Files
mercury/tests/invalid/state_vars_test3.err_exp
Zoltan Somogyi eecf8b6b15 Complain about no clauses for pred/func ...
compiler/typecheck_error_undef.m:
    ... only if that predicate or function was declared by the user.
    If the compiler itself added the pred/func declaration implicitly
    because it saw a clause for that pred/func, but then decided not to
    add that clause to the HLDS after all because it had syntax errors,
    then don't complain about the absence of a clause for a pred/func
    that the user did not declare.

tests/invalid/state_vars_test3.err_exp:
    Expect no complaint about a missing clause in the above situation.
2023-02-08 14:55:40 +11:00

8 lines
413 B
Plaintext

state_vars_test3.m:011: Error: no clauses for function `f'/1.
state_vars_test3.m:017: Error: clause for function `f'/2
state_vars_test3.m:017: without corresponding `:- func' declaration.
state_vars_test3.m:017: However, a function of that name does exist with
state_vars_test3.m:017: arity 1.
state_vars_test3.m:017: Error: !Y cannot be a function result.
state_vars_test3.m:017: You probably meant !:Y.