Enable support for types' properties

This commit is contained in:
Bartłomiej Pluta
2019-07-08 22:06:38 +02:00
parent 74eec7f997
commit b06a8533c0
22 changed files with 77 additions and 126 deletions

View File

@@ -1,13 +1,12 @@
from smnp.runtime.evaluator import Evaluator
from smnp.type.model import Type
from smnp.type.value import Value
class StringEvaluator(Evaluator):
@classmethod
def evaluator(cls, node, environment):
return Value(Type.STRING, node.value)
return Type.string(node.value)
# TODO: make use of complex interpreter for code inside '{' and '}'
# def interpolate(string, environment):