8000 doxygen 'ignore' errors on backslash · Issue #3205 · swig/swig · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
doxygen 'ignore' errors on backslash #3205
Open
@clintonstimpson

Description

@clintonstimpson
%module mytest

%feature("doxygen:ignore:exampleCpp", range="end");

/**
    A splendid function.

    \exampleCpp
      Splendid("world \"awesome\"\n")
    \endexampleCpp
 */
void Splendid(const char* str);

This gives me a warning: mytest.i:8: Warning 562: Expected Doxygen command: endexampleCpp.
The output is:

def Splendid(str):
    r"""
        A splendid function.


          Splendid("world \"awesome"
    ")
        \endexampleCpp
    """
    return _mytest.Splendid(str)

which is obviously incorrect.

If I add additional escaping by changing to \\"awesome\\" the warning goes away and the resulting docstring looks ok.

However, when running the doxygen tool on the same, but keeping the exampleCpp section (aliased to \code{.cpp}), it gives me 2 backslashes instead of a single one. I'd to have a single backslash, but not have swig give me a warning or incorrect output.

3E08

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0