diff options
author | Dimitri van Heesch <dimitri@stack.nl> | 2008-01-16 19:20:21 (GMT) |
---|---|---|
committer | Dimitri van Heesch <dimitri@stack.nl> | 2008-01-16 19:20:21 (GMT) |
commit | fc90c25edfba404f54319eaeeacca39246f95c9e (patch) | |
tree | 78bac4e928b25e139605aceefa82537f378d8af0 /src/fortranscanner.l | |
parent | f57b7d974fec18d1d8f325c102efd8be5930131d (diff) | |
download | Doxygen-fc90c25edfba404f54319eaeeacca39246f95c9e.zip Doxygen-fc90c25edfba404f54319eaeeacca39246f95c9e.tar.gz Doxygen-fc90c25edfba404f54319eaeeacca39246f95c9e.tar.bz2 |
Release-1.5.4
Diffstat (limited to 'src/fortranscanner.l')
-rw-r--r-- | src/fortranscanner.l | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/src/fortranscanner.l b/src/fortranscanner.l index e4ef1f8..eecdd60 100644 --- a/src/fortranscanner.l +++ b/src/fortranscanner.l @@ -184,7 +184,7 @@ B [ \t] BS [ \t]* BS_ [ \t]+ COMMA {BS},{BS} -ARGS {BS}("("[^)]*")"){BS} +ARGS {BS}("("[^)]*")") NOARGS {BS}"\n" NUM_TYPE (complex|integer|logical|real) @@ -196,7 +196,7 @@ INTENT_SPEC intent{BS}"("{BS}(in|out|in{BS}out){BS}")" ATTR_SPEC (ALLOCATABLE|DIMENSION{ARGS}|EXTERNAL|{INTENT_SPEC}|INTRINSIC|OPTIONAL|PARAMETER|POINTER|PRIVATE|PUBLIC|SAVE|TARGET) ACCESS_SPEC (PRIVATE|PUBLIC) /* Assume that attribute statements are almost the same as attributes. */ -ATTR_STMT {ATTR_SPEC}|DIMENSION +ATTR_STMT {ATTR_SPEC}|DIMENSION|{ACCESS_SPEC} %option noyywrap %option stack @@ -311,7 +311,7 @@ ATTR_STMT {ATTR_SPEC}|DIMENSION } /*------ ignore special fortran statements */ -<Start,ModuleBody,SubprogBody>(^|[ \t])interface({BS_}{ID})?/[ \t\n] { // handle interface block +<Start,ModuleBody,SubprogBody>^[ \t]*interface({BS_}{ID}({BS}\({BS}[^ \t()]+{BS}\))?)? { // handle interface block QString name = yytext; int index = name.find("interface", 0, FALSE); index = name.find(QRegExp("[^ \\t]"), index+9); @@ -379,7 +379,7 @@ ATTR_STMT {ATTR_SPEC}|DIMENSION /*------- type definition -------------------------------------------------------------------------------*/ -<Start,ModuleBody>"type"({BS_}|({COMMA}{ACCESS_SPEC})) { /* type definition found : TYPE , access-spec::type-name |*/ +<Start,ModuleBody>^{BS}"type"({BS_}|({COMMA}{ACCESS_SPEC})) { /* type definition found : TYPE , access-spec::type-name |*/ yy_push_state(YY_START); BEGIN(Typedef); current->protection = defaultProtection; @@ -419,7 +419,7 @@ ATTR_STMT {ATTR_SPEC}|DIMENSION <Start,ModuleBody,TypedefBody,SubprogBody>{ {TYPE_SPEC}/{SEPARATE} { /* variable declaration starts */ - //cout << "4=========> got variable type: " << yytext << endl; + //fprintf(stderr,"4=========> got variable type: %s\n",yytext); QString help=yytext; help= help.simplifyWhiteSpace(); argType= help.latin1(); @@ -444,9 +444,9 @@ ATTR_STMT {ATTR_SPEC}|DIMENSION REJECT; } } -{ATTR_STMT}{BS}/{ID} { +{ATTR_STMT}/{BS_}{ID}|{BS}"::" { /* attribute statement starts */ - //cout << "5=========> Attribute statement: "<< yytext << endl; + //fprintf(stderr,"5=========> Attribute statement: %s\n", yytext); QString tmp = yytext; currentModifiers |= tmp.stripWhiteSpace(); argType=""; |