summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorMasahiro Yamada <masahiroy@kernel.org>2025-02-06 02:45:28 +0900
committerMasahiro Yamada <masahiroy@kernel.org>2025-03-15 21:16:21 +0900
commit6c3fb0bb4d4f1173f32cc26d077b151d72226a2f (patch)
treea972dcf12774224af5e52e027c76e853baa0618f /scripts
parent90efe2b9119ff8a83a67eb5323e52311a1a49de9 (diff)
genksyms: factor out APP for the ST_NORMAL state
For the ST_NORMAL state, APP is called regardless of the token type. Factor it out. Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
Diffstat (limited to 'scripts')
-rw-r--r--scripts/genksyms/lex.l6
1 files changed, 1 insertions, 5 deletions
diff --git a/scripts/genksyms/lex.l b/scripts/genksyms/lex.l
index 22aeb57649d9..f81033af1528 100644
--- a/scripts/genksyms/lex.l
+++ b/scripts/genksyms/lex.l
@@ -176,10 +176,10 @@ repeat:
switch (lexstate)
{
case ST_NORMAL:
+ APP;
switch (token)
{
case IDENT:
- APP;
{
int r = is_reserved_word(yytext, yyleng);
if (r >= 0)
@@ -224,13 +224,11 @@ repeat:
break;
case '[':
- APP;
lexstate = ST_BRACKET;
count = 1;
goto repeat;
case '{':
- APP;
if (dont_want_brace_phrase)
break;
lexstate = ST_BRACE;
@@ -238,12 +236,10 @@ repeat:
goto repeat;
case '=': case ':':
- APP;
lexstate = ST_EXPRESSION;
break;
default:
- APP;
break;
}
break;