From: David Lamparter Date: Fri, 16 Dec 2016 19:43:26 +0000 (+0100) Subject: lib: parser: accept number-only word tokens X-Git-Tag: frr-3.0-branchpoint~112^2~1 X-Git-Url: https://git.puffer.fish/?a=commitdiff_plain;h=bca1a301babea5f2cd17ccd7e6d077fbd120bfda;p=mirror%2Ffrr.git lib: parser: accept number-only word tokens There seems to be no reason why numbers don't work as plain word tokens; this is useful to have "number choices" or constants, e.g. <128|192|256> for bit encryption lengths. Signed-off-by: David Lamparter --- diff --git a/lib/command_lex.l b/lib/command_lex.l index 0cb306b682..d767926263 100644 --- a/lib/command_lex.l +++ b/lib/command_lex.l @@ -26,7 +26,7 @@ #include "command_parse.h" %} -WORD (\-|\+)?[a-z\*][-+_a-zA-Z0-9\*]* +WORD (\-|\+)?[a-z0-9\*][-+_a-zA-Z0-9\*]* IPV4 A\.B\.C\.D IPV4_PREFIX A\.B\.C\.D\/M IPV6 X:X::X:X