From: Dmitry Selyutin Date: Sun, 22 Aug 2021 18:27:09 +0000 (+0000) Subject: lexer: t_NUMBER should not grab minus sign X-Git-Tag: xlen-bcd~108 X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=488e1535e0c3e81f2e3e83612fe73284e0578d5a;p=openpower-isa.git lexer: t_NUMBER should not grab minus sign --- diff --git a/src/openpower/decoder/pseudo/lexer.py b/src/openpower/decoder/pseudo/lexer.py index aad11a04..b420798b 100644 --- a/src/openpower/decoder/pseudo/lexer.py +++ b/src/openpower/decoder/pseudo/lexer.py @@ -346,7 +346,7 @@ class PowerLexer: #t_NUMBER = r'\d+' # taken from decmial.py but without the leading sign def t_NUMBER(self, t): - r"""[-]?(\d+(\.\d*)?|\.\d+)([eE][-+]? \d+)?""" + r"""(\d+(\.\d*)?|\.\d+)([eE][-+]? \d+)?""" t.value = int(t.value) return t