ICE in change_address at emit_rtl.c

Fergus Henderson fjh@cs.mu.oz.au
Sun Nov 25 21:58:00 GMT 2001


On 23-Nov-2001, Neil Booth <neil@daikokuya.demon.co.uk> wrote:
> Gabriel Dos Reis wrote:-
> > Neil Booth <neil@daikokuya.demon.co.uk> writes:
> > 
> > | I've not been able to find a satisfactory fix; since I'm not a fan of
> > | error_mark_node-s I don't want to introduce yet more checks for them.
> > | I hate the error_mark_node stuff; it would be nice if it could go
> > | away.
> > 
> > What should be the alternative?
> 
> Generate something that is valid, even if it's not what the user
> specified.  e.g. if it's an invalid typedef, typedef it to int (or
> something more intelligent if possible) rather than error_mark_node.

But that will cause spurious flow-on errors when the
type is used in some way for which `int' is not valid.

The only way to avoid all such spurious flow-on errors is to have a type
(or expression, declaration, etc.) for which *all* operations are valid.

And if you have such a type (or expression, declaration, etc.), then
whatever you end up calling it, you will have reinvented something
very similar to the error_mark_node approach.

The main way in which it could usefully vary, IMHO, is that you might
want to have different nodes for error_mark_type, error_mark_expr,
error_mark_decl, etc.

-- 
Fergus Henderson <fjh@cs.mu.oz.au>  |  "I have always known that the pursuit
The University of Melbourne         |  of excellence is a lethal habit"
WWW: < http://www.cs.mu.oz.au/~fjh >  |     -- the last words of T. S. Garp.



More information about the Gcc mailing list