This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: Test for invalid optimization of ?: lvalue expression


This doesn't seem like a proper fix to me; obfuscating the trees to defeat
fold just hides the problem.  A better solution might be to turn the
expression in question into

  *((I != J) ? &I : &J)

How does the C frontend deal with using a cond_expr as an lvalue?

Jason

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]