[net.lang.ada] Where's my exception?!?

wilson%anchor.DECnet@LLL-ICDC.ARPA ("ANCHOR::WILSON") (08/19/86)

Here's a little program which raises an exceptional point:

	procedure TEST is

	    I : INTEGER := INTEGER'last + 1;

	begin

	    null;

	end TEST;

Should this program raise an exception?  Well, I'd like to think so.  
However, the DEC compiler optimizes my whole program away, since there's 
I/O or other visible action taken, and the program terminates normally.

Summarizing LRM 10.6:

	1.  A compiler is allowed to replace code which would cause an
	    exception to be raised with code to raise that exception

	2.  Code which would never be executed need not be considered "in
	    error" if it is never called.

Neither of these statements seem to apply to this program.

Is the compiler taking unauthorized action, or am I missing something in 
the LRM?

Thanks,

			--- Rick

wilson%anchor.decnet@lll-icdc.arpa
------