[PATCH 1/5] Simplify a regular expression in ada-lex.l

Tom Tromey via Gdb-patches
2022-02-28T18:33:55Z

ada-lex.l uses "%option case-insensitive", so there is no need for
regular expressions to match upper case.
---
gdb/ada-lex.l | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/gdb/ada-lex.l b/gdb/ada-lex.l
index f61efba81a9..a1e19423691 100644
--- a/gdb/ada-lex.l
+++ b/gdb/ada-lex.l
@@ -220,7 +220,7 @@ false { return FALSEKEYWORD; }

/* ATTRIBUTES */

-{TICK}[a-zA-Z][a-zA-Z_]+ { BEGIN INITIAL; return processAttribute (yytext+1); }
+{TICK}[a-z][a-z_]+ { BEGIN INITIAL; return processAttribute (yytext+1); }

/* PUNCTUATION */

--
2.31.1