Skip to content

Commit

Permalink
Fixed Issue #41.
Browse files Browse the repository at this point in the history
  • Loading branch information
dloscutoff committed Nov 16, 2021
1 parent ac583cd commit c80ad03
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions execution.py
Original file line number Diff line number Diff line change
Expand Up @@ -216,8 +216,8 @@ def evaluate(self, expression):
result = opFunction(*args)
except TypeError as e:
# Probably the wrong number of args
errMsg = f"evaluate({expression}) raised TypeError"
self.err.die("Implementation error:", errMsg, e)
self.err.die(f"Implementation error: evaluate({expression}) "
"raised TypeError:", e)
#!print(fnName, "returned", result)
return result

Expand Down Expand Up @@ -819,7 +819,9 @@ def AT(self, lhs, rhs=None):
result.append(groups[0])
return List(result)
elif isinstance(rhs, Pattern) and isinstance(lhs, (List, Range)):
return List(self.AT(sub, rhs) for sub in lhs)
return List(self.AT(item, rhs) for item in lhs)
elif isinstance(rhs, List) and isinstance(lhs, PipIterable):
return List(self.AT(lhs, item) for item in rhs)
elif isinstance(lhs, PipIterable):
try:
if len(lhs) == 0:
Expand Down

0 comments on commit c80ad03

Please sign in to comment.