Create evaluator for extend statement

This commit is contained in:
Bartłomiej Pluta
2019-07-12 22:31:14 +02:00
parent 41f385de09
commit 033d864b0f
3 changed files with 7 additions and 4 deletions

View File

@@ -17,11 +17,11 @@ class ExtendEvaluator(Evaluator):
@classmethod
def _typeToMethodSignature(cls, node):
if type(node.specifiers) == NoneNode:
return signature(ofType(node.type))
return signature(ofType(node.type.value))
elif node.type == Type.LIST:
elif node.type.value == Type.LIST:
return signature(listSpecifier(node.specifiers[0]))
elif node.type == Type.MAP:
elif node.type.value == Type.MAP:
return signature(mapSpecifier(node.specifiers[0], node.specifiers[1]))
@classmethod