From daed07efa3c2795d39ba70ea2a4782f23d398568 Mon Sep 17 00:00:00 2001 From: Bertrand Benjamin Date: Wed, 29 Sep 2021 16:13:02 +0200 Subject: [PATCH] Feat: simplify "no * allowed token" --- mapytex/calculus/core/str2.py | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/mapytex/calculus/core/str2.py b/mapytex/calculus/core/str2.py index aa6d4d2..e0f6d23 100644 --- a/mapytex/calculus/core/str2.py +++ b/mapytex/calculus/core/str2.py @@ -395,11 +395,7 @@ def missing_times(target): elif not is_operator(tok) and tok != ")": target_.send("*") - if ( - isinstance(tok, int) - or (isinstance(tok, str) and not is_operator(tok) and not tok == "(") - or (isinstance(tok, RdLeaf)) - ): + if not ( is_operator(tok) or tok =="(" ): previous = tok target_.send(tok)