Files
mercury/tests/invalid/mode_without_pred.m
Zoltan Somogyi 66dee1e133 Fix a phasing problem in building the HLDS.
compiler/make_hlds_passes.m:
    Both fix and document the phasing problem.

compiler/add_pred.m:
    Document the field here as well.

compiler/check_field_access_functions.m:
    Delete the reference to this phasing problem.

tests/invalid/mode_without_pred.{m,err_exp}:
    A test case for this issue, which compilers from before this fix
    would have failed.

tests/invalid/Mmakefile:
    Enable the new test.
2025-07-14 17:01:34 +02:00

21 lines
466 B
Mathematica

%---------------------------------------------------------------------------%
% vim: ts=4 sw=4 et ft=mercury
%---------------------------------------------------------------------------%
:- module mode_without_pred.
:- interface.
:- type t
---> f(
f1 :: int,
f2 :: int
).
:- implementation.
% :- func f1(t) = int.
:- mode f1(in) = out is det.
:- func 'f1 :='(t, int) = t.
:- mode 'f1 :='(in, in) = out is det.