diff --git a/midas/checker/midas.py b/midas/checker/midas.py index 61a1700..810049e 100644 --- a/midas/checker/midas.py +++ b/midas/checker/midas.py @@ -408,7 +408,7 @@ class MidasTyper(m.Stmt.Visitor[None], m.Expr.Visitor[Type], m.Type.Visitor[Type self._predicate_params = {} if not self.types.is_subtype(constraint_type, self._bool): self.reporter.error( - type.location, + type.constraint.location, f"Constraint must evaluate to a boolean, got {constraint_type}", )