:- module pair.
:- interface.
:- type pair(T) == pair.pair(T, T).
:- type pair(T1, T2)
	--->	-(T1, T2).
:- inst (pair(I)) == pair.pair(I, I).
:- inst (pair(I1, I2)) == bound(-(I1, I2)).
:- func fst(pair.pair(X, Y)) = X.
:- pred fst(pair.pair(X, Y), X).
:- mode fst((builtin.in), (builtin.out)) is det.
:- func pair(T1, T2) = pair.pair(T1, T2).
:- func snd(pair.pair(X, Y)) = Y.
:- pred snd(pair.pair(X, Y), Y).
:- mode snd((builtin.in), (builtin.out)) is det.
