Files
mercury/tests/valid_seq/intermod_user_sharing.m
Zoltan Somogyi 6d79ac7802 Fix some anachronisms in tests/valid*.
tests/valid/Mmake.valid.common:
    Delete the RESERVE_TAG_PROGS make variable, since we have not supported
    reserved tags for a long time.

    Delete the NO_SPECIAL_PREDS_PROG make variable, since (despite its
    documentation) we do not actually specify --no-special-preds for
    the test cases listed in it.

tests/valid/Mmakefile:
    Conform to the changes above. Move the only test listed for
    NO_SPECIAL_PREDS_PROG to OTHER_PROGS.

tests/valid_seq/Mmakefile:
    Conform to the changes above.

tests/valid/unify_typeinfo_bug.m:
    Fix programming style.

tests/valid_seq/intermod_user_sharing.m:
    Delete a redundant import.
2020-07-14 00:51:50 +10:00

31 lines
876 B
Mathematica

%---------------------------------------------------------------------------%
% vim: ts=4 sw=4 et ft=mercury
%---------------------------------------------------------------------------%
%
% Test that we can write out and read back in `no_sharing', `unknown_sharing'
% and `sharing' annotations on foreign_procs.
%
:- module intermod_user_sharing.
:- interface.
:- import_module io.
:- pred main(io::di, io::uo) is det.
%---------------------------------------------------------------------------%
%---------------------------------------------------------------------------%
:- implementation.
:- import_module intermod_user_sharing_2.
%---------------------------------------------------------------------------%
main(!IO) :-
p_no_sharing(!IO),
p_unknown_sharing("bar", Bar),
io.write(Bar, !IO),
p_sharing(1, "foo", Array),
io.write(Array, !IO).