Files
mercury/tests/invalid/bug214.err_exp
Julien Fischer ced413438c Add workarounds for bugs #184 and #214.
Bug #184 is a compiler abort due to the code that generates an error message
for an unsatisfied type class constraint.  That code is either making an
incorrect assumption about the constraint_map type or the there is a bug in the
type checker.  Bug #214 is also concerned with the error message for
unsatisfied type class constraints: in that case we attempt to list which goals
that are causing the unsatisfied constraints, but that list of goals is empty
and we end up with an incomplete looking error message.   (This is related to
bug #184 as once the the workaround for the abort is in place, the same thing
occurs there.)

compiler/post_typecheck.m:
     Do not assume that all unproven constraints will appears as values
     in the constraint map: that isn't true for the program in bug #184.

     If the list of goals that are causing unsatisfied type class constraints
     is empty, then omit the prefix "The unsatisfied constraints are
     due to:" from the error message.

tests/invalid/Mmakefile:
tests/invalid/Mercury.options.m:
tests/invalid/bug184.{m,err_exp}:
tests/invalid/bug214.{m,err_exp}:
     Add the test cases for the above bugs.
2016-06-29 21:54:40 +10:00

4 lines
162 B
Plaintext

bug214.m:043: In predicate `solve_mip_cg'/2:
bug214.m:043: type error: unsatisfied typeclass constraint:
bug214.m:043: `bug214.linear_expr(int, V_15, int)'