Skip to content

Commit

Permalink
Keep utf8 characters together in comments
Browse files Browse the repository at this point in the history
Analogous to the fortrancode (#10728) also do this in the fortranscanner.
  • Loading branch information
albert-github committed Mar 12, 2024
1 parent c55f070 commit 53614a3
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/fortranscanner.l
Original file line number Diff line number Diff line change
Expand Up @@ -445,6 +445,7 @@ FILEMASK {VFILEMASK}|{HFILEMASK}
}
pop_state(yyscanner);
}
<String>[\x80-\xFF]* |
<String>. { if (yy_top_state(yyscanner) == Initialization ||
yy_top_state(yyscanner) == ArrayInitializer)
{
Expand Down Expand Up @@ -485,6 +486,7 @@ FILEMASK {VFILEMASK}|{HFILEMASK}
<StrIgnore>.?/\n { pop_state(yyscanner); // comment ends with endline character
DBG_CTX((stderr,"end comment %d %s\n",yyextra->lineNr,qPrint(yyextra->debugStr)));
} // comment line ends
<StrIgnore>[\x80-\xFF]* |
<StrIgnore>. { yyextra->debugStr+=yytext; }


Expand Down

0 comments on commit 53614a3

Please sign in to comment.