22%option never-interactive
23%option prefix="pyscannerYY"
25%option extra-type="struct pyscannerYY_state *"
29#define YY_TYPEDEF_YY_SCANNER_T
65#define DBG_CTX(x) do { } while(0)
68#define YY_NO_UNISTD_H 1
70#define unput_string(yytext,yyleng) do { for (int i=(int)yyleng-1;i>=0;i--) unput(yytext[i]); } while(0)
161#define YY_INPUT(buf,result,max_size) result=yyread(yyscanner,buf,max_size);
Abstract interface for outline parsers.
This is an alternative implementation of QCString.
Text streaming class that buffers data.
std::unordered_map< std::string, std::string > StringUnorderedMap
#define lineCount(s, len)
static void newEntry(yyscan_t yyscanner)
static void incLineNr(yyscan_t yyscanner)
static void docVariable(yyscan_t yyscanner, const char *s)
static void initSpecialBlock(yyscan_t yyscanner)
static void initTriSingleQuoteBlock(yyscan_t yyscanner)
static int computeIndent(const char *s)
static void addFrom(yyscan_t yyscanner, bool all)
static void setProtection(yyscan_t yyscanner)
static void initParser(yyscan_t yyscanner)
static void endOfDef(yyscan_t yyscanner, int correction=0)
static QCString findPackageScope(yyscan_t yyscanner, const QCString &fileName)
static int yyread(yyscan_t yyscanner, char *buf, int max_size)
static void searchFoundClass(yyscan_t yyscanner)
static const char * stateToString(int state)
static QCString findPackageScopeFromPath(yyscan_t yyscanner, const QCString &path)
static void newVariable(yyscan_t yyscanner)
static void initTriDoubleQuoteBlock(yyscan_t yyscanner)
static void handleCommentBlock(yyscan_t yyscanner, const QCString &doc, bool brief)
static void searchFoundDef(yyscan_t yyscanner)
static void addEntry(yyscan_t yyscanner)
static const char * getLexerFILE()
static void startCommentBlock(yyscan_t yyscanner, bool brief)
static void newFunction(yyscan_t yyscanner)
static void addVariable(yyscan_t yyscanner)
static void addToString(yyscan_t yyscanner, const char *s)
static void initEntry(yyscan_t yyscanner)
Some helper functions for std::string.
std::shared_ptr< Entry > previous
std::shared_ptr< Entry > current
StringUnorderedMap packageNameCache
std::shared_ptr< Entry > bodyEntry
TextStream decoratorCommentStr
std::shared_ptr< Entry > current_root
bool packageCommentAllowed
OutlineParserInterface * thisParser
std::vector< QCString > decorators
CommentScanner commentScanner
MethodTypes
Kind of method.
Protection
Protection level of members.
Specifier
Virtualness of a member.
A bunch of utility functions.
178HEXNUMBER "0"[xX][0-9a-fA-F]+[lL]?
179OCTNUMBER "0"[0-7]+[lL]?
180NUMBER {DIGIT}+[lLjJ]?
181INTNUMBER {HEXNUMBER}|{OCTNUMBER}|{NUMBER}
182FLOATNUMBER {DIGIT}+"."{DIGIT}+([eE][+\-]?{DIGIT}+)?[jJ]?
184LETTER [A-Za-z\x80-\xFF]
185NONEMPTY [A-Za-z0-9_\x80-\xFF]
186EXPCHAR [#(){}\[\],:.%/\\=`*~|&<>!;+-]
187PARAMNONEMPTY [^ \t\n():]
188IDENTIFIER ({LETTER}|"_")({LETTER}|{DIGIT}|"_")*
189SCOPE {IDENTIFIER}("."{IDENTIFIER})*
191TRISINGLEQUOTE {STRINGPREFIX}?"'''"(!)?
192TRIDOUBLEQUOTE {STRINGPREFIX}?"\"\"\""(!)?
193ENDTRISINGLEQUOTE "'''"
194ENDTRIDOUBLEQUOTE "\"\"\""
195LONGSTRINGCHAR [^\\"']
197LONGSTRINGITEM ({LONGSTRINGCHAR}|{ESCAPESEQ})
198SMALLQUOTE ("\"\""|"\""|"'"|"''")
199LONGSTRINGBLOCK ({LONGSTRINGITEM}|{SMALLQUOTE})
201STRINGPREFIX ("r"|"u"|"ur"|"R"|"U"|"UR"|"Ur"|"uR")
202POUNDCOMMENT "#"[^#\n][^\n]*
207LINENR {B}*[1-9][0-9]*
208FILEICHAR [a-z_A-Z0-9\x80-\xFF\\:\\\/\-\+=&#@~]
209FILEECHAR [a-z_A-Z0-9\x80-\xFF\-\+=&#@~]
210FILECHARS {FILEICHAR}*{FILEECHAR}+
211HFILEMASK {FILEICHAR}*("."{FILEICHAR}+)+{FILECHARS}*
212VFILEMASK {FILECHARS}("."{FILECHARS})*
213FILEMASK {VFILEMASK}|{HFILEMASK}
216ID [a-z_A-Z%]+{IDSYM}*
239%x FunctionTypeAnnotation
240%x FunctionParamDefVal
259%x SingleQuoteStringIgnore
260%x DoubleQuoteStringIgnore
280 DBG_CTX((stderr,
"Found def at %d\n",yyextra->yyLineNr));
283 BEGIN( FunctionDec );
285 ^{B}"async"{BB}"def"{BB} {
286 DBG_CTX((stderr,
"Found async def at %d\n",yyextra->yyLineNr));
289 BEGIN( FunctionDec );
293 BEGIN( FunctionDec );
295 "async"{BB}"def"{BB} {
297 BEGIN( FunctionDec );
301 DBG_CTX((stderr,
"Found class at %d\n",yyextra->yyLineNr));
312 yyextra->packageCommentAllowed =
FALSE;
318 yyextra->packageCommentAllowed =
FALSE;
321 ^{B}{IDENTIFIER}/{B}"="{B}"property" {
322 yyextra->current->section = EntryType::makeVariable();
325 yyextra->current->fileName = yyextra->fileName;
326 yyextra->current->startLine = yyextra->yyLineNr;
327 yyextra->current->bodyLine = yyextra->yyLineNr;
328 yyextra->packageCommentAllowed =
FALSE;
QCString stripWhiteSpace() const
returns a copy of this string with leading and trailing whitespace removed
331 ^{B}{IDENTIFIER}/{B}"="[^=] {
332 if (yyextra->searchCount>0) REJECT;
334 yyextra->current->section = EntryType::makeVariable();
336 yyextra->current->fileName = yyextra->fileName;
337 yyextra->current->startLine = yyextra->yyLineNr;
338 yyextra->current->bodyLine = yyextra->yyLineNr;
339 yyextra->packageCommentAllowed =
FALSE;
342 ^{B}{IDENTIFIER}/{B}":" {
343 if (yyextra->searchCount>0) REJECT;
345 if (
id ==
"try" ||
id ==
"else" ||
id ==
"except" ||
id ==
"finally") REJECT;
347 yyextra->current->section = EntryType::makeVariable();
348 yyextra->current->name = id;
349 yyextra->current->fileName = yyextra->fileName;
350 yyextra->current->startLine = yyextra->yyLineNr;
351 yyextra->current->bodyLine = yyextra->yyLineNr;
352 yyextra->packageCommentAllowed =
FALSE;
355 {B}{IDENTIFIER}/({B},{B}{IDENTIFIER})*{B}")"*{B}"="[^=] {
359 if (yyextra->searchCount>1) REJECT;
361 yyextra->current->section = EntryType::makeVariable();
363 yyextra->current->fileName = yyextra->fileName;
364 yyextra->current->startLine = yyextra->yyLineNr;
365 yyextra->current->bodyLine = yyextra->yyLineNr;
366 yyextra->packageCommentAllowed =
FALSE;
static void addVariable(yyscan_t yyscanner, QCString type, QCString name)
370 yyextra->stringContext=YY_START;
371 yyextra->copyString=
nullptr;
372 yyextra->packageCommentAllowed =
FALSE;
373 BEGIN( SingleQuoteString );
376 yyextra->stringContext=YY_START;
377 yyextra->copyString=
nullptr;
378 yyextra->packageCommentAllowed =
FALSE;
379 BEGIN( DoubleQuoteString );
382 yyextra->isStatic=
TRUE;
386 yyextra->decoratorRound = 1;
387 yyextra->copyString=
nullptr;
394 if (yyextra->yyLineNr != 1) REJECT;
401 yyextra->packageCommentAllowed =
FALSE;
413 BEGIN(TripleComment);
418 BEGIN(TripleComment);
421 {B}{STARTDOCSYMS}/[^#] {
423 yyextra->packageCommentAllowed =
FALSE;
425 BEGIN(SpecialComment);
428 yyextra->searchCount++;
431 if (yyextra->searchCount>0)
433 yyextra->searchCount--;
437 yyextra->current->doc.clear();
438 yyextra->current->brief.clear();
452 {IDENTIFIER}({B}"."{B}{IDENTIFIER})* {
453 yyextra->packageName=yytext;
475 {IDENTIFIER}/{B}","{B} {
478 {IDENTIFIER}/{B}")" {
483 if (!yyextra->importTuple)
490 if (!yyextra->importTuple)
498 yyextra->importTuple=
TRUE;
501 yyextra->importTuple=
FALSE;
516 {IDENTIFIER}({B}"."{B}{IDENTIFIER})* {
518 yyextra->current->fileName = yyextra->fileName;
520 yyextra->current->section=EntryType::makeUsingDecl();
521 yyextra->current_root->moveToSubEntryAndRefresh(yyextra->current);
static void initEntry(yyscan_t yyscanner)
QCString substitute(const QCString &s, const QCString &src, const QCString &dst)
substitute all occurrences of src in s by dst
QCString removeRedundantWhiteSpace(const QCString &s)
538 ("cls"|"self")"."{IDENTIFIER}/{B}[,)] {
539 const char *s = strchr(yytext,
'.'); s++;
540 DBG_CTX((stderr,
"Found instance method variable %s in %s at %d\n",s,
qPrint(yyextra->current_root->name.data(),yyextra->yyLineNr)));
const char * qPrint(const char *s)
544 ("cls"|"self")"."{IDENTIFIER}/{B}"=" {
545 const char *s = strchr(yytext,
'.'); s++;
546 DBG_CTX((stderr,
"Found instance method variable %s in %s at %d\n",s,
qPrint(yyextra->current_root->name.data(),yyextra->yyLineNr)));
548 BEGIN( SearchSkipValue );
550 ("cls"|"self")"."{IDENTIFIER}/{B}":" {
551 const char *s = strchr(yytext,
'.'); s++;
552 DBG_CTX((stderr,
"Found instance method variable %s in %s at %d\n",s,
qPrint(yyextra->current_root->name.data(),yyextra->yyLineNr)));
558 BEGIN(TripleComment);
563 BEGIN(TripleComment);
566 {STARTDOCSYMS}/[^#] {
568 BEGIN(SpecialComment);
573 yyextra->stringContext=YY_START;
574 yyextra->copyString=
nullptr;
575 BEGIN( SingleQuoteString );
578 yyextra->stringContext=YY_START;
579 yyextra->copyString=
nullptr;
580 BEGIN( DoubleQuoteString );
584 yyextra->current->doc.clear();
585 yyextra->current->brief.clear();
587 BEGIN( SearchSkipValue );
596 yyextra->braceCount=0;
599 yyextra->current->type+=*yytext;
600 yyextra->braceCount++;
603 yyextra->current->type+=*yytext;
604 yyextra->braceCount--;
607 yyextra->stringContext=YY_START;
608 yyextra->copyString=
nullptr;
609 BEGIN( SingleQuoteString );
612 yyextra->stringContext=YY_START;
613 yyextra->copyString=
nullptr;
614 BEGIN( DoubleQuoteString );
617 if (yyextra->braceCount==0)
619 yyextra->current->type = yyextra->current->type.stripWhiteSpace();
621 BEGIN(SearchSkipValue);
625 yyextra->current->type+=*yytext;
629 yyextra->current->type = yyextra->current->type.stripWhiteSpace();
632 BEGIN(SearchMemVars);
635 yyextra->current->type+=
' ';
639 yyextra->current->type+=*yytext;
643<SearchSkipValue,VariableDec>{
646 yyextra->startInit =
TRUE;
647 yyextra->current->initializer.str(yytext);
648 yyextra->current->initializer <<
" ";
651 yyextra->current->initializer << yytext;
655 if (yyextra->current->type.isEmpty()) yyextra->current->type =
"int";
656 yyextra->current->initializer << yytext;
659 if (yyextra->current->type.isEmpty()) yyextra->current->type =
"float";
660 yyextra->current->initializer << yytext;
663 if (yyextra->current->type.isEmpty()) yyextra->current->type =
"bool";
664 yyextra->current->initializer << yytext;
667 if (yyextra->current->type.isEmpty()) yyextra->current->type =
"str";
668 yyextra->current->initializer << yytext;
669 yyextra->copyString=&yyextra->current->initializer;
670 yyextra->stringContext=YY_START;
671 BEGIN( SingleQuoteString );
673 {STRINGPREFIX}?"\"" {
674 if (yyextra->current->type.isEmpty()) yyextra->current->type =
"str";
675 yyextra->current->initializer << yytext;
676 yyextra->copyString=&yyextra->current->initializer;
677 yyextra->stringContext=YY_START;
678 BEGIN( DoubleQuoteString );
681 if (yyextra->current->type.isEmpty()) yyextra->current->type =
"str";
682 yyextra->current->initializer << yytext;
683 yyextra->doubleQuote=
TRUE;
684 yyextra->copyString=&yyextra->current->initializer;
685 yyextra->stringContext=YY_START;
690 if (yyextra->current->type.isEmpty()) yyextra->current->type =
"str";
691 yyextra->current->initializer << yytext;
692 yyextra->doubleQuote=
FALSE;
693 yyextra->copyString=&yyextra->current->initializer;
694 yyextra->stringContext=YY_START;
700 yyextra->current->type =
"tuple";
702 yyextra->current->initializer << *yytext;
703 yyextra->atomStart=
'(';
704 yyextra->atomEnd=
')';
705 yyextra->atomCount=1;
706 yyextra->atomContext=YY_START;
707 BEGIN( VariableAtom );
710 if (yyextra->startInit) yyextra->current->type =
"list";
711 yyextra->current->initializer << *yytext;
712 yyextra->atomStart=
'[';
713 yyextra->atomEnd=
']';
714 yyextra->atomCount=1;
715 yyextra->atomContext=YY_START;
716 BEGIN( VariableAtom );
719 if (yyextra->startInit) yyextra->current->type =
"dict";
720 yyextra->current->initializer << *yytext;
721 yyextra->atomStart=
'{';
722 yyextra->atomEnd=
'}';
723 yyextra->atomCount=1;
724 yyextra->atomContext=YY_START;
725 BEGIN( VariableAtom );
728 yyextra->current->initializer << yytext;
733 if (yyextra->current->type.isEmpty())
735 for (
const auto &child : yyextra->current_root->children())
737 if (child->name ==
QCString(yytext))
739 yyextra->current->type = child->type;
744 yyextra->startInit =
FALSE;
745 yyextra->current->initializer << yytext;
748 yyextra->startInit =
FALSE;
749 yyextra->current->initializer << *yytext;
753 {STARTDOCSYMS}/[^#] {
755 BEGIN(SpecialComment);
761 BEGIN(SearchMemVars);
765 BEGIN(SearchMemVars);
770 \n{B}/{IDENTIFIER}[^{LETTER}{DIGIT}_] {
782 yyextra->current->program << yytext;
796 yyextra->current->program << yytext;
804 yyextra->current->program << yytext;
808 if (yyextra->curIndent<=yyextra->indent)
816 yyextra->current->program << yytext;
820 yyextra->current->program << yytext;
821 yyextra->stringContext=YY_START;
822 yyextra->specialBlock =
FALSE;
823 yyextra->copyString=&yyextra->current->program;
824 BEGIN( SingleQuoteString );
827 yyextra->current->program << yytext;
828 yyextra->stringContext=YY_START;
829 yyextra->specialBlock =
FALSE;
830 yyextra->copyString=&yyextra->current->program;
831 BEGIN( DoubleQuoteString );
834 yyextra->current->program << yytext;
835 yyextra->specialBlock =
FALSE;
838 yyextra->current->program << yytext;
841 yyextra->current->program << yytext;
845 yyextra->current->program << yytext;
848 yyextra->current->program << *yytext;
849 yyextra->specialBlock =
FALSE;
853 yyextra->current->program << yytext;
855 BEGIN(TripleComment);
859 yyextra->current->program << yytext;
861 BEGIN(TripleComment);
869 yyextra->current->name = yytext;
870 yyextra->current->name = yyextra->current->name.stripWhiteSpace();
874 yyextra->specialBlock =
TRUE;
875 yyextra->bodyEntry = yyextra->current;
876 yyextra->current->bodyLine = yyextra->yyLineNr;
881 yyextra->defVal.str(std::string());
882 yyextra->braceCount = 0;
883 BEGIN(FunctionTypeAnnotation);
886 yyextra->funcParamsEnd =
FALSE;
887 yyextra->current->bodyLine = yyextra->yyLineNr;
888 BEGIN(FunctionParams);
891 if (yyextra->current->argList.empty())
893 yyextra->current->argList.setNoParameters(
TRUE);
896 yyextra->funcParamsEnd =
TRUE;
QCString argListToString(const ArgumentList &al, bool useCanonicalType, bool showDefVals)
905 if (!yyextra->argType.isEmpty())
909 a.
type = yyextra->argType;
910 yyextra->current->argList.push_back(a);
911 yyextra->argType =
"";
This class contains the information about the argument of a function or template.
916 yyextra->argType = yytext;
922 a.
type = yyextra->argType;
923 yyextra->current->argList.push_back(a);
924 yyextra->argType =
"";
929 yyextra->defVal.str(std::string());
930 yyextra->braceCount = 0;
931 BEGIN(FunctionParamDefVal);
934 if (!yyextra->argType.isEmpty())
938 a.
type = yyextra->argType;
939 yyextra->current->argList.push_back(a);
940 yyextra->argType =
"";
946 yyextra->defVal.str(std::string());
947 yyextra->braceCount = 0;
948 BEGIN(FunctionAnnotation);
957<FunctionTypeAnnotation>{
961 ++yyextra->braceCount;
962 yyextra->defVal << *yytext;
967 --yyextra->braceCount;
968 yyextra->defVal << *yytext;
971 if (yyextra->braceCount == 0)
973 yyextra->current->type = yyextra->defVal.str();
978 yyextra->defVal << *yytext;
981 yyextra->defVal << *yytext;
982 yyextra->copyString=&yyextra->defVal;
983 yyextra->stringContext=FunctionTypeAnnotation;
984 BEGIN(SingleQuoteString);
987 yyextra->defVal << *yytext;
988 yyextra->copyString=&yyextra->defVal;
989 yyextra->stringContext=FunctionTypeAnnotation;
990 BEGIN(DoubleQuoteString);
993 yyextra->defVal << *yytext;
997 yyextra->defVal << *yytext;
1001<FunctionAnnotation>{
1005 ++yyextra->braceCount;
1006 yyextra->defVal << *yytext;
1010 --yyextra->braceCount;
1011 yyextra->defVal << *yytext;
1016 if (yyextra->braceCount == 0)
1018 if (!yyextra->current->argList.empty())
1019 yyextra->current->argList.back().type += yyextra->defVal.str();
1022 BEGIN(FunctionParams);
1027 --yyextra->braceCount;
1028 yyextra->defVal << *yytext;
1032 yyextra->defVal << *yytext;
1033 yyextra->copyString=&yyextra->defVal;
1034 yyextra->stringContext=FunctionAnnotation;
1035 BEGIN(SingleQuoteString);
1038 yyextra->defVal << *yytext;
1039 yyextra->copyString=&yyextra->defVal;
1040 yyextra->stringContext=FunctionAnnotation;
1041 BEGIN(DoubleQuoteString);
1044 yyextra->defVal << *yytext;
1048 yyextra->defVal << *yytext;
1052<FunctionParamDefVal>{
1056 ++yyextra->braceCount;
1057 yyextra->defVal << *yytext;
1061 --yyextra->braceCount;
1062 yyextra->defVal << *yytext;
1066 if (yyextra->braceCount == 0)
1068 if (!yyextra->current->argList.empty())
1072 BEGIN(FunctionParams);
1077 --yyextra->braceCount;
1078 yyextra->defVal << *yytext;
1083 yyextra->defVal << *yytext;
1084 yyextra->copyString=&yyextra->defVal;
1085 yyextra->stringContext=FunctionParamDefVal;
1086 BEGIN( SingleQuoteString );
1089 yyextra->defVal << *yytext;
1090 yyextra->copyString=&yyextra->defVal;
1091 yyextra->stringContext=FunctionParamDefVal;
1092 BEGIN( DoubleQuoteString );
1095 yyextra->defVal << *yytext;
1099 yyextra->defVal << *yytext;
1105 \n/{IDENTIFIER}{BB} {
1109 for (i=(
int)yyleng-1;i>=0;i--)
1120 yyextra->current->program << yytext;
1127 for (i=(
int)yyleng-1;i>=0;i--)
1138 yyextra->current->program << yytext;
1142 yyextra->current->program << yytext;
1150 DBG_CTX((stderr,
"yyextra->curIndent=%d yyextra->indent=%d\n",yyextra->curIndent,yyextra->indent));
1151 if (yyextra->curIndent<=yyextra->indent)
1155 yyextra->indent=yyextra->curIndent;
1163 yyextra->current->program << yytext;
1167 yyextra->current->program << *yytext;
1168 yyextra->stringContext=YY_START;
1169 yyextra->specialBlock =
FALSE;
1170 yyextra->copyString=&yyextra->current->program;
1171 BEGIN( SingleQuoteString );
1174 yyextra->current->program << *yytext;
1175 yyextra->stringContext=YY_START;
1176 yyextra->specialBlock =
FALSE;
1177 yyextra->copyString=&yyextra->current->program;
1178 BEGIN( DoubleQuoteString );
1181 yyextra->current->program << yytext;
1182 yyextra->specialBlock =
FALSE;
1186 yyextra->current->program << *yytext;
1190 yyextra->current->program << yytext;
1193 yyextra->specialBlock =
FALSE;
1194 yyextra->current->program << *yytext;
1198 yyextra->current->program << yytext;
1200 BEGIN(TripleComment);
1205 yyextra->current->program << yytext;
1207 BEGIN(TripleComment);
1211<ClassDec>{IDENTIFIER} {
1212 if (yyextra->current->type.isEmpty())
1214 yyextra->current->type =
"class";
1217 yyextra->current->section = EntryType::makeClass();
1218 yyextra->current->name = yytext;
1223 if (yyextra->current_root->section.isScope())
1226 yyextra->current->name.prepend(yyextra->current_root->name+
"::");
1229 yyextra->current->name = yyextra->current->name.stripWhiteSpace();
1230 yyextra->current->fileName = yyextra->fileName;
1231 yyextra->docBlockContext = YY_START;
1232 yyextra->docBlockInBody =
FALSE;
1233 yyextra->docBlockJavaStyle =
FALSE;
1234 yyextra->docBlock.clear();
1236 BEGIN(ClassInheritance);
1244 yyextra->specialBlock =
TRUE;
1245 yyextra->current->bodyLine = yyextra->yyLineNr;
1246 yyextra->current->program.str(std::string());
1247 BEGIN(ClassCaptureIndent);
1251 yyextra->current->extends.emplace_back(
1257 yyextra->stringContext=YY_START;
1258 BEGIN( SingleQuoteStringIgnore );
1261 yyextra->stringContext=YY_START;
1262 BEGIN( DoubleQuoteStringIgnore );
1266<SingleQuoteStringIgnore>{
1268 BEGIN(yyextra->stringContext);
1272<DoubleQuoteStringIgnore>{
1274 BEGIN(yyextra->stringContext);
1279<ClassCaptureIndent>{
1283 yyextra->current->program << yytext;
1288 yyextra->current->program << yytext;
1289 BEGIN(TripleComment);
1293 yyextra->current->program << yytext;
1294 BEGIN(TripleComment);
1296 {STARTDOCSYMS}[#]* {
1298 BEGIN(SpecialComment);
1303 yyextra->current->program << yytext;
1306 yyextra->bodyEntry = yyextra->current;
1307 DBG_CTX((stderr,
"setting indent %d\n",yyextra->curIndent));
1313 ""/({NONEMPTY}|{EXPCHAR}) {
1317 yyextra->current->program << yytext;
1326 ":"{B}{IDENTIFIER} {
1327 yyextra->startInit =
FALSE;
1328 yyextra->current->type =
substitute(yytext,
":",
"");
1330 {STARTDOCSYMS}"<"/.* {
1332 yyextra->packageCommentAllowed =
FALSE;
1334 yyextra->docBlockContext = VariableEnd;
1335 BEGIN(SpecialComment);
1338 BEGIN( VariableEnd );
1342 BEGIN( VariableEnd );
1348 yyextra->current->initializer << *yytext;
1349 if (yyextra->atomStart==*yytext)
1351 yyextra->atomCount++;
1355 yyextra->current->initializer << *yytext;
1356 if (yyextra->atomEnd==*yytext)
1358 yyextra->atomCount--;
1360 if (yyextra->atomCount==0)
1362 yyextra->startInit =
FALSE;
1363 BEGIN(yyextra->atomContext);
1367 yyextra->specialBlock =
FALSE;
1368 yyextra->current->program << yytext;
1370 BEGIN(TripleComment);
1374 yyextra->specialBlock =
FALSE;
1375 yyextra->current->program << yytext;
1377 BEGIN(TripleComment);
1380 yyextra->stringContext=YY_START;
1381 yyextra->current->initializer <<
"'";
1382 yyextra->copyString=&yyextra->current->initializer;
1383 BEGIN( SingleQuoteString );
1386 yyextra->stringContext=YY_START;
1387 yyextra->current->initializer <<
"\"";
1388 yyextra->copyString=&yyextra->current->initializer;
1389 BEGIN( DoubleQuoteString );
1392 yyextra->current->initializer << yytext;
1395 yyextra->current->initializer << *yytext;
1398 yyextra->current->initializer << *yytext;
std::string_view stripWhiteSpace(std::string_view s)
Given a string view s, returns a new, narrower view on that string, skipping over any leading or trai...
1423 {ENDTRIDOUBLEQUOTE} |
1424 {ENDTRISINGLEQUOTE} {
1426 if (yyextra->doubleQuote==(yytext[0]==
'"'))
1428 if (yyextra->specialBlock)
1430 QCString actualDoc=yyextra->docBlock;
1431 if (!yyextra->docBlockSpecial)
1436 actualDoc.
prepend(
"@iverbatim\n");
1437 actualDoc.
append(
"@endiverbatim ");
1443 else if (yyextra->packageCommentAllowed)
1445 QCString actualDoc=yyextra->docBlock;
1446 if (!yyextra->docBlockSpecial)
1451 actualDoc.
prepend(
"@iverbatim\n");
1452 actualDoc.
append(
"@endiverbatim ");
1455 if (yyextra->moduleScope.startsWith(
"__") && yyextra->moduleScope.endsWith(
"__"))
1457 actualDoc.
prepend(
"\\namespace \\"+yyextra->moduleScope+
" ");
1461 actualDoc.
prepend(
"\\namespace "+yyextra->moduleScope+
" ");
1465 if ((yyextra->docBlockContext==ClassBody ) ||
1466 yyextra->docBlockContext==FunctionBody)
1468 yyextra->current->program << yyextra->docBlock;
1469 yyextra->current->program << yytext;
1476 BEGIN(yyextra->docBlockContext);
1480 yyextra->docBlock += yytext;
1482 yyextra->packageCommentAllowed =
FALSE;
QCString & prepend(const char *s)
bool isEmpty() const
Returns TRUE iff the string is empty.
QCString & append(char c)
static void handleCommentBlock(yyscan_t yyscanner, const QCString &doc, bool brief)
void stripIndentationVerbatim(QCString &doc, const int indentationLevel)
1487 if (yyextra->firstPass && yyextra->docBlockSpecial && yyleng >= yyextra->curIndent)
1488 yyextra->docBlock += yytext + yyextra->curIndent;
1490 yyextra->docBlock += yytext;
1493 yyextra->docBlock += yytext;
1497 yyextra->docBlock += yytext;
1499 {CMD}"ifile"{B}+"\""[^\n\"]+"\"" {
1500 yyextra->fileName = &yytext[6];
1501 yyextra->fileName = yyextra->fileName.stripWhiteSpace();
1502 yyextra->fileName = yyextra->fileName.mid(1,yyextra->fileName.length()-2);
1503 yyextra->docBlock+=yytext;
1505 {CMD}"ifile"{B}+{FILEMASK} {
1506 yyextra->fileName = &yytext[6];
1507 yyextra->fileName = yyextra->fileName.stripWhiteSpace();
1508 yyextra->docBlock+=yytext;
1510 {CMD}"iline"{LINENR}/[\n\.] |
1511 {CMD}"iline"{LINENR}{B} {
1516 warn(yyextra->fileName,yyextra->yyLineNr,
"Invalid line number '{}' for iline command",yytext);
1520 yyextra->yyLineNr = nr;
1522 yyextra->docBlock+=yytext;
int toInt(bool *ok=nullptr, int base=10) const
#define warn(file, line, fmt,...)
1524 ({CMD}{CMD}){ID}/[^a-z_A-Z0-9] {
1525 yyextra->docBlock+=yytext;
1528 yyextra->docBlock += yytext;
1531 yyextra->docBlock += yytext;
1539 yyextra->docBlock+=
'\n';
1540 yyextra->docBrief =
FALSE;
1543 {CMD}"ifile"{B}+"\""[^\n\"]+"\"" {
1544 yyextra->fileName = &yytext[6];
1545 yyextra->fileName = yyextra->fileName.stripWhiteSpace();
1546 yyextra->fileName = yyextra->fileName.mid(1,yyextra->fileName.length()-2);
1547 yyextra->docBlock+=yytext;
1549 {CMD}"ifile"{B}+{FILEMASK} {
1550 yyextra->fileName = &yytext[6];
1551 yyextra->fileName = yyextra->fileName.stripWhiteSpace();
1552 yyextra->docBlock+=yytext;
1554 {CMD}"iline"{LINENR}/[\n\.] |
1555 {CMD}"iline"{LINENR}{B} {
1560 warn(yyextra->fileName,yyextra->yyLineNr,
"Invalid line number '{}' for iline command",yytext);
1564 yyextra->yyLineNr = nr;
1566 yyextra->docBlock+=yytext;
1568 ({CMD}{CMD}){ID}/[^a-z_A-Z0-9] {
1569 yyextra->docBlock+=yytext;
1573 int extraSpaces = std::max(0,
static_cast<int>(yyleng-9-yyextra->curIndent-2));
1574 indent.
fill(
' ',extraSpaces);
1576 yyextra->docBlock +=
"\\ilinebr ";
1577 yyextra->docBlock += indent;
void fill(char c, int len=-1)
Fills a string with a predefined character.
1580 yyextra->docBlock+=yytext;
1584 if (yyextra->docBlockContext == VariableEnd)
1592 BEGIN(yyextra->docBlockContext);
1595 yyextra->docBlock+=*yytext;
1612 BEGIN(yyextra->stringContext);
1635 BEGIN(yyextra->stringContext);
1646 {ENDTRIDOUBLEQUOTE} |
1647 {ENDTRISINGLEQUOTE} {
1648 *yyextra->copyString << yytext;
1649 if (yyextra->doubleQuote==(yytext[0]==
'"'))
1651 BEGIN(yyextra->stringContext);
1656 ({LONGSTRINGBLOCK}) {
1658 *yyextra->copyString << yytext;
1662 *yyextra->copyString << yytext;
1665 *yyextra->copyString << *yytext;
1671 yyextra->doubleQuote=
TRUE;
1672 yyextra->decoratorCommentStr.str(std::string());
1673 yyextra->copyString=&yyextra->decoratorCommentStr;
1674 yyextra->stringContext=YY_START;
1675 BEGIN(TripleString);
1679 yyextra->doubleQuote=
FALSE;
1680 yyextra->decoratorCommentStr.str(std::string());
1681 yyextra->copyString=&yyextra->decoratorCommentStr;
1682 yyextra->stringContext=YY_START;
1683 BEGIN(TripleString);
1686 yyextra->stringContext=YY_START;
1687 yyextra->decoratorCommentStr.str(std::string());
1688 yyextra->copyString=&yyextra->decoratorCommentStr;
1689 BEGIN( SingleQuoteString );
1692 yyextra->stringContext=YY_START;
1693 yyextra->decoratorCommentStr.str(std::string());
1694 yyextra->copyString=&yyextra->decoratorCommentStr;
1695 BEGIN( DoubleQuoteString );
1698 yyextra->decoratorRound++;
1701 yyextra->decoratorRound--;
1702 if (!yyextra->decoratorRound) BEGIN(
Search );
1744 struct yyguts_t *yyg = (
struct yyguts_t*)yyscanner;
1746 const char *p = yyextra->inputString + yyextra->inputPosition;
1747 while ( c < max_size && *p ) { *buf++ = *p++; c++; }
1748 yyextra->inputPosition+=c;
1754 struct yyguts_t *yyg = (
struct yyguts_t*)yyscanner;
1757 yyextra->isStatic =
FALSE;
1759 yyextra->previous = 0;
1760 yyextra->packageCommentAllowed =
TRUE;
1765 struct yyguts_t *yyg = (
struct yyguts_t*)yyscanner;
1767 yyextra->current->protection = yyextra->protection ;
1768 yyextra->current->mtype = yyextra->mtype;
1769 yyextra->current->virt = yyextra->virt;
1770 yyextra->current->isStatic = yyextra->isStatic;
1772 yyextra->current->type.clear();
1773 yyextra->current->name.clear();
1774 yyextra->commentScanner.initGroupInfo(yyextra->current.get());
1775 yyextra->isStatic =
FALSE;
1780 struct yyguts_t *yyg = (
struct yyguts_t*)yyscanner;
1782 if (yyextra->checkDupEntry)
1784 for (
auto &v : yyextra->current_root->children())
1787 if (v->name==yyextra->current->name && v->section==yyextra->current->section)
1789 if (v->doc.isEmpty() && !yyextra->current->doc.isEmpty())
1791 v->doc = yyextra->current->doc;
1792 v->docLine = yyextra->current->docLine;
1793 v->docFile = yyextra->current->docFile;
1795 if (v->brief.isEmpty() && !yyextra->current->brief.isEmpty())
1797 v->brief = yyextra->current->brief;
1798 v->briefLine = yyextra->current->briefLine;
1799 v->briefFile = yyextra->current->briefFile;
1801 if (v->type.isEmpty() && !yyextra->current->type.isEmpty())
1804 v->type = yyextra->current->type;
1813 yyextra->previous = yyextra->current;
1814 yyextra->current_root->moveToSubEntryAndRefresh(yyextra->current);
1821 struct yyguts_t *yyg = (
struct yyguts_t*)yyscanner;
1823 auto doc = yyextra->current->doc;
1824 auto docLine = yyextra->current->docLine;
1825 auto docFile = yyextra->current->docFile;
1826 auto brief = yyextra->current->brief;
1827 auto briefLine = yyextra->current->briefLine;
1828 auto briefFile = yyextra->current->briefFile;
1830 yyextra->previous = yyextra->current;
1831 yyextra->current_root->moveToSubEntryAndRefresh(yyextra->current);
1834 yyextra->current->doc = doc;
1835 yyextra->current->docLine = docLine;
1836 yyextra->current->docFile = docFile;
1837 yyextra->current->brief = brief;
1838 yyextra->current->briefLine = briefLine;
1839 yyextra->current->briefFile = briefFile;
1844 struct yyguts_t *yyg = (
struct yyguts_t*)yyscanner;
1845 if (!yyextra->current->name.isEmpty() && yyextra->current->name.at(0)==
'_')
1847 if (yyextra->current->name.at(1)==
'_')
1860 struct yyguts_t *yyg = (
struct yyguts_t*)yyscanner;
1861 yyextra->current->name = name;
1862 yyextra->current->section=EntryType::makeVariable();
1863 yyextra->current->fileName = yyextra->fileName;
1864 yyextra->current->startLine = yyextra->yyLineNr;
1865 yyextra->current->bodyLine = yyextra->yyLineNr;
1866 yyextra->current->type.clear();
1868 yyextra->checkDupEntry =
true;
1873 struct yyguts_t *yyg = (
struct yyguts_t*)yyscanner;
1875 if (yyextra->current_root->section.isCompound())
1877 yyextra->current->isStatic =
TRUE;
1884 struct yyguts_t *yyg = (
struct yyguts_t*)yyscanner;
1886 if (yyextra->current_root->section.isCompound())
1888 yyextra->current->isStatic =
TRUE;
1895 struct yyguts_t *yyg = (
struct yyguts_t*)yyscanner;
1896 if (yyextra->current->name.startsWith(
"__") && yyextra->current->name.endsWith(
"__"))
1917 else if (c==
'\t') col+=tabSize-(col%tabSize);
1925 struct yyguts_t *yyg = (
struct yyguts_t*)yyscanner;
1926 auto it = yyextra->packageNameCache.
find(path.
str());
1927 if (it!=yyextra->packageNameCache.end())
1942 scope+=path.
mid(i+1);
1943 yyextra->packageNameCache.emplace(path.
str(),scope.
str());
1952 if (fileName.
isEmpty())
return fileName;
1959 struct yyguts_t *yyg = (
struct yyguts_t*)yyscanner;
1960 QCString item=all ? yyextra->packageName : yyextra->packageName+
"."+yytext;
1962 yyextra->current->fileName = yyextra->fileName;
1964 yyextra->current->section=all ? EntryType::makeUsingDir() : EntryType::makeUsingDecl();
1965 yyextra->current_root->moveToSubEntryAndRefresh(yyextra->current);
1972 struct yyguts_t *yyg = (
struct yyguts_t*)yyscanner;
1973 DBG_CTX((stderr,
"yyextra->yyLineNr=%d\n",yyextra->yyLineNr));
1974 for (
const char *p = yytext; *p; ++p)
1976 yyextra->yyLineNr += (*p ==
'\n') ;
1982 struct yyguts_t *yyg = (
struct yyguts_t*)yyscanner;
1983 DBG_CTX((stderr,
"yyextra->yyLineNr=%d\n",yyextra->yyLineNr));
1984 yyextra->yyLineNr++;
1990 struct yyguts_t *yyg = (
struct yyguts_t*)yyscanner;
1993 yyextra->current->briefFile = yyextra->fileName;
1994 yyextra->current->briefLine = yyextra->yyLineNr;
1998 yyextra->current->docFile = yyextra->fileName;
1999 yyextra->current->docLine = yyextra->yyLineNr;
2005 struct yyguts_t *yyg = (
struct yyguts_t*)yyscanner;
2010 yyextra->docBlockInBody=
FALSE;
2012 if (!yyextra->current->doc.isEmpty())
2014 yyextra->current->doc=yyextra->current->doc.stripWhiteSpace()+
"\n\n";
2016 if (yyextra->docBlockInBody && yyextra->previous && !yyextra->previous->doc.isEmpty())
2018 yyextra->previous->doc=yyextra->previous->doc.stripWhiteSpace()+
"\n\n";
2022 bool needsEntry =
false;
2023 int lineNr = brief ? yyextra->current->briefLine : yyextra->current->docLine;
2024 Markdown markdown(yyextra->fileName,lineNr);
2029 while (yyextra->commentScanner.parseCommentBlock(
2030 yyextra->thisParser,
2031 (yyextra->docBlockInBody && yyextra->previous) ? yyextra->previous.get() : yyextra->current.get(),
2035 yyextra->docBlockInBody ?
FALSE : brief,
2036 yyextra->docBlockJavaStyle,
2037 yyextra->docBlockInBody,
2038 yyextra->protection,
2060 struct yyguts_t *yyg = (
struct yyguts_t*)yyscanner;
2062 if (yyextra->bodyEntry)
2064 yyextra->bodyEntry->endBodyLine = yyextra->yyLineNr-correction;
2065 yyextra->bodyEntry = 0;
2073 struct yyguts_t *yyg = (
struct yyguts_t*)yyscanner;
2074 if (yyextra->copyString) (*yyextra->copyString) << s;
2079 struct yyguts_t *yyg = (
struct yyguts_t*)yyscanner;
2080 yyextra->docBlockContext = YY_START;
2081 yyextra->docBlockInBody =
FALSE;
2082 yyextra->docBlockJavaStyle =
TRUE;
2083 yyextra->docBlockSpecial = yytext[strlen(yytext) - 1]==
'!' || !
Config_getBool(PYTHON_DOCSTRING);
2084 yyextra->docBlock.clear();
2085 yyextra->commentIndent = yyextra->curIndent;
2086 yyextra->doubleQuote =
TRUE;
2092 struct yyguts_t *yyg = (
struct yyguts_t*)yyscanner;
2093 yyextra->docBlockContext = YY_START;
2094 yyextra->docBlockInBody =
FALSE;
2095 yyextra->docBlockJavaStyle =
TRUE;
2096 yyextra->docBlockSpecial = yytext[strlen(yytext) - 1]==
'!' || !
Config_getBool(PYTHON_DOCSTRING);
2097 yyextra->docBlock.clear();
2098 yyextra->commentIndent = yyextra->curIndent;
2099 yyextra->doubleQuote =
FALSE;
2105 struct yyguts_t *yyg = (
struct yyguts_t*)yyscanner;
2106 yyextra->docBlockContext = YY_START;
2107 yyextra->docBlockInBody =
FALSE;
2108 yyextra->docBlockJavaStyle =
TRUE;
2109 yyextra->docBrief =
TRUE;
2110 yyextra->docBlock.clear();
2111 yyextra->commentIndent = yyextra->curIndent;
2117 struct yyguts_t *yyg = (
struct yyguts_t*)yyscanner;
2118 yyextra->current->fileName = yyextra->fileName;
2119 yyextra->current->startLine = yyextra->yyLineNr;
2120 yyextra->current->bodyLine = yyextra->yyLineNr;
2121 yyextra->current->section = EntryType::makeFunction();
2124 yyextra->current->isStatic = yyextra->isStatic;
2126 yyextra->current->type.clear();
2127 yyextra->current->name.clear();
2128 yyextra->current->args.clear();
2129 yyextra->current->argList.clear();
2130 yyextra->packageCommentAllowed =
FALSE;
2131 yyextra->isStatic=
FALSE;
2137 struct yyguts_t *yyg = (
struct yyguts_t*)yyscanner;
2138 yyextra->current->section = EntryType::makeClass();
2139 yyextra->current->argList.clear();
2140 yyextra->current->type +=
"class" ;
2141 yyextra->current->fileName = yyextra->fileName;
2142 yyextra->current->startLine = yyextra->yyLineNr;
2143 yyextra->current->bodyLine = yyextra->yyLineNr;
2144 yyextra->packageCommentAllowed =
FALSE;
2151 struct yyguts_t *yyg = (
struct yyguts_t*)yyscanner;
2153 for (
size_t i=0; i<rt->children().size(); ++i)
2155 std::shared_ptr<Entry> ce = rt->children()[i];
2156 if (!ce->program.empty())
2161 yyextra->programStr = ce->program.str();
2162 yyextra->inputString = yyextra->programStr.data();
2163 yyextra->inputPosition = 0;
2164 yyextra->firstPass =
false;
2165 pyscannerYYrestart(
nullptr, yyscanner );
2166 if (ce->section.isCompound())
2168 yyextra->specialBlock =
false;
2169 yyextra->current_root = ce;
2172 else if (ce->parent())
2174 yyextra->current_root = rt;
2177 BEGIN( SearchMemVars );
2179 yyextra->fileName = ce->fileName;
2180 yyextra->yyLineNr = ce->bodyLine ;
2181 yyextra->current = std::make_shared<Entry>();
2184 yyextra->checkDupEntry =
false;
2187 yyextra->commentScanner.enterCompound(yyextra->fileName,yyextra->yyLineNr,name);
2189 pyscannerYYlex(yyscanner) ;
2190 yyextra->lexInit=
TRUE;
2192 yyextra->programStr.clear();
2193 ce->program.str(std::string());
2195 yyextra->commentScanner.leaveCompound(yyextra->fileName,yyextra->yyLineNr,name);
2207 struct yyguts_t *yyg = (
struct yyguts_t*)yyscanner;
2210 if (fileBuf==
nullptr || fileBuf[0]==
'\0')
return;
2212 yyextra->inputString = fileBuf;
2213 yyextra->inputPosition = 0;
2217 yyextra->isStatic =
false;
2219 yyextra->current_root = rt;
2220 yyextra->specialBlock =
false;
2222 yyextra->yyLineNr = 1 ;
2223 yyextra->fileName = fileName;
2224 yyextra->checkDupEntry =
false;
2225 yyextra->firstPass =
true;
2227 msg(
"Parsing file {}...\n",yyextra->fileName);
2232 if (baseName!=
"__init__")
2234 if (!yyextra->moduleScope.isEmpty())
2236 yyextra->moduleScope+=
"::";
2238 yyextra->moduleScope+=baseName;
2242 QCString scope = yyextra->moduleScope;
2247 pos = scope.
find(
"::",startPos);
2249 if (pos==-1) pos=(int)scope.
length();
2250 yyextra->current = std::make_shared<Entry>();
2252 yyextra->current->name = scope.
left(pos);
2253 yyextra->current->section = EntryType::makeNamespace();
2254 yyextra->current->type =
"namespace";
2255 yyextra->current->fileName = yyextra->fileName;
2256 yyextra->current->startLine = yyextra->yyLineNr;
2257 yyextra->current->bodyLine = yyextra->yyLineNr;
2258 yyextra->current_root = yyextra->current;
2259 rt->moveToSubEntryAndRefresh(yyextra->current);
2260 }
while (pos<(
int)scope.
length());
2264 yyextra->commentScanner.enterFile(yyextra->fileName,yyextra->yyLineNr);
2266 yyextra->current->reset();
2268 pyscannerYYrestart(
nullptr,yyscanner);
2270 pyscannerYYlex(yyscanner);
2271 yyextra->lexInit=
TRUE;
2273 yyextra->commentScanner.leaveFile(yyextra->fileName,yyextra->yyLineNr);
2275 yyextra->programStr.clear();
2276 yyextra->current_root->program.str(std::string());
2285 struct yyguts_t *yyg = (
struct yyguts_t*)yyscanner;
2289 warn(yyextra->fileName,yyextra->yyLineNr,
"Empty prototype found!");
2293 yyextra->specialBlock =
FALSE;
2294 yyextra->packageCommentAllowed =
FALSE;
2297 YY_BUFFER_STATE orgState = YY_CURRENT_BUFFER;
2298 yy_switch_to_buffer(yy_create_buffer(
nullptr,
YY_BUF_SIZE, yyscanner), yyscanner);
2299 const char *orgInputString = yyextra->inputString;
2300 int orgInputPosition = yyextra->inputPosition;
2303 yyextra->inputString = text.
data();
2304 yyextra->inputPosition = 0;
2305 pyscannerYYrestart(
nullptr, yyscanner );
2307 BEGIN( FunctionDec );
2309 pyscannerYYlex(yyscanner);
2310 yyextra->lexInit=
TRUE;
2312 yyextra->current->name = yyextra->current->name.stripWhiteSpace();
2313 if (yyextra->current->section.isMemberDoc() && yyextra->current->args.isEmpty())
2315 yyextra->current->section = EntryType::makeVariableDoc();
2320 yy_delete_buffer(YY_CURRENT_BUFFER, yyscanner);
2321 yy_switch_to_buffer(orgState, yyscanner);
2323 yyextra->inputString = orgInputString;
2324 yyextra->inputPosition = orgInputPosition;
2339 pyscannerYYlex_init_extra(&
p->state,&
p->yyscanner);
2347 pyscannerYYlex_destroy(
p->yyscanner);
2352 const char *fileBuf,
2353 const std::shared_ptr<Entry> &root,
2356 struct yyguts_t *yyg = (
struct yyguts_t*)
p->yyscanner;
2357 yyextra->thisParser =
this;
2377#include "pyscanner.l.h"
Clang parser object for a single translation unit, which consists of a source file and the directly o...
static bool isFlagSet(const DebugMask mask)
Minimal replacement for QFileInfo.
std::string dirPath(bool absPath=true) const
std::string baseName() const
Helper class to process markdown formatted text.
QCString process(const QCString &input, int &startNewlines, bool fromParseInput=false)
bool needsPreprocessing(const QCString &extension) const override
Returns TRUE if the language identified by extension needs the C preprocessor to be run before feed t...
void parseInput(const QCString &fileName, const char *fileBuf, const std::shared_ptr< Entry > &root, ClangTUParser *clangParser) override
Parses a single input file with the goal to build an Entry tree.
std::unique_ptr< Private > p
~PythonOutlineParser() override
void parsePrototype(const QCString &text) override
Callback function called by the comment block scanner.
int find(char c, int index=0, bool cs=TRUE) const
size_t length() const
Returns the length of the string, not counting the 0-terminator.
QCString mid(size_t index, size_t len=static_cast< size_t >(-1)) const
const std::string & str() const
int findRev(char c, int index=-1, bool cs=TRUE) const
const char * data() const
Returns a pointer to the contents of the string in the form of a 0-terminated C string.
QCString left(size_t len) const
static int yyread(yyscan_t yyscanner, char *buf, int max_size)
#define Config_getInt(name)
#define Config_getBool(name)
static void startCommentBlock(yyscan_t yyscanner, bool)
static void parseMain(yyscan_t yyscanner, const QCString &fileName, const char *fileBuf, const std::shared_ptr< Entry > &rt, FortranFormat format)
static void parsePrototype(yyscan_t yyscanner, const QCString &text)
static void parseCompounds(yyscan_t yyscanner, std::shared_ptr< Entry > rt)
QCString stripIndentation(const QCString &s, bool skipFirstLine)