imported patch jason/slicc-external-structure-fix

This commit is contained in:
Brad Beckmann 2012-07-10 22:51:54 -07:00
parent 86d6b788f6
commit 884cd6f752
2 changed files with 2 additions and 2 deletions

View file

@ -45,7 +45,7 @@ class AssignStatementAST(StatementAST):
code("$lcode = $rcode;")
if ltype != rtype:
if not (ltype == rtype or (ltype.isInterface and ltype['interface'] == rtype.ident)):
# FIXME - beckmann
# the following if statement is a hack to allow NetDest
# objects to be assigned to Sets this allows for the

View file

@ -93,7 +93,7 @@ class FuncCallExprAST(ExprAST):
for expr,expected_type in zip(self.exprs, func.param_types):
# Check the types of the parameter
actual_type,param_code = expr.inline(True)
if actual_type != expected_type:
if str(actual_type) != str(expected_type):
expr.error("Type mismatch: expected: %s actual: %s" % \
(expected_type, actual_type))
cvec.append(param_code)