This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
Re: Fortran ICE
On Mon, Oct 29, 2001 at 06:14:07AM -0800, Tim Prince wrote:
> I don't think this combination of extensions to Fortran makes sense.
> %val() would say to pass a value stored in memory rather than a reference
> to it, and I think it is not supported reliably anyway by g77. Setting
> the value as a parameter allows the compiler to avoid storing it in
> memory. Optimization level may make a difference. With g77, you would
> not get a reference to an exit() function in the C library (which would
> accept a call by value), unless you took specific action to make it so
> (such as invoking -fno-underscoring). It makes no sense anyway to use a
> C exit() from a program with a Fortran main.
The original testcase actually used -fno-underscoring.
If this doesn't make sense, then either g77 should issue an error message,
or compile it somehow, ICEs really shouldn't happen even on bad input.
Jakub