summaryrefslogtreecommitdiffstats
path: root/src/pre.l
diff options
context:
space:
mode:
Diffstat (limited to 'src/pre.l')
-rw-r--r--src/pre.l12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/pre.l b/src/pre.l
index c578763..e226148 100644
--- a/src/pre.l
+++ b/src/pre.l
@@ -1975,7 +1975,7 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'"))
<SkipCComment,SkipVerbatim>. {
outputChar(*yytext);
}
-<CopyCComment>[^*]+ {
+<CopyCComment>[^*a-z_A-Z]+ {
g_defLitText+=yytext;
g_defText+=escapeAt(yytext);
}
@@ -1989,10 +1989,6 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'"))
g_defLitText+=yytext;
g_defText+=yytext;
}
-<CopyCComment>. {
- g_defLitText+=yytext;
- g_defText+=yytext;
- }
<RemoveCComment>"*/" { BEGIN(g_lastCContext); }
<RemoveCComment>"//"
<RemoveCComment>"/*"
@@ -2026,7 +2022,7 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'"))
g_quoteArg=TRUE;
g_defLitText+=yytext;
}
-<DefineText>{ID} {
+<DefineText,CopyCComment>{ID} {
g_defLitText+=yytext;
if (g_quoteArg)
{
@@ -2059,6 +2055,10 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'"))
}
g_quoteArg=FALSE;
}
+<CopyCComment>. {
+ g_defLitText+=yytext;
+ g_defText+=yytext;
+ }
<DefineText>\\[\r]?\n {
g_defLitText+=yytext;
outputChar('\n');