summaryrefslogtreecommitdiffstats
path: root/src/pre.l
diff options
context:
space:
mode:
Diffstat (limited to 'src/pre.l')
-rw-r--r--src/pre.l4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/pre.l b/src/pre.l
index 648c2c5..43de171 100644
--- a/src/pre.l
+++ b/src/pre.l
@@ -376,6 +376,7 @@ struct preYY_state
bool skip;
QStack<CondCtx> condStack;
bool insideCS; // C# has simpler preprocessor
+ bool insideFtn;
bool isSource;
int fenceSize = 0;
@@ -495,7 +496,7 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'"))
name=name.left(name.find('(')).stripWhiteSpace();
Define *def=0;
- if (skipFuncMacros &&
+ if (skipFuncMacros && !yyextra->insideFtn &&
name!="Q_PROPERTY" &&
!(
(yyextra->includeStack.isEmpty() || yyextra->curlyCount>0) &&
@@ -1711,6 +1712,7 @@ static void setFileName(yyscan_t yyscanner,const char *name)
// name,state->yyFileName.data(),state->yyFileDef);
if (state->yyFileDef && state->yyFileDef->isReference()) state->yyFileDef=0;
state->insideCS = getLanguageFromFileName(state->yyFileName)==SrcLangExt_CSharp;
+ state->insideFtn = getLanguageFromFileName(state->yyFileName)==SrcLangExt_Fortran;
state->isSource = guessSection(state->yyFileName);
}