From 1f6c6614a49a08eb5bf55a683b6d18dfcb0cdeab Mon Sep 17 00:00:00 2001 From: PlexSheep Date: Sun, 17 Dec 2023 18:52:30 +0100 Subject: [PATCH] arith worms --- src/arithmetic.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/arithmetic.py b/src/arithmetic.py index 037d67a..389524b 100644 --- a/src/arithmetic.py +++ b/src/arithmetic.py @@ -21,7 +21,7 @@ def t_NUMBER(t): def t_EXP(t): r'\*\*' - pass + return t lexer = ply.lex.lex() @@ -76,5 +76,3 @@ parser = ply.yacc.yacc() while True: s = input('calc> ') ply.yacc.parse(s) - if s == '': - break