Files
mercury/tests/invalid/require_scopes.err_exp
Zoltan Somogyi c5fc9a929d Print the contexts of later disjuncts ...
compiler/det_report.m:
    ... when a "declared det, inferred multi" kind of determinism error
    is caused by the (probably unexpected, possibly hard-to-see) presence
    of a disjunction.

    Change the wording to refer to "disjuncts" instead of "clauses";
    while in Mercury, all clauses in multi-clause definitions are implicitly
    also disjuncts, not all disjuncts are whole clauses.

tests/invalid/bug496.err_exp:
tests/invalid/det_errors.err_exp:
tests/invalid/not_a_switch.err_exp:
tests/invalid/require_scopes.err_exp:
tests/invalid/switch_arm_multi_not_det.err_exp:
    Expect the updated form of the error message.
2022-12-04 23:33:37 +11:00

20 lines
1.2 KiB
Plaintext

require_scopes.m:036: Error: the required determinism of the goal in this scope
require_scopes.m:036: is `det', but its actual determinism is `semidet'.
require_scopes.m:037: Call to `int.>'(in, in) can fail.
require_scopes.m:040: Error: the required determinism of the goal in this scope
require_scopes.m:040: is `nondet', but its actual determinism is `semidet'.
require_scopes.m:064: Error: the switch on `A' is required to be complete, but
require_scopes.m:064: it does not cover
require_scopes.m:064: `f1'/0.
require_scopes.m:097: Error: the arms of the switch on A are required have a
require_scopes.m:097: determinism that is acceptable in a `det' context, but
require_scopes.m:097: the actual determinism of the arm for
require_scopes.m:097: require_scopes.f3/1 is `semidet'.
require_scopes.m:098: Call to `int.>'(in, in) can fail.
require_scopes.m:109: Error: the arms of the switch on B are required have a
require_scopes.m:109: determinism that is acceptable in a `semidet' context,
require_scopes.m:109: but the actual determinism of the arm for 10 is
require_scopes.m:109: `multi'.
require_scopes.m:110: Disjunction has more than one disjunct with solutions.
require_scopes.m:111: This later disjunct may have a solution.