Your June 7 change to expand_expr

Richard Kenner kenner@vlsi1.ultra.nyu.edu
Thu Jul 2 15:48:00 GMT 1998


    Yes.  But, no conforming program can ever have a NULL reference. 

BTW, the Ada RM distinguishes between "illegal" and "erroneous".  The
former is a static violation of the language rules which compilers are
required to diagnose at compile time and "erroneous" refers to a
program which violates a run-time restriction and for which the
compiler may generate code to do anything at all.  I take it that
"conforming" means that it's neither illegal or erroneous in the Ada
sense.

    My point was that GCC could conceivably optimize certain operations by
    knowing that things of REFERENCE_TYPE are non-NULL; doing so would
    break no legal programs.

Can't it actually do more?  Can't it assume that the address is a valid
address in memory?  This can be quite important in things like Merced.



More information about the Gcc-bugs mailing list