diff options
author | Dimitri van Heesch <dimitri@stack.nl> | 2014-03-15 15:14:58 (GMT) |
---|---|---|
committer | Dimitri van Heesch <dimitri@stack.nl> | 2014-03-15 15:14:58 (GMT) |
commit | c1e25238950492e7f8a5c996e3d3ad41b9b023b0 (patch) | |
tree | 62d8b6469643fd0d4fc30950e85b3990bf51eda1 /src/fortranscanner.l | |
parent | 31a72d0ad15a4185dc123b522039ef3fa8a68b43 (diff) | |
parent | 2dec1060623165057628ee678eb3580351922408 (diff) | |
download | Doxygen-c1e25238950492e7f8a5c996e3d3ad41b9b023b0.zip Doxygen-c1e25238950492e7f8a5c996e3d3ad41b9b023b0.tar.gz Doxygen-c1e25238950492e7f8a5c996e3d3ad41b9b023b0.tar.bz2 |
Merge branch 'feature/bug_625601' of https://github.com/albert-github/doxygen into albert-github-feature/bug_625601
Diffstat (limited to 'src/fortranscanner.l')
-rw-r--r-- | src/fortranscanner.l | 15 |
1 files changed, 9 insertions, 6 deletions
diff --git a/src/fortranscanner.l b/src/fortranscanner.l index aa59bf0..e083b2d 100644 --- a/src/fortranscanner.l +++ b/src/fortranscanner.l @@ -187,7 +187,7 @@ static InterfaceType ifType = IF_NONE; static bool functionLine = FALSE; static char stringStartSymbol; // single or double quote -static bool parsingPrototype = FALSE; // see parsePrototype() +static bool parsingPrototype = FALSE; // see parsePrototype() //! Accumulated modifiers of current statement, eg variable declaration. static SymbolModifiers currentModifiers; @@ -1313,11 +1313,14 @@ void truncatePrepass(int index) // simplified way to know if this is fixed form // duplicate in fortrancode.l -static bool recognizeFixedForm(const char* contents) +static bool recognizeFixedForm(const char* contents, FortranKind codeType) { int column=0; bool skipLine=FALSE; + if (codeType == FORTRAN_FIXED) return TRUE; + if (codeType == FORTRAN_FREE) return FALSE; + for(int i=0;;i++) { column++; @@ -2243,7 +2246,7 @@ level--; #endif -static void parseMain(const char *fileName,const char *fileBuf,Entry *rt) +static void parseMain(const char *fileName,const char *fileBuf,Entry *rt, FortranKind codeType) { char *tmpBuf = NULL; initParser(); @@ -2263,7 +2266,7 @@ static void parseMain(const char *fileName,const char *fileBuf,Entry *rt) inputFile.setName(fileName); if (inputFile.open(IO_ReadOnly)) { - isFixedForm = recognizeFixedForm(fileBuf); + isFixedForm = recognizeFixedForm(fileBuf,codeType); if (isFixedForm) { @@ -2342,7 +2345,7 @@ void FortranLanguageScanner::parseInput(const char *fileName, printlex(yy_flex_debug, TRUE, __FILE__, fileName); - ::parseMain(fileName,fileBuf,root); + ::parseMain(fileName,fileBuf,root,this->codeType); printlex(yy_flex_debug, FALSE, __FILE__, fileName); } @@ -2365,7 +2368,7 @@ void FortranLanguageScanner::parseCode(CodeOutputInterface & codeOutIntf, { ::parseFortranCode(codeOutIntf,scopeName,input,isExampleBlock,exampleName, fileDef,startLine,endLine,inlineFragment,memberDef, - showLineNumbers,searchCtx,collectXRefs); + showLineNumbers,searchCtx,collectXRefs,this->codeType); } bool FortranLanguageScanner::needsPreprocessing(const QCString &extension) |