diff options
author | Jakob Lykke Andersen <jakob@caput.dk> | 2014-08-06 17:41:51 +0200 |
---|---|---|
committer | Jakob Lykke Andersen <jakob@caput.dk> | 2014-08-06 17:41:51 +0200 |
commit | 14e6affa7d243948592062750c025523bc8302a1 (patch) | |
tree | eab76a9ddd9e39fbf749319560e827d638640252 /tests/test_cpp_domain.py | |
parent | c19a15ea0d87e8851597cd14813c19ed8312da83 (diff) | |
download | sphinx-git-14e6affa7d243948592062750c025523bc8302a1.tar.gz |
C++, update id generation to use name mangling
Diffstat (limited to 'tests/test_cpp_domain.py')
-rw-r--r-- | tests/test_cpp_domain.py | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/tests/test_cpp_domain.py b/tests/test_cpp_domain.py index 8750ddbed..7be8fe3f4 100644 --- a/tests/test_cpp_domain.py +++ b/tests/test_cpp_domain.py @@ -31,11 +31,13 @@ def check(name, input, output=None): ast = parse(name, input) res = text_type(ast) if res != output: - print("Input: ", text_type(input)) - print("Result:", res) + print "Input: ", text_type(input) + print "Result: ", res + print "Expected: ", output raise DefinitionError("") - # now check describe_signature ast.describe_signature([], 'lastIsName', None) + ast.prefixedName = ast.name # otherwise the get_id fails, it would be set in handle_signarue + ast.get_id() #print ".. %s:: %s" % (name, input) def test_type_definitions(): @@ -92,7 +94,7 @@ def test_type_definitions(): check('function', 'MyClass::a_member_function() &&') check('function', 'MyClass::a_member_function() &') check('function', 'MyClass::a_member_function() const &') - check('function', 'int main(int argc, char *argv[][])') + check('function', 'int main(int argc, char *argv[])') check('function', 'MyClass &MyClass::operator++()') check('function', 'MyClass::pointer MyClass::operator->()') |