summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDimitri van Heesch <dimitri@stack.nl>2015-12-27 11:22:30 (GMT)
committerDimitri van Heesch <dimitri@stack.nl>2015-12-27 11:22:30 (GMT)
commit8da86f8adfb826f13321c7d163431f9671ba20b7 (patch)
tree12b83f4bcf250e22fb44944568bd0dabb21b203b
parent303b5b58955fd7122fe361d5146f6a9334a41997 (diff)
downloadDoxygen-8da86f8adfb826f13321c7d163431f9671ba20b7.zip
Doxygen-8da86f8adfb826f13321c7d163431f9671ba20b7.tar.gz
Doxygen-8da86f8adfb826f13321c7d163431f9671ba20b7.tar.bz2
Bug 746361 - Doxygen thinks C++ class is Objective-C
-rw-r--r--src/scanner.l6
-rwxr-xr-xsrc/util.cpp2
2 files changed, 7 insertions, 1 deletions
diff --git a/src/scanner.l b/src/scanner.l
index d603824..fc6dc84 100644
--- a/src/scanner.l
+++ b/src/scanner.l
@@ -4093,6 +4093,7 @@ OPERATOR "operator"{B}*({ARITHOP}|{ASSIGNOP}|{LOGICOP}|{BITOP})
current_root->addSubEntry( current ) ;
current=new Entry;
initEntry();
+ language = current->lang = SrcLangExt_Cpp; // see bug746361
insideObjC=FALSE;
BEGIN( FindMembers );
}
@@ -5382,6 +5383,11 @@ OPERATOR "operator"{B}*({ARITHOP}|{ASSIGNOP}|{LOGICOP}|{BITOP})
unput(';');
current->reset();
initEntry();
+ if (insideObjC) // see bug746361
+ {
+ language = current->lang = SrcLangExt_Cpp;
+ insideObjC = FALSE;
+ }
if (isTypedef) // typedef of a class, put typedef keyword back
{
current->type.prepend("typedef");
diff --git a/src/util.cpp b/src/util.cpp
index 84e9126..6f3bc40 100755
--- a/src/util.cpp
+++ b/src/util.cpp
@@ -7038,7 +7038,7 @@ void initDefaultExtensionMapping()
updateLanguageMapping(".phtml", "php");
updateLanguageMapping(".m", "objective-c");
updateLanguageMapping(".M", "objective-c");
- updateLanguageMapping(".mm", "objective-c");
+ updateLanguageMapping(".mm", "c"); // see bug746361
updateLanguageMapping(".py", "python");
updateLanguageMapping(".pyw", "python");
updateLanguageMapping(".f", "fortran");