Files
mercury/tests/invalid/html.err_exp
Zoltan Somogyi 75dc210ab3 Color subjects in mode errors.
compiler/mode_errors.m:
    Use color to emphasize the subject variables and terms of mode errors.

    Use color to emphasize disagreements as possible causes
    in a few more places.

    Require reporters of the "no matching mode" error to specify
    what the match was against. This is to allow us to generate
    better diagnostics. Note the things that should still be improved.

    Use the names of numbers (as in two, three etc) instead of their numeral
    versions.

    Improve the wording and/or the punctuation of some error messages.

compiler/inst_mode_type_prop.m:
    Use the names of numbers (as in two, three etc) instead of their numeral
    versions.

compiler/error_spec.m:
compiler/write_error_spec.m:
    Move two formerly private utility functions of write_error_spec.m
    to error_spec.m, and export them. One of them is now used in
    the modules above.

compiler/modecheck_call.m:
compiler/modecheck_goal.m:
compiler/modecheck_unify.m:
compiler/modecheck_util.m:
compiler/unique_modes.m:
    Pass around info about "what the match was against" for the change
    in mode_errors.m descrived above.

compiler/hlds_out_util.m:
    Improve variable name.

compiler/hlds_module.m:
    Add an XXX.

tests/invalid/any_mode.err_exp:
tests/invalid/any_passed_as_ground.err_exp:
tests/invalid/any_should_not_match_bound.err_exp:
tests/invalid/any_to_ground_in_ite_cond.err_exp:
tests/invalid/any_to_ground_in_ite_cond_nomax.err_exp:
tests/invalid/anys_in_negated_contexts.err_exp:
tests/invalid/bad_sv_unify_msg.err_exp:
tests/invalid/bind_in_negated.err_exp:
tests/invalid/bind_var_errors.err_exp:
tests/invalid/bug117.err_exp:
tests/invalid/bug191.err_exp:
tests/invalid/bug278.err_exp:
tests/invalid/bug415.err_exp:
tests/invalid/bug487.err_exp:
tests/invalid/char_inst.err_exp:
tests/invalid/coerce_clobbered.err_exp:
tests/invalid/coerce_disambig.err_exp:
tests/invalid/coerce_implied_mode.err_exp:
tests/invalid/coerce_instvar.err_exp:
tests/invalid/coerce_int.err_exp:
tests/invalid/coerce_mode_error.err_exp:
tests/invalid/coerce_mode_error2.err_exp:
tests/invalid/coerce_recursive_inst.err_exp:
tests/invalid/coerce_recursive_type.err_exp:
tests/invalid/coerce_uniq.err_exp:
tests/invalid/constrained_poly_insts2.err_exp:
tests/invalid/currying_multimode_func.err_exp:
tests/invalid/dcg_context.err_exp:
tests/invalid/default_ho_inst.err_exp:
tests/invalid/default_ho_inst_2.err_exp:
tests/invalid/freefree.err_exp:
tests/invalid/functor_ho_inst_bad.err_exp:
tests/invalid/functor_ho_inst_bad_2.err_exp:
tests/invalid/functor_ho_inst_bad_3.err_exp:
tests/invalid/ho_any_inst.err_exp:
tests/invalid/ho_default_func_1.err_exp:
tests/invalid/ho_default_func_2.err_exp:
tests/invalid/ho_default_func_3.err_exp:
tests/invalid/ho_default_func_4.err_exp:
tests/invalid/ho_type_mode_bug.err_exp:
tests/invalid/ho_unique_error.err_exp:
tests/invalid/html.err_exp:
tests/invalid/inst_matches_final_bug.err_exp:
tests/invalid/invalid_integral_call_inst.err_exp:
tests/invalid/io_in_ite_cond.err_exp:
tests/invalid/merge_ground_any.err_exp:
tests/invalid/merge_inst_error.err_exp:
tests/invalid/mode_error_arg_number.err_exp:
tests/invalid/mode_inf.err_exp:
tests/invalid/modes_erroneous.err_exp:
tests/invalid/mostly_uniq1.err_exp:
tests/invalid/mostly_uniq2.err_exp:
tests/invalid/multimode_dcg.err_exp:
tests/invalid/no_ho_inst.err_exp:
tests/invalid/partial_implied_mode.err_exp:
tests/invalid/polymorphic_unification.err_exp:
tests/invalid/state_vars_test1.err_exp:
tests/invalid/state_vars_test5.err_exp:
tests/invalid/try_detism.err_exp:
tests/invalid/unify_mode_error.err_exp:
tests/invalid/uniq_modes.err_exp:
tests/invalid/uniq_neg.err_exp:
tests/invalid_nodepend/constrained_poly_insts.err_exp:
tests/invalid_nodepend/occurs.err_exp:
tests/invalid_purity/impure_func_t5_fixed.err_exp:
tests/invalid_purity/purity.err_exp:
tests/warnings/simple_code.err_exp:
tests/warnings/unify_f_g.err_exp:
    Expect the updated versions of diagnostics.
2024-05-07 10:11:11 +10:00

4.3 KiB

html.m:053: In clause for `init_body_elem =
html.m:053: out(html.non_empty_list(html.top_body_elem))':
html.m:053: mode error: the function result had the wrong instantiatedness.
html.m:053: Final instantiatedness of `HeadVar__1' was `unique',
html.m:053: expected final instantiatedness was
html.m:053: named inst non_empty_list(top_body_elem)
html.m:053: which expands to
html.m:053: bound(
html.m:053: '[|]'(
html.m:053: named inst top_body_elem
html.m:053: which expands to
html.m:053: bound(
html.m:053: text(ground)
html.m:053: ;
html.m:053: ul(
html.m:053: named inst non_empty_list(
html.m:053: li(
html.m:053: named inst top_body_elem
html.m:053: )
html.m:053: )
html.m:053: which expands to
html.m:053: bound(
html.m:053: '[|]'(
html.m:053: named inst li(
html.m:053: named inst top_body_elem
html.m:053: )
html.m:053: which expands to
html.m:053: bound(
html.m:053: li(
html.m:053: named inst
html.m:053: non_empty_list(top_body_elem)
html.m:053: )
html.m:053: ),
html.m:053: named inst list.list_skel(
html.m:053: named inst li(
html.m:053: named inst top_body_elem
html.m:053: )
html.m:053: )
html.m:053: which expands to
html.m:053: bound(
html.m:053: []
html.m:053: ;
html.m:053: '[|]'(
html.m:053: named inst li(
html.m:053: named inst top_body_elem
html.m:053: ),
html.m:053: named inst list.list_skel(
html.m:053: named inst li(
html.m:053: named inst top_body_elem
html.m:053: )
html.m:053: )
html.m:053: )
html.m:053: )
html.m:053: )
html.m:053: )
html.m:053: )
html.m:053: ),
html.m:053: named inst list.list_skel(
html.m:053: named inst top_body_elem
html.m:053: )
html.m:053: which expands to
html.m:053: bound(
html.m:053: []
html.m:053: ;
html.m:053: '[|]'(
html.m:053: named inst top_body_elem,
html.m:053: named inst list.list_skel(
html.m:053: named inst top_body_elem
html.m:053: )
html.m:053: )
html.m:053: )
html.m:053: )
html.m:053: ).