Files
mercury/tests/invalid/predmode.m
Zoltan Somogyi 60dc60d6d6 Generate more detailed messages for arg declaration errors.
compiler/parse_item.m:
    When parsing the arguments of function and predicate declarations,
    which may consist either of just a type or a type::mode pair,
    report an error for each unparseable type and for each unparseable mode,
    instead of reporting a single "syntax error" for the whole declaration.

compiler/parse_type_name.m:
    Put quotes around ill-formed types in error messages.

    Put the arguments of a predicate in a better order.

compiler/parse_mutable.m:
compiler/parse_type_defn.m:
compiler/superhomogeneous.m:
compiler/parse_class.m:
    Conform to the changes in parse_type_name.m.

tests/invalid/predmode.{m,err_exp}:
    Add a test of the new capability to this test case.

    Remove the cause of an unnecessary error message.

tests/invalid/combined_ho_type_inst.m:
    Fix indentation.

tests/invalid/combined_ho_type_inst.err_exp:
tests/invalid/combined_ho_type_inst_2.err_exp:
tests/invalid/impl_def_literal_syntax.err_exp:
tests/invalid/kind.err_exp:
tests/invalid/vars_in_wrong_places.err_exp:
    Expect the updated form of error messages.
2016-04-14 23:43:37 +10:00

18 lines
346 B
Mathematica

%---------------------------------------------------------------------------%
% vim: ts=4 sw=4 et ft=mercury
%---------------------------------------------------------------------------%
:- module predmode.
:- interface.
:- pred p(int::in, int).
:- pred q(int::out) is det.
:- implementation.
q(1).
:- pred r(1::2, "bad"::"worse") is det.