diff options
author | Dimitri van Heesch <doxygen@gmail.com> | 2020-08-30 19:18:58 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-08-30 19:18:58 (GMT) |
commit | ed2fb0d0e6d6fee34a698c48dff925b92e7661c0 (patch) | |
tree | d10fdf787e08f8cd11eb1e90bfc3f5a9604fcca7 | |
parent | 075771fd46ee7e6e4c7572b84cff194e887eddf4 (diff) | |
parent | 1d8610c90ba279bb207f0d45f96cef3054ff34eb (diff) | |
download | Doxygen-ed2fb0d0e6d6fee34a698c48dff925b92e7661c0.zip Doxygen-ed2fb0d0e6d6fee34a698c48dff925b92e7661c0.tar.gz Doxygen-ed2fb0d0e6d6fee34a698c48dff925b92e7661c0.tar.bz2 |
Merge pull request #7981 from albert-github/feature/bug_647654
bug_647654 Special command \fn fails when first argument of PHP function is call-by-reference
-rw-r--r-- | src/declinfo.l | 1 | ||||
-rw-r--r-- | src/scanner.l | 15 |
2 files changed, 12 insertions, 4 deletions
diff --git a/src/declinfo.l b/src/declinfo.l index 2f497f9..014ef75 100644 --- a/src/declinfo.l +++ b/src/declinfo.l @@ -149,6 +149,7 @@ ID "$"?([a-z_A-Z\x80-\xFF][a-z_A-Z0-9\x80-\xFF]*)|(@[0-9]+) addType(yyscanner); } <Start>{B}*"("({ID}"::")*{B}*[&*]({B}*("const"|"volatile"){B}+)? { + if (yyextra->insidePHP) REJECT; addType(yyscanner); QCString text=yytext; yyextra->type+=text.stripWhiteSpace(); diff --git a/src/scanner.l b/src/scanner.l index 70f15d6..e56f151 100644 --- a/src/scanner.l +++ b/src/scanner.l @@ -6506,10 +6506,17 @@ OPERATOR "operator"{B}*({ARITHOP}|{ASSIGNOP}|{LOGICOP}|{BITOP}) BEGIN( ReadFuncArgType ) ; } <Prototype>"("({ID}"::")*({B}*[&*])+ { - yyextra->current->type+=yyextra->current->name+yytext; - yyextra->current->name.resize(0); - BEGIN( PrototypePtr ); - } + if (yyextra->insidePHP) // reference parameter + { + REJECT; + } + else + { + yyextra->current->type+=yyextra->current->name+yytext; + yyextra->current->name.resize(0); + BEGIN( PrototypePtr ); + } + } <PrototypePtr>{SCOPENAME} { yyextra->current->name+=yytext; } |