Files
mercury/tests/valid/any_inst_merge.m
Zoltan Somogyi c03b11ca48 Update the style of more test cases.
And updated expected outputs for changed line numbers.
2021-07-27 19:29:21 +10:00

24 lines
569 B
Mathematica

%---------------------------------------------------------------------------%
% vim: ts=4 sw=4 et ft=mercury
%---------------------------------------------------------------------------%
%
% A regression test -- Mercury 0.9.1 and earlier failed this test case,
% due to a bug in inst_merge.
:- module any_inst_merge.
:- interface.
:- type hpair(A, B)
---> (A - B).
:- inst hpair(A, B) == bound(A - B).
:- pred pass(hpair(A, B)::in, hpair(A, B)::in(hpair(ground, any)),
hpair(A, B)::out(any)) is multi.
:- implementation.
pass(X, _, X).
pass(_, X, X).