File tree Expand file tree Collapse file tree 1 file changed +30
-2
lines changed Expand file tree Collapse file tree 1 file changed +30
-2
lines changed Original file line number Diff line number Diff line change @@ -920,11 +920,39 @@ NUMBER {INTEGER_NUMBER}|{FLOAT_NUMBER}
920920 BEGIN (ArgCopyCComment);
921921 }
922922<FindDefineArgs>{CPPC}[/!].*\n/{B}*{CPPC}[/!] { // replace multi line C++ style comment by C style comment
923- yyextra->defArgsStr +=QCString (" /**" )+&yytext[3 ];
923+ if (Config_getBool (MULTILINE_CPP_IS_BRIEF) && !Config_getBool (QT_AUTOBRIEF))
924+ {
925+ if (yytext[3 ]==' <' ) // preserve < before @brief
926+ {
927+ yyextra->defArgsStr +=QCString (" /**< @brief " )+&yytext[4 ];
928+ }
929+ else
930+ {
931+ yyextra->defArgsStr +=QCString (" /** @brief " )+&yytext[3 ];
932+ }
933+ }
934+ else
935+ {
936+ yyextra->defArgsStr +=QCString (" /**" )+&yytext[3 ];
937+ }
924938 BEGIN (ArgCopyCppComment);
925939 }
926940<FindDefineArgs>{CPPC}[/!].*\n { // replace C++ single line style comment by C style comment
927- yyextra->defArgsStr +=QCString (" /**" )+&yytext[3 ]+" */" ;
941+ if (Config_getBool (QT_AUTOBRIEF))
942+ {
943+ yyextra->defArgsStr +=QCString (" /**" )+&yytext[3 ]+" */" ;
944+ }
945+ else // add brief command explicitly when translating C++ to C comment style
946+ {
947+ if (yytext[3 ]==' <' ) // preserve < before @brief
948+ {
949+ yyextra->defArgsStr +=QCString (" /**< @brief " )+&yytext[4 ]+" */" ;
950+ }
951+ else
952+ {
953+ yyextra->defArgsStr +=QCString (" /** @brief " )+&yytext[3 ]+" */" ;
954+ }
955+ }
928956 }
929957<FindDefineArgs>{CPPC}.*\n { // replace C++ single line style comment by C style comment
930958 yyextra->defArgsStr +=QCString (" /*" )+&yytext[2 ]+" */" ;
You can’t perform that action at this time.
0 commit comments