[C++ PATCH] Fix ice-on-invalid (i ? j : k) = (void) bar (); (PR c++/30847)

Nathan Sidwell nathan@codesourcery.com
Wed Mar 28 11:43:00 GMT 2007


Jakub Jelinek wrote:
>
> 
> 2007-03-19  Jakub Jelinek  <jakub@redhat.com>
> 
> 	PR c++/30847
> 	* typeck.c (build_modify_expr): Don't call stabilize_expr on RHS
> 	if RHS has void type.
> 
> 	* g++.dg/parse/cond3.C: New test.

ok (except the changelog isn't exactly describing the 'bail out on assigning a 
void type' behaviour :))

nathan
-- 
Nathan Sidwell    ::   http://www.codesourcery.com   ::         CodeSourcery
nathan@codesourcery.com    ::     http://www.planetfall.pwp.blueyonder.co.uk



More information about the Gcc-patches mailing list