[m-dev.] 0.13 release: op/3 syntax
Peter Schachte
schachte at csse.unimelb.edu.au
Sat Mar 4 00:14:40 AEDT 2006
> > [Moving language syntax extensions to the library would simplify
> > the language and its documentation.]
>
> No, then we'd just have to shift the documentation to the library
> modules.
That would be a good thing. Users really need to understand the whole
language, but not the whole library. Otherwise why not just build the
whole library into the language?
> At least with the current scheme you won't find the compiler reporting
> strange new syntax errors in a previously working module just because
> you added an import_module directive.
That wouldn't happen. Worst case is they'd get a warning about a
module redefining an operator. However, what you're describing can
happen in Mercury. If the new module you import defines a func/pred
with the same signature as another you define or import, and you use
it, you would get an error. The one I really love is that you can get
an error in your module when another module you don't even import
changes (details left as an exercise for the reader). Funny thing is,
despite these pitfalls, the sky doesn't fall.
> We've just stripped out a whole load of aditi related operators
Cool. But they wouldn't have had to be added to the language in the
first place if some Aditi library could have defined them itself.
--
Peter Schachte Victory attained by violence is tantamount to a
schachte at cs.mu.OZ.AU defeat, for it is momentary.
www.cs.mu.oz.au/~schachte/ -- Mahatma Gandhi
Phone: +61 3 8344 1338
--------------------------------------------------------------------------
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