Skip to content
Snippets Groups Projects
Commit 99cbffd7 authored by pycsham's avatar pycsham
Browse files

second attempt to fix issues brought about by abstract check fix

parent 98052b4c
No related branches found
No related tags found
No related merge requests found
......@@ -162,8 +162,8 @@ class ClassNode(ClassInterNode):
for con in contains:
if 'abstract' in con.mods and (not('abstract' in self.mods)):
raise Exception("ERROR: Non-abstract Class '{}' contains an abstract method".format(self.name))
if (not con.body) and (not ('native' in con.mods)) and (not ('abstract' in self.mods)):
raise Exception("ERROR: Non-abstract Class '{}' contains an abstract method".format(self.name))
if (not con.body) and (not ('native' in con.mods)) and (not ('abstract' in self.mods)) and (not (con in self.constructors)):
raise Exception("ERROR: Non-abstract Class '{}' contains an abstract method {}".format(self.name, con.name))
# hierarchy: string[]
def getContains(self, hierarchy):
......@@ -178,6 +178,8 @@ class ClassNode(ClassInterNode):
for con in superContains:
conOverwritten = False
for method in contains:
print(method)
print(con)
if (method == con):
# cannot have same signiture but different return types
if (method.methodType != con.methodType):
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment