Skip to content

Commit

Permalink
add factory for int wrapper
Browse files Browse the repository at this point in the history
  • Loading branch information
hstoebel committed Feb 19, 2020
1 parent 3733cda commit 70f7dca
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions interpreter/app/token/utils.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
from app.token import IntWrapper, IntToken

def int_wrapper_factory(int_str: str):
int_tokens = [IntToken(char) for char in int_str]
return IntWrapper(int_tokens)

0 comments on commit 70f7dca

Please sign in to comment.