Don't indent Doxygen doc strings in generated Python code.
This is unnecessary and inconsistent with "builtin" case in which the docstrings are not indented in the generated C++ code, thus making it impossible to write tests working in both cases. Most of the changes in this commit simply remove the extra whitespace from the expected values in the tests.
This commit is contained in:
parent
9b857e6cf1
commit
410b508e9a
9 changed files with 471 additions and 535 deletions
|
|
@ -14,7 +14,6 @@ commentVerifier.check(doxygen_basic_notranslate.function.__doc__,
|
||||||
\author Some author
|
\author Some author
|
||||||
\return Some number
|
\return Some number
|
||||||
\sa function2
|
\sa function2
|
||||||
|
|
||||||
"""
|
"""
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -22,13 +21,11 @@ commentVerifier.check(doxygen_basic_notranslate.function2.__doc__,
|
||||||
r"""
|
r"""
|
||||||
A test of a very very very very very very very very very very very very very very very very
|
A test of a very very very very very very very very very very very very very very very very
|
||||||
very very very very very long comment string.
|
very very very very very long comment string.
|
||||||
|
|
||||||
"""
|
"""
|
||||||
)
|
)
|
||||||
|
|
||||||
commentVerifier.check(doxygen_basic_notranslate.function3.__doc__,
|
commentVerifier.check(doxygen_basic_notranslate.function3.__doc__,
|
||||||
r"""
|
r""" *Overload 1:*
|
||||||
*Overload 1:*
|
|
||||||
|
|
||||||
A test for overloaded functions
|
A test for overloaded functions
|
||||||
This is function \b one
|
This is function \b one
|
||||||
|
|
@ -38,8 +35,7 @@ commentVerifier.check(doxygen_basic_notranslate.function3.__doc__,
|
||||||
*Overload 2:*
|
*Overload 2:*
|
||||||
|
|
||||||
A test for overloaded functions
|
A test for overloaded functions
|
||||||
This is function \b two
|
This is function \b two"""
|
||||||
"""
|
|
||||||
)
|
)
|
||||||
|
|
||||||
commentVerifier.check(doxygen_basic_notranslate.function4.__doc__,
|
commentVerifier.check(doxygen_basic_notranslate.function4.__doc__,
|
||||||
|
|
@ -58,7 +54,6 @@ commentVerifier.check(doxygen_basic_notranslate.function4.__doc__,
|
||||||
int main() { while(true); }
|
int main() { while(true); }
|
||||||
\endcode
|
\endcode
|
||||||
\endif
|
\endif
|
||||||
|
|
||||||
"""
|
"""
|
||||||
)
|
)
|
||||||
commentVerifier.check(doxygen_basic_notranslate.function5.__doc__,
|
commentVerifier.check(doxygen_basic_notranslate.function5.__doc__,
|
||||||
|
|
@ -68,7 +63,6 @@ commentVerifier.check(doxygen_basic_notranslate.function6.__doc__,
|
||||||
r"""
|
r"""
|
||||||
Test for default args
|
Test for default args
|
||||||
@param a Some parameter, default is 42
|
@param a Some parameter, default is 42
|
||||||
|
|
||||||
"""
|
"""
|
||||||
)
|
)
|
||||||
commentVerifier.check(doxygen_basic_notranslate.function7.__doc__,
|
commentVerifier.check(doxygen_basic_notranslate.function7.__doc__,
|
||||||
|
|
@ -76,6 +70,5 @@ commentVerifier.check(doxygen_basic_notranslate.function7.__doc__,
|
||||||
Test for a parameter with difficult type
|
Test for a parameter with difficult type
|
||||||
(mostly for python)
|
(mostly for python)
|
||||||
@param a Very strange param
|
@param a Very strange param
|
||||||
|
|
||||||
"""
|
"""
|
||||||
)
|
)
|
||||||
|
|
|
||||||
|
|
@ -7,6 +7,7 @@ import commentVerifier
|
||||||
|
|
||||||
commentVerifier.check(doxygen_basic_translate.function.__doc__,
|
commentVerifier.check(doxygen_basic_translate.function.__doc__,
|
||||||
"""
|
"""
|
||||||
|
|
||||||
Brief description.
|
Brief description.
|
||||||
|
|
||||||
The comment text.
|
The comment text.
|
||||||
|
|
@ -16,18 +17,15 @@ commentVerifier.check(doxygen_basic_translate.function.__doc__,
|
||||||
:rtype: int
|
:rtype: int
|
||||||
:return: Some number
|
:return: Some number
|
||||||
|
|
||||||
See also: function2
|
See also: function2"""
|
||||||
"""
|
|
||||||
)
|
)
|
||||||
commentVerifier.check(doxygen_basic_translate.function2.__doc__,
|
commentVerifier.check(doxygen_basic_translate.function2.__doc__,
|
||||||
"""
|
"""
|
||||||
A test of a very very very very very very very very very very very very very very very very
|
A test of a very very very very very very very very very very very very very very very very
|
||||||
very very very very very long comment string.
|
very very very very very long comment string."""
|
||||||
"""
|
|
||||||
)
|
)
|
||||||
commentVerifier.check(doxygen_basic_translate.function3.__doc__,
|
commentVerifier.check(doxygen_basic_translate.function3.__doc__,
|
||||||
"""
|
"""*Overload 1:*
|
||||||
*Overload 1:*
|
|
||||||
|
|
||||||
A test for overloaded functions
|
A test for overloaded functions
|
||||||
This is function **one**
|
This is function **one**
|
||||||
|
|
@ -37,8 +35,7 @@ commentVerifier.check(doxygen_basic_translate.function3.__doc__,
|
||||||
*Overload 2:*
|
*Overload 2:*
|
||||||
|
|
||||||
A test for overloaded functions
|
A test for overloaded functions
|
||||||
This is function **two**
|
This is function **two**"""
|
||||||
"""
|
|
||||||
)
|
)
|
||||||
commentVerifier.check(doxygen_basic_translate.function4.__doc__,
|
commentVerifier.check(doxygen_basic_translate.function4.__doc__,
|
||||||
"""
|
"""
|
||||||
|
|
@ -57,8 +54,7 @@ commentVerifier.check(doxygen_basic_translate.function4.__doc__,
|
||||||
|
|
||||||
int main() { while(true); }
|
int main() { while(true); }
|
||||||
|
|
||||||
}
|
}"""
|
||||||
"""
|
|
||||||
)
|
)
|
||||||
commentVerifier.check(doxygen_basic_translate.function5.__doc__,
|
commentVerifier.check(doxygen_basic_translate.function5.__doc__,
|
||||||
""" This is a post comment."""
|
""" This is a post comment."""
|
||||||
|
|
@ -67,16 +63,14 @@ commentVerifier.check(doxygen_basic_translate.function6.__doc__,
|
||||||
"""
|
"""
|
||||||
Test for default args
|
Test for default args
|
||||||
:type a: int
|
:type a: int
|
||||||
:param a: Some parameter, default is 42
|
:param a: Some parameter, default is 42"""
|
||||||
"""
|
|
||||||
)
|
)
|
||||||
commentVerifier.check(doxygen_basic_translate.function7.__doc__,
|
commentVerifier.check(doxygen_basic_translate.function7.__doc__,
|
||||||
"""
|
"""
|
||||||
Test for a parameter with difficult type
|
Test for a parameter with difficult type
|
||||||
(mostly for python)
|
(mostly for python)
|
||||||
:type a: :py:class:`Shape`
|
:type a: :py:class:`Shape`
|
||||||
:param a: Very strange param
|
:param a: Very strange param"""
|
||||||
"""
|
|
||||||
)
|
)
|
||||||
|
|
||||||
commentVerifier.check(doxygen_basic_translate.Atan2.__doc__,
|
commentVerifier.check(doxygen_basic_translate.Atan2.__doc__,
|
||||||
|
|
@ -88,6 +82,5 @@ commentVerifier.check(doxygen_basic_translate.Atan2.__doc__,
|
||||||
:type x: float
|
:type x: float
|
||||||
:param x: Horizontal coordinate.
|
:param x: Horizontal coordinate.
|
||||||
:rtype: float
|
:rtype: float
|
||||||
:return: Arc tangent of ``y/x``.
|
:return: Arc tangent of ``y/x``."""
|
||||||
"""
|
|
||||||
)
|
)
|
||||||
|
|
|
||||||
|
|
@ -17,5 +17,4 @@ commentVerifier.check(doxygen_ignore.func.__doc__,
|
||||||
|
|
||||||
Command ignored, but anything here is still included.
|
Command ignored, but anything here is still included.
|
||||||
|
|
||||||
|
|
||||||
""")
|
""")
|
||||||
|
|
|
||||||
|
|
@ -18,7 +18,6 @@ commentVerifier.check(doxygen_misc_constructs.getAddress.__doc__,
|
||||||
:param isGetSize: if set, for every object location both address and size are returned
|
:param isGetSize: if set, for every object location both address and size are returned
|
||||||
|
|
||||||
Connection::getId()
|
Connection::getId()
|
||||||
|
|
||||||
""")
|
""")
|
||||||
|
|
||||||
commentVerifier.check(doxygen_misc_constructs.CConnectionConfig.__doc__,
|
commentVerifier.check(doxygen_misc_constructs.CConnectionConfig.__doc__,
|
||||||
|
|
@ -36,21 +35,19 @@ commentVerifier.check(doxygen_misc_constructs.CConnectionConfig.__doc__,
|
||||||
|
|
||||||
|
|
||||||
advancedWinIDEALaunching.py Python example.
|
advancedWinIDEALaunching.py Python example.
|
||||||
|
|
||||||
""")
|
""")
|
||||||
|
|
||||||
commentVerifier.check(doxygen_misc_constructs.waitTime.__doc__,
|
commentVerifier.check(doxygen_misc_constructs.waitTime.__doc__,
|
||||||
r"""
|
r"""
|
||||||
Determines how long the ``isystem.connect`` should wait for running
|
Determines how long the ``isystem.connect`` should wait for running
|
||||||
instances to respond. Only one of ``lfWaitXXX`` flags from IConnect::ELaunchFlags
|
instances to respond. Only one of ``lfWaitXXX`` flags from IConnect::ELaunchFlags
|
||||||
may be specified.
|
may be specified."""
|
||||||
"""
|
|
||||||
)
|
)
|
||||||
|
|
||||||
commentVerifier.check(doxygen_misc_constructs.getConnection.__doc__,
|
commentVerifier.check(doxygen_misc_constructs.getConnection.__doc__,
|
||||||
r"""
|
r"""
|
||||||
This function returns connection id.
|
|
||||||
"""
|
This function returns connection id."""
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -60,8 +57,7 @@ commentVerifier.check(doxygen_misc_constructs.getFirstLetter.__doc__,
|
||||||
|
|
||||||
commentVerifier.check(doxygen_misc_constructs.ClassWithNestedEnum.__doc__,
|
commentVerifier.check(doxygen_misc_constructs.ClassWithNestedEnum.__doc__,
|
||||||
r"""
|
r"""
|
||||||
Class description.
|
Class description."""
|
||||||
"""
|
|
||||||
)
|
)
|
||||||
|
|
||||||
commentVerifier.check(doxygen_misc_constructs.showList.__doc__,
|
commentVerifier.check(doxygen_misc_constructs.showList.__doc__,
|
||||||
|
|
@ -75,21 +71,16 @@ commentVerifier.check(doxygen_misc_constructs.showList.__doc__,
|
||||||
is preserved.
|
is preserved.
|
||||||
- And the final list item after it.
|
- And the final list item after it.
|
||||||
|
|
||||||
And this is not a list item any more.
|
And this is not a list item any more."""
|
||||||
"""
|
|
||||||
)
|
)
|
||||||
|
|
||||||
commentVerifier.check(doxygen_misc_constructs.isNoSpaceValidA.__doc__,
|
commentVerifier.check(doxygen_misc_constructs.isNoSpaceValidA.__doc__,
|
||||||
r"""
|
r"""This comment without space after '*' is valid in Doxygen.
|
||||||
This comment without space after '*' is valid in Doxygen.
|
|
||||||
|
|
||||||
"""
|
"""
|
||||||
)
|
)
|
||||||
|
|
||||||
commentVerifier.check(doxygen_misc_constructs.isNoSpaceValidB.__doc__,
|
commentVerifier.check(doxygen_misc_constructs.isNoSpaceValidB.__doc__,
|
||||||
r"""
|
r""".This comment without space after '*' is valid in Doxygen.
|
||||||
.This comment without space after '*' is valid in Doxygen.
|
|
||||||
|
|
||||||
"""
|
"""
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -100,8 +91,7 @@ commentVerifier.check(doxygen_misc_constructs.isNoSpaceValidC.__doc__,
|
||||||
commentVerifier.check(doxygen_misc_constructs.backslashA.__doc__,
|
commentVerifier.check(doxygen_misc_constructs.backslashA.__doc__,
|
||||||
r"""
|
r"""
|
||||||
Backslash following``word`` is a valid doxygen command. Output contains
|
Backslash following``word`` is a valid doxygen command. Output contains
|
||||||
'followingword' with 'word' in code font.
|
'followingword' with 'word' in code font."""
|
||||||
"""
|
|
||||||
)
|
)
|
||||||
|
|
||||||
commentVerifier.check(doxygen_misc_constructs.backslashB.__doc__,
|
commentVerifier.check(doxygen_misc_constructs.backslashB.__doc__,
|
||||||
|
|
@ -117,8 +107,7 @@ commentVerifier.check(doxygen_misc_constructs.backslashB.__doc__,
|
||||||
'd:'. Escaping works: d:\xyz\qwe\myfile. Unix
|
'd:'. Escaping works: d:\xyz\qwe\myfile. Unix
|
||||||
paths of course have no such problems: /xyz/qwe/myfile
|
paths of course have no such problems: /xyz/qwe/myfile
|
||||||
Commands for escaped symbols:
|
Commands for escaped symbols:
|
||||||
$ @ \ & ~ < > # % " . :: @text ::text
|
$ @ \ & ~ < > # % " . :: @text ::text"""
|
||||||
"""
|
|
||||||
)
|
)
|
||||||
|
|
||||||
commentVerifier.check(doxygen_misc_constructs.backslashC.__doc__,
|
commentVerifier.check(doxygen_misc_constructs.backslashC.__doc__,
|
||||||
|
|
@ -127,8 +116,7 @@ commentVerifier.check(doxygen_misc_constructs.backslashC.__doc__,
|
||||||
*with* old comment parser.
|
*with* old comment parser.
|
||||||
|
|
||||||
See also: MyClass::fun(char,
|
See also: MyClass::fun(char,
|
||||||
float)
|
float)"""
|
||||||
"""
|
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -157,6 +145,5 @@ commentVerifier.check(doxygen_misc_constructs.cycle.__doc__,
|
||||||
|
|
||||||
|
|
||||||
:type fileName: string
|
:type fileName: string
|
||||||
:param fileName: name of the log file
|
:param fileName: name of the log file"""
|
||||||
"""
|
|
||||||
);
|
);
|
||||||
|
|
|
||||||
|
|
@ -7,32 +7,26 @@ import commentVerifier
|
||||||
|
|
||||||
commentVerifier.check(doxygen_parsing.someFunction.__doc__,
|
commentVerifier.check(doxygen_parsing.someFunction.__doc__,
|
||||||
r"""
|
r"""
|
||||||
The function comment
|
The function comment""")
|
||||||
""")
|
|
||||||
commentVerifier.check(doxygen_parsing.SomeClass.__doc__,
|
commentVerifier.check(doxygen_parsing.SomeClass.__doc__,
|
||||||
r"""
|
r"""
|
||||||
The class comment
|
The class comment""")
|
||||||
""")
|
|
||||||
commentVerifier.check(doxygen_parsing.SomeStruct.__doc__,
|
commentVerifier.check(doxygen_parsing.SomeStruct.__doc__,
|
||||||
r"""
|
r"""
|
||||||
The struct comment
|
The struct comment""")
|
||||||
""")
|
|
||||||
commentVerifier.check(doxygen_parsing.SomeAnotherClass.__init__.__doc__,
|
commentVerifier.check(doxygen_parsing.SomeAnotherClass.__init__.__doc__,
|
||||||
r"""
|
r""" *Overload 1:*
|
||||||
*Overload 1:*
|
|
||||||
First overloaded constructor.
|
First overloaded constructor.
|
||||||
|
|
||||||
|
|
|
|
||||||
|
|
||||||
*Overload 2:*
|
*Overload 2:*
|
||||||
Second overloaded constructor.
|
Second overloaded constructor.""")
|
||||||
""")
|
|
||||||
commentVerifier.check(doxygen_parsing.SomeAnotherClass.classMethod.__doc__,
|
commentVerifier.check(doxygen_parsing.SomeAnotherClass.classMethod.__doc__,
|
||||||
r"""
|
r"""
|
||||||
The class method comment.
|
The class method comment.
|
||||||
|
|
||||||
SomeAnotherClass#classMethodExtended(int, int) a link text
|
SomeAnotherClass#classMethodExtended(int, int) a link text""")
|
||||||
""")
|
|
||||||
commentVerifier.check(doxygen_parsing.SomeAnotherClass.classMethodExtended.__doc__,
|
commentVerifier.check(doxygen_parsing.SomeAnotherClass.classMethodExtended.__doc__,
|
||||||
r"""
|
r"""
|
||||||
The class method with parameter
|
The class method with parameter
|
||||||
|
|
@ -40,8 +34,7 @@ commentVerifier.check(doxygen_parsing.SomeAnotherClass.classMethodExtended.__doc
|
||||||
:type a: int
|
:type a: int
|
||||||
:param a: Parameter a
|
:param a: Parameter a
|
||||||
:type b: int
|
:type b: int
|
||||||
:param b: Parameter b
|
:param b: Parameter b"""
|
||||||
"""
|
|
||||||
)
|
)
|
||||||
commentVerifier.check(doxygen_parsing.SomeAnotherClass.classMethodExtended2.__doc__,
|
commentVerifier.check(doxygen_parsing.SomeAnotherClass.classMethodExtended2.__doc__,
|
||||||
r"""
|
r"""
|
||||||
|
|
@ -50,13 +43,11 @@ commentVerifier.check(doxygen_parsing.SomeAnotherClass.classMethodExtended2.__do
|
||||||
:type a: int
|
:type a: int
|
||||||
:param a: Parameter a
|
:param a: Parameter a
|
||||||
:type b: int
|
:type b: int
|
||||||
:param b: Parameter b
|
:param b: Parameter b"""
|
||||||
"""
|
|
||||||
)
|
)
|
||||||
commentVerifier.check(doxygen_parsing.SomeAnotherStruct.structMethod.__doc__,
|
commentVerifier.check(doxygen_parsing.SomeAnotherStruct.structMethod.__doc__,
|
||||||
r"""
|
r"""
|
||||||
The struct method comment
|
The struct method comment""")
|
||||||
""")
|
|
||||||
commentVerifier.check(doxygen_parsing.SomeAnotherStruct.structMethodExtended.__doc__,
|
commentVerifier.check(doxygen_parsing.SomeAnotherStruct.structMethodExtended.__doc__,
|
||||||
r"""
|
r"""
|
||||||
The struct method with parameter
|
The struct method with parameter
|
||||||
|
|
@ -64,8 +55,7 @@ commentVerifier.check(doxygen_parsing.SomeAnotherStruct.structMethodExtended.__d
|
||||||
:type a: int
|
:type a: int
|
||||||
:param a: Parameter a
|
:param a: Parameter a
|
||||||
:type b: int
|
:type b: int
|
||||||
:param b: Parameter b
|
:param b: Parameter b"""
|
||||||
"""
|
|
||||||
)
|
)
|
||||||
commentVerifier.check(doxygen_parsing.SomeAnotherStruct.structMethodExtended2.__doc__,
|
commentVerifier.check(doxygen_parsing.SomeAnotherStruct.structMethodExtended2.__doc__,
|
||||||
r"""
|
r"""
|
||||||
|
|
@ -74,5 +64,4 @@ commentVerifier.check(doxygen_parsing.SomeAnotherStruct.structMethodExtended2.__
|
||||||
:type a: int
|
:type a: int
|
||||||
:param a: Parameter a
|
:param a: Parameter a
|
||||||
:type b: int
|
:type b: int
|
||||||
:param b: Parameter b
|
:param b: Parameter b""")
|
||||||
""")
|
|
||||||
|
|
|
||||||
|
|
@ -40,7 +40,6 @@ r"""
|
||||||
.. code-block:: c++
|
.. code-block:: c++
|
||||||
|
|
||||||
some test code
|
some test code
|
||||||
|
|
||||||
""")
|
""")
|
||||||
|
|
||||||
commentVerifier.check(doxygen_translate_all_tags.func02.__doc__,
|
commentVerifier.check(doxygen_translate_all_tags.func02.__doc__,
|
||||||
|
|
@ -66,8 +65,7 @@ r"""
|
||||||
Deprecated: Now use another function
|
Deprecated: Now use another function
|
||||||
|
|
||||||
This is very large
|
This is very large
|
||||||
and detailed description of some thing
|
and detailed description of some thing""")
|
||||||
""")
|
|
||||||
|
|
||||||
commentVerifier.check(doxygen_translate_all_tags.func03.__doc__,
|
commentVerifier.check(doxygen_translate_all_tags.func03.__doc__,
|
||||||
r"""
|
r"""
|
||||||
|
|
@ -88,11 +86,11 @@ r"""
|
||||||
|
|
||||||
|
|
||||||
Example: someFile.txt
|
Example: someFile.txt
|
||||||
Some details on using the example
|
Some details on using the example""")
|
||||||
""")
|
|
||||||
|
|
||||||
commentVerifier.check(doxygen_translate_all_tags.func04.__doc__,
|
commentVerifier.check(doxygen_translate_all_tags.func04.__doc__,
|
||||||
r"""
|
r"""
|
||||||
|
|
||||||
:raises: SuperError
|
:raises: SuperError
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -122,7 +120,6 @@ r"""
|
||||||
|
|
||||||
|
|
||||||
This will only appear in hmtl
|
This will only appear in hmtl
|
||||||
|
|
||||||
""")
|
""")
|
||||||
|
|
||||||
commentVerifier.check(doxygen_translate_all_tags.func05.__doc__,
|
commentVerifier.check(doxygen_translate_all_tags.func05.__doc__,
|
||||||
|
|
@ -158,8 +155,7 @@ r"""
|
||||||
|
|
||||||
|
|
||||||
Some text
|
Some text
|
||||||
describing invariant.
|
describing invariant.""")
|
||||||
""")
|
|
||||||
|
|
||||||
commentVerifier.check(doxygen_translate_all_tags.func06.__doc__,
|
commentVerifier.check(doxygen_translate_all_tags.func06.__doc__,
|
||||||
r"""
|
r"""
|
||||||
|
|
@ -197,7 +193,6 @@ r"""
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
""")
|
""")
|
||||||
|
|
||||||
commentVerifier.check(doxygen_translate_all_tags.func07.__doc__,
|
commentVerifier.check(doxygen_translate_all_tags.func07.__doc__,
|
||||||
|
|
@ -233,11 +228,15 @@ r"""
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
""")
|
""")
|
||||||
|
|
||||||
commentVerifier.check(doxygen_translate_all_tags.func08.__doc__,
|
commentVerifier.check(doxygen_translate_all_tags.func08.__doc__,
|
||||||
r"""
|
r"""
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
Text after anchor.
|
Text after anchor.
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -271,11 +270,11 @@ r"""
|
||||||
|
|
||||||
:rtype: int
|
:rtype: int
|
||||||
:return: may return
|
:return: may return
|
||||||
|
|
||||||
""")
|
""")
|
||||||
|
|
||||||
commentVerifier.check(doxygen_translate_all_tags.func09.__doc__,
|
commentVerifier.check(doxygen_translate_all_tags.func09.__doc__,
|
||||||
r"""
|
r"""
|
||||||
|
|
||||||
This will only appear in RTF
|
This will only appear in RTF
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -308,8 +307,7 @@ r"""
|
||||||
|
|
||||||
:raises: superException
|
:raises: superException
|
||||||
|
|
||||||
:raises: RuntimeError
|
:raises: RuntimeError""")
|
||||||
""")
|
|
||||||
|
|
||||||
commentVerifier.check(doxygen_translate_all_tags.func10.__doc__,
|
commentVerifier.check(doxygen_translate_all_tags.func10.__doc__,
|
||||||
r"""
|
r"""
|
||||||
|
|
@ -343,5 +341,4 @@ r"""
|
||||||
Here goes test of symbols:
|
Here goes test of symbols:
|
||||||
$ @ \ & ~ < > # % " . ::
|
$ @ \ & ~ < > # % " . ::
|
||||||
|
|
||||||
And here goes simple text
|
And here goes simple text""")
|
||||||
""")
|
|
||||||
|
|
|
||||||
|
|
@ -38,5 +38,4 @@ r"""
|
||||||
See also: superFunc()
|
See also: superFunc()
|
||||||
See also: superFunc()
|
See also: superFunc()
|
||||||
See also: superFunc()
|
See also: superFunc()
|
||||||
|
|
||||||
""")
|
""")
|
||||||
|
|
|
||||||
|
|
@ -135,8 +135,7 @@ r"""
|
||||||
Here goes test of symbols:
|
Here goes test of symbols:
|
||||||
$ @ \ & ~ < > # % " . ::
|
$ @ \ & ~ < > # % " . ::
|
||||||
|
|
||||||
And here goes simple text
|
And here goes simple text"""
|
||||||
"""
|
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -224,7 +223,6 @@ r"""
|
||||||
|
|
||||||
|
|
||||||
<u>underlined \b bold text - doxy commands are ignored inside 'htmlonly' section </u>
|
<u>underlined \b bold text - doxy commands are ignored inside 'htmlonly' section </u>
|
||||||
|
|
||||||
""")
|
""")
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -242,8 +240,7 @@ r"""
|
||||||
| 17 - 32 | 4 |
|
| 17 - 32 | 4 |
|
||||||
|
|
||||||
Almost all combinations of above flags are supported by
|
Almost all combinations of above flags are supported by
|
||||||
``htmlTable...`` functions.
|
``htmlTable...`` functions.""")
|
||||||
""")
|
|
||||||
|
|
||||||
|
|
||||||
commentVerifier.check(doxygen_translate.htmlEntitiesFunction.__doc__,
|
commentVerifier.check(doxygen_translate.htmlEntitiesFunction.__doc__,
|
||||||
|
|
@ -270,5 +267,4 @@ r"""
|
||||||
<--
|
<--
|
||||||
-->
|
-->
|
||||||
Not an html entity - ignored by Doxygen.
|
Not an html entity - ignored by Doxygen.
|
||||||
Not an &text html entity - ampersand is replaced with entity.
|
Not an &text html entity - ampersand is replaced with entity.""")
|
||||||
""")
|
|
||||||
|
|
|
||||||
|
|
@ -1545,21 +1545,12 @@ public:
|
||||||
* Get the docstring text enclosed in triple double quotes.
|
* Get the docstring text enclosed in triple double quotes.
|
||||||
* ------------------------------------------------------------ */
|
* ------------------------------------------------------------ */
|
||||||
|
|
||||||
String *docstring(Node *n, autodoc_t ad_type, const String *indent) {
|
String *docstring(Node *n, autodoc_t ad_type) {
|
||||||
String *docstr = build_combined_docstring(n, ad_type);
|
String *docstr = build_combined_docstring(n, ad_type);
|
||||||
if (!Len(docstr))
|
if (!Len(docstr))
|
||||||
return docstr;
|
return docstr;
|
||||||
|
|
||||||
|
|
||||||
// If there is more than one line then make docstrings like this:
|
|
||||||
//
|
|
||||||
// """
|
|
||||||
// This is line1
|
|
||||||
// And here is line2 followed by the rest of them
|
|
||||||
// """
|
|
||||||
//
|
|
||||||
// otherwise, put it all on a single line
|
|
||||||
//
|
|
||||||
// Notice that all comments are created as raw strings (prefix "r"),
|
// Notice that all comments are created as raw strings (prefix "r"),
|
||||||
// because '\' is used often in comments, but may break Python module from
|
// because '\' is used often in comments, but may break Python module from
|
||||||
// loading. For example, in doxy comment one may write path in quotes:
|
// loading. For example, in doxy comment one may write path in quotes:
|
||||||
|
|
@ -1571,15 +1562,7 @@ public:
|
||||||
// of doxygen doc, Latex expressions, ...
|
// of doxygen doc, Latex expressions, ...
|
||||||
String *doc = NewString("");
|
String *doc = NewString("");
|
||||||
Append(doc, "r\"\"\"");
|
Append(doc, "r\"\"\"");
|
||||||
|
|
||||||
if (Strchr(docstr, '\n') == 0) {
|
|
||||||
Append(doc, docstr);
|
Append(doc, docstr);
|
||||||
} else {
|
|
||||||
Append(doc, "\n");
|
|
||||||
Append(doc, pythoncode(docstr, indent));
|
|
||||||
Append(doc, indent);
|
|
||||||
}
|
|
||||||
|
|
||||||
Append(doc, "\"\"\"");
|
Append(doc, "\"\"\"");
|
||||||
|
|
||||||
Delete(docstr);
|
Delete(docstr);
|
||||||
|
|
@ -2137,7 +2120,7 @@ public:
|
||||||
/* Make a wrapper function to insert the code into */
|
/* Make a wrapper function to insert the code into */
|
||||||
Printv(f_dest, "\ndef ", name, "(", parms, ")", returnTypeAnnotation(n), ":\n", NIL);
|
Printv(f_dest, "\ndef ", name, "(", parms, ")", returnTypeAnnotation(n), ":\n", NIL);
|
||||||
if (have_docstring(n))
|
if (have_docstring(n))
|
||||||
Printv(f_dest, tab4, docstring(n, AUTODOC_FUNC, tab4), "\n", NIL);
|
Printv(f_dest, tab4, docstring(n, AUTODOC_FUNC), "\n", NIL);
|
||||||
if (have_pythonprepend(n))
|
if (have_pythonprepend(n))
|
||||||
Printv(f_dest, pythoncode(pythonprepend(n), tab4), "\n", NIL);
|
Printv(f_dest, pythoncode(pythonprepend(n), tab4), "\n", NIL);
|
||||||
if (have_pythonappend(n)) {
|
if (have_pythonappend(n)) {
|
||||||
|
|
@ -3274,7 +3257,7 @@ public:
|
||||||
if (f_s) {
|
if (f_s) {
|
||||||
Printv(f_s, iname, " = ", module, ".", iname, "\n", NIL);
|
Printv(f_s, iname, " = ", module, ".", iname, "\n", NIL);
|
||||||
if (have_docstring(n))
|
if (have_docstring(n))
|
||||||
Printv(f_s, docstring(n, AUTODOC_CONST, ""), "\n", NIL);
|
Printv(f_s, docstring(n, AUTODOC_CONST), "\n", NIL);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return SWIG_OK;
|
return SWIG_OK;
|
||||||
|
|
@ -4053,7 +4036,7 @@ public:
|
||||||
|
|
||||||
// write docstrings if requested
|
// write docstrings if requested
|
||||||
if (have_docstring(n)) {
|
if (have_docstring(n)) {
|
||||||
String *str = docstring(n, AUTODOC_CLASS, tab4);
|
String *str = docstring(n, AUTODOC_CLASS);
|
||||||
if (str && Len(str))
|
if (str && Len(str))
|
||||||
Printv(f_shadow, tab4, str, "\n", NIL);
|
Printv(f_shadow, tab4, str, "\n", NIL);
|
||||||
}
|
}
|
||||||
|
|
@ -4333,7 +4316,7 @@ public:
|
||||||
} else {
|
} else {
|
||||||
Printv(f_shadow, "\n", tab4, "def ", symname, "(", parms, ")", returnTypeAnnotation(n), ":\n", NIL);
|
Printv(f_shadow, "\n", tab4, "def ", symname, "(", parms, ")", returnTypeAnnotation(n), ":\n", NIL);
|
||||||
if (have_docstring(n))
|
if (have_docstring(n))
|
||||||
Printv(f_shadow, tab8, docstring(n, AUTODOC_METHOD, tab8), "\n", NIL);
|
Printv(f_shadow, tab8, docstring(n, AUTODOC_METHOD), "\n", NIL);
|
||||||
if (have_pythonprepend(n)) {
|
if (have_pythonprepend(n)) {
|
||||||
fproxy = 0;
|
fproxy = 0;
|
||||||
Printv(f_shadow, pythoncode(pythonprepend(n), tab8), "\n", NIL);
|
Printv(f_shadow, pythoncode(pythonprepend(n), tab8), "\n", NIL);
|
||||||
|
|
@ -4419,7 +4402,7 @@ public:
|
||||||
String *callParms = make_pyParmList(n, false, true, kw);
|
String *callParms = make_pyParmList(n, false, true, kw);
|
||||||
Printv(f_shadow, "\n", tab4, "def ", symname, "(", parms, ")", returnTypeAnnotation(n), ":\n", NIL);
|
Printv(f_shadow, "\n", tab4, "def ", symname, "(", parms, ")", returnTypeAnnotation(n), ":\n", NIL);
|
||||||
if (have_docstring(n))
|
if (have_docstring(n))
|
||||||
Printv(f_shadow, tab8, docstring(n, AUTODOC_STATICFUNC, tab8), "\n", NIL);
|
Printv(f_shadow, tab8, docstring(n, AUTODOC_STATICFUNC), "\n", NIL);
|
||||||
if (have_pythonprepend(n))
|
if (have_pythonprepend(n))
|
||||||
Printv(f_shadow, pythoncode(pythonprepend(n), tab8), "\n", NIL);
|
Printv(f_shadow, pythoncode(pythonprepend(n), tab8), "\n", NIL);
|
||||||
if (have_pythonappend(n)) {
|
if (have_pythonappend(n)) {
|
||||||
|
|
@ -4536,7 +4519,7 @@ public:
|
||||||
|
|
||||||
Printv(f_shadow, "\n", tab4, "def __init__(", parms, ")", returnTypeAnnotation(n), ":\n", NIL);
|
Printv(f_shadow, "\n", tab4, "def __init__(", parms, ")", returnTypeAnnotation(n), ":\n", NIL);
|
||||||
if (have_docstring(n))
|
if (have_docstring(n))
|
||||||
Printv(f_shadow, tab8, docstring(n, AUTODOC_CTOR, tab8), "\n", NIL);
|
Printv(f_shadow, tab8, docstring(n, AUTODOC_CTOR), "\n", NIL);
|
||||||
if (have_pythonprepend(n))
|
if (have_pythonprepend(n))
|
||||||
Printv(f_shadow, pythoncode(pythonprepend(n), tab8), "\n", NIL);
|
Printv(f_shadow, pythoncode(pythonprepend(n), tab8), "\n", NIL);
|
||||||
Printv(f_shadow, pass_self, NIL);
|
Printv(f_shadow, pass_self, NIL);
|
||||||
|
|
@ -4569,7 +4552,7 @@ public:
|
||||||
|
|
||||||
Printv(f_shadow_stubs, "\ndef ", symname, "(", parms, ")", returnTypeAnnotation(n), ":\n", NIL);
|
Printv(f_shadow_stubs, "\ndef ", symname, "(", parms, ")", returnTypeAnnotation(n), ":\n", NIL);
|
||||||
if (have_docstring(n))
|
if (have_docstring(n))
|
||||||
Printv(f_shadow_stubs, tab4, docstring(n, AUTODOC_CTOR, tab4), "\n", NIL);
|
Printv(f_shadow_stubs, tab4, docstring(n, AUTODOC_CTOR), "\n", NIL);
|
||||||
if (have_pythonprepend(n))
|
if (have_pythonprepend(n))
|
||||||
Printv(f_shadow_stubs, pythoncode(pythonprepend(n), tab4), "\n", NIL);
|
Printv(f_shadow_stubs, pythoncode(pythonprepend(n), tab4), "\n", NIL);
|
||||||
String *subfunc = NULL;
|
String *subfunc = NULL;
|
||||||
|
|
@ -4637,7 +4620,7 @@ public:
|
||||||
}
|
}
|
||||||
Printv(f_shadow, tab4, "def __del__(self):\n", NIL);
|
Printv(f_shadow, tab4, "def __del__(self):\n", NIL);
|
||||||
if (have_docstring(n))
|
if (have_docstring(n))
|
||||||
Printv(f_shadow, tab8, docstring(n, AUTODOC_DTOR, tab8), "\n", NIL);
|
Printv(f_shadow, tab8, docstring(n, AUTODOC_DTOR), "\n", NIL);
|
||||||
if (have_pythonprepend(n))
|
if (have_pythonprepend(n))
|
||||||
Printv(f_shadow, pythoncode(pythonprepend(n), tab8), "\n", NIL);
|
Printv(f_shadow, pythoncode(pythonprepend(n), tab8), "\n", NIL);
|
||||||
#ifdef USE_THISOWN
|
#ifdef USE_THISOWN
|
||||||
|
|
@ -4811,7 +4794,7 @@ public:
|
||||||
} else if (shadow) {
|
} else if (shadow) {
|
||||||
Printv(f_shadow, tab4, symname, " = ", module, ".", Swig_name_member(NSPACE_TODO, class_name, symname), "\n", NIL);
|
Printv(f_shadow, tab4, symname, " = ", module, ".", Swig_name_member(NSPACE_TODO, class_name, symname), "\n", NIL);
|
||||||
if (have_docstring(n))
|
if (have_docstring(n))
|
||||||
Printv(f_shadow, tab4, docstring(n, AUTODOC_CONST, tab4), "\n", NIL);
|
Printv(f_shadow, tab4, docstring(n, AUTODOC_CONST), "\n", NIL);
|
||||||
}
|
}
|
||||||
return SWIG_OK;
|
return SWIG_OK;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue