[m-dev.] diff: remove support for cuts
Fergus Henderson
fjh at cs.mu.OZ.AU
Tue Mar 28 13:51:06 AEST 2000
On 28-Mar-2000, Zoltan Somogyi <zs at cs.mu.OZ.AU> wrote:
> On 28-Mar-2000, Fergus Henderson <fjh at cs.mu.OZ.AU> wrote:
> > That change breaks backwards compatibility. You should not remove it, you
> > should instead add a `pragma obsolete' declaration for it, and then wait a
> > couple of releases before removing it. This change should be mentioned in the
> > NEWS file.
> >
> > Also the ! predicate might still be useful for people converting Prolog code
> > to Mercury, so I suggest that it be moved to library/prolog.m rather than
> > being removed altogether.
>
> These two suggestions are not fully compatible: if ! is moved to
> library/prolog.m, people will have to add :- import_module prolog to their
> code.
Actually I meant that you should add it to `library/prolog.m',
and leave the copy in builtin.m, just adding `pragma obsolete' to it.
But now that I think about it, that won't work, since any module
importing `prolog.m' will also import `builtin.m' and so you would
have to use an explicit module qualifier to resolve the ambiguity...
It would be nice if we had something like Ada's `renames',
so that the compiler could detect that the two different occurrences
of `!' were both the same, and thus avoid the ambiguity.
However, since we don't, I guess it is probably best to just
deprecate the existing version in builtin.m (i.e. add the
`pragma obsolete'), and not add it to prolog.m.
--
Fergus Henderson <fjh at cs.mu.oz.au> | "I have always known that the pursuit
WWW: <http://www.cs.mu.oz.au/~fjh> | of excellence is a lethal habit"
PGP: finger fjh at 128.250.37.3 | -- the last words of T. S. Garp.
--------------------------------------------------------------------------
mercury-developers mailing list
Post messages to: mercury-developers at cs.mu.oz.au
Administrative Queries: owner-mercury-developers at cs.mu.oz.au
Subscriptions: mercury-developers-request at cs.mu.oz.au
--------------------------------------------------------------------------
More information about the developers
mailing list