Commit ae1ba36d by 雾雨魔理沙 Committed by Thierry Moreau

fix (#3769)

parent 83bef9ff
......@@ -249,7 +249,7 @@ class ExprMutator(ExprFunctor):
return con
def visit_match(self, m):
return Match(self.visit(m.data), [Clause(c.lhs, self.visit(c.rhs)) for c in m.pattern])
return Match(self.visit(m.data), [Clause(c.lhs, self.visit(c.rhs)) for c in m.clauses])
def visit_ref_create(self, r):
return RefCreate(self.visit(r.value))
......
......@@ -121,6 +121,10 @@ def test_memo():
check_visit(expr)
def test_match():
p = relay.prelude.Prelude()
check_visit(p.mod[p.map])
if __name__ == "__main__":
test_constant()
test_tuple()
......@@ -134,3 +138,4 @@ if __name__ == "__main__":
test_ref_read()
test_ref_write()
test_memo()
test_match()
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment