summaryrefslogtreecommitdiffstats
path: root/libmscgen/mscgen_lexer.l
diff options
context:
space:
mode:
authoralbert-github <albert.tests@gmail.com>2019-09-05 12:04:14 (GMT)
committeralbert-github <albert.tests@gmail.com>2019-09-05 12:04:14 (GMT)
commitaca16ea3b4e4beef9bf067d0b532dfa3802f7a3d (patch)
tree9c040ab60c4d6f7c1bd3503abb1b2f6d219d86f2 /libmscgen/mscgen_lexer.l
parent98cc801013b16d827d91567998ead7b24fd78b6d (diff)
downloadDoxygen-aca16ea3b4e4beef9bf067d0b532dfa3802f7a3d.zip
Doxygen-aca16ea3b4e4beef9bf067d0b532dfa3802f7a3d.tar.gz
Doxygen-aca16ea3b4e4beef9bf067d0b532dfa3802f7a3d.tar.bz2
Consistent way to show scanner state
Create a consistent way to display the state mnemonics of the different scanners (analogous to the fortranscanner.l) Use an automatic procedure to generate the routine with the translation of the states to a string.
Diffstat (limited to 'libmscgen/mscgen_lexer.l')
-rw-r--r--libmscgen/mscgen_lexer.l6
1 files changed, 4 insertions, 2 deletions
diff --git a/libmscgen/mscgen_lexer.l b/libmscgen/mscgen_lexer.l
index 29d6aea..8410e07 100644
--- a/libmscgen/mscgen_lexer.l
+++ b/libmscgen/mscgen_lexer.l
@@ -41,7 +41,7 @@ static Boolean lex_utf8 = FALSE;
/* Local function prototypes */
static void newline(const char *text, unsigned int n);
static char *trimQstring(char *s);
-
+static const char *stateToString(int state);
%}
/* Not used, so prevent compiler warning */
@@ -49,7 +49,8 @@ static char *trimQstring(char *s);
%option noinput
%option noyywrap
-%x IN_COMMENT BODY
+%x IN_COMMENT
+%x BODY
%%
<INITIAL>{
@@ -233,4 +234,5 @@ Boolean lex_getutf8(void)
return lex_utf8;
}
+#include "mscgen_lexer.l.h"
/* END OF FILE */