[m-dev.] delaying compile errors until runtime

Robert Ernst Johann JESCHOFNIK rejj at cat.cs.mu.OZ.AU
Wed Dec 22 19:14:09 AEDT 1999


On Wed, 22 Dec 1999, Fergus Henderson wrote:

> It might be nice to add an option to the Mercury compiler
> that would cause it to go ahead and generate executable
> code anyway, even if compile errors were found.  The generated
> code would then raise exceptions at runtime, if/when it was
> executed.
> 
> Comments?

FWIW, it sounds like a good idea to me.
Another use I can see in this is when you are worknig on a certain portion
of your program that you haven't actually included any calls to yet - at
compile time the compiler will still have a cry if there are errors in
this code, even though it isn't being used. An option like this would
allow you to get around this and generate the executable, anyway. (And I
imagin that since the code with errors is never called, the exception will
never be raised. That code probably would [should] get optimised away,
anyway)


rob

--------------------------------------------------------------------------
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