diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/config.xml | 3 | ||||
-rw-r--r-- | src/pycode.l | 7 | ||||
-rw-r--r-- | src/pyscanner.l | 4 |
3 files changed, 13 insertions, 1 deletions
diff --git a/src/config.xml b/src/config.xml index 39e83ad..6158970 100644 --- a/src/config.xml +++ b/src/config.xml @@ -660,7 +660,8 @@ Go to the <a href="commands.html">next</a> section or return to the <br>Note: For files without extension you can use `no_extension` as a placeholder. <br>Note that for custom extensions you also need to set \ref cfg_file_patterns "FILE_PATTERNS" otherwise the - files are not read by doxygen. + files are not read by doxygen. When specifying `no_extension` you should add `*` + to the \ref cfg_file_patterns "FILE_PATTERNS". ]]> </docs> </option> diff --git a/src/pycode.l b/src/pycode.l index ea314da..cc00447 100644 --- a/src/pycode.l +++ b/src/pycode.l @@ -168,6 +168,8 @@ EXPCHAR [#(){}\[\],:.%/\\=`*~|&<>!;+-] NONEMPTYEXP [^ \t\n:] PARAMNONEMPTY [^ \t\n():] IDENTIFIER ({LETTER}|"_")({LETTER}|{DIGIT}|"_")* +SCOPE {IDENTIFIER}("."{IDENTIFIER})* +CALLANY "("[^)]*")" BORDER ([^A-Za-z0-9]) POUNDCOMMENT "##" @@ -341,6 +343,11 @@ TARGET ({IDENTIFIER}|"("{TARGET_LIST}")"|"["{TARGET_LIST}"]"|{ATTRIBU codify(yyscanner,"cls."); findMemberLink(yyscanner,*yyextra->code,&yytext[4]); } + "@"{SCOPE}{CALLANY}? { // decorator + startFontClass(yyscanner,"preprocessor"); + codify(yyscanner,yytext); + endFontClass(yyscanner); + } } <ClassDec>{IDENTIFIER} { diff --git a/src/pyscanner.l b/src/pyscanner.l index a136b52..4a9552e 100644 --- a/src/pyscanner.l +++ b/src/pyscanner.l @@ -113,6 +113,7 @@ struct pyscannerYY_state int search_count = 0; QCString argType; bool funcParamsEnd = FALSE; + std::vector<QCString> decorators; }; //----------------------------------------------------------------------------- @@ -175,6 +176,7 @@ NONEMPTYEXP [^ \t\n:] PARAMNONEMPTY [^ \t\n():] IDENTIFIER ({LETTER}|"_")({LETTER}|{DIGIT}|"_")* SCOPE {IDENTIFIER}("."{IDENTIFIER})* +CALL "("[^)]*")" BORDER ([^A-Za-z0-9]) TRISINGLEQUOTE {STRINGPREFIX}?"'''"(!)? @@ -335,6 +337,8 @@ STARTDOCSYMS "##" "@staticmethod" { yyextra->stat=TRUE; } + "@"{SCOPE}{CALL}? { // decorator + } {SCRIPTCOMMENT} { // Unix type script comment if (yyextra->yyLineNr != 1) REJECT; } |