[JAVA PATCH] SAVE_EXPR evaluate-once semantics in jcf-write.c

Jason Merrill jason@redhat.com
Mon Sep 29 17:36:00 GMT 2003


On Mon, 29 Sep 2003 11:02:12 +0100, Andrew Haley <aph@redhat.com> wrote:

> Roger Sayle writes:

>  > > What we should do is use a "let expression":
>  > >
>  > > LET tmp := expression IN f(use tmp, use tmp)
>  > >
>  > > This provides an explicit well-defined scope for the temporary.
>  > 
>  > As mentioned above, this may be a good idea.
>
> Yes, indeed.  This does seem to be more civilized than SAVE_EXPR.
>
>  > I'll let the GIMPLE folks argue of the merits of allowing a form of
>  > SCOPE_EXPR within expressions.
>
> I would have thought that expanding an inline function generates
> something similar.

Sounds like you want BIND_EXPR.

Jason



More information about the Java-patches mailing list