diff options
author | Dimitri van Heesch <doxygen@gmail.com> | 2021-05-02 09:30:09 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-05-02 09:30:09 (GMT) |
commit | e042aeceae7bb0dbee8e7602d3a20b388b94eb82 (patch) | |
tree | 472cae26af6b7fd1fb7798abf15dca7791f7bc09 /src | |
parent | 3463d27b600f7ce7c38354e45b86f030a1531928 (diff) | |
parent | 2e16aef612692d255ad6026396557bfa0f311dd4 (diff) | |
download | Doxygen-e042aeceae7bb0dbee8e7602d3a20b388b94eb82.zip Doxygen-e042aeceae7bb0dbee8e7602d3a20b388b94eb82.tar.gz Doxygen-e042aeceae7bb0dbee8e7602d3a20b388b94eb82.tar.bz2 |
Merge pull request #8427 from lcarlier/bug_anonymous_namespace
Fix bug linking C++ anonymous namespace
Diffstat (limited to 'src')
-rw-r--r-- | src/docparser.cpp | 16 |
1 files changed, 15 insertions, 1 deletions
diff --git a/src/docparser.cpp b/src/docparser.cpp index de28a65..a812406 100644 --- a/src/docparser.cpp +++ b/src/docparser.cpp @@ -724,7 +724,21 @@ static bool findDocsForMemberOrCompound(const QCString &commandName, // for symbols we need to normalize the separator, so A#B, or A\B, or A.B becomes A::B cmdArg = substitute(cmdArg,"#","::"); cmdArg = substitute(cmdArg,"\\","::"); - cmdArg = substitute(cmdArg,".","::"); + static bool extractAnonNs = Config_getBool(EXTRACT_ANON_NSPACES); + if (extractAnonNs && + cmdArg.startsWith("anonymous_namespace{") + ) + { + int rightBracePos = cmdArg.find("}", std::strlen("anonymous_namespace{")); + QCString leftPart = cmdArg.left(rightBracePos + 1); + QCString rightPart = cmdArg.right(cmdArg.size() - rightBracePos - 1); + rightPart = substitute(rightPart, ".", "::"); + cmdArg = leftPart + rightPart; + } + else + { + cmdArg = substitute(cmdArg,".","::"); + } int l=(int)cmdArg.length(); |