------- Comment #5 from redi at gcc dot gnu dot org 2010-04-29 14:11 ------- the definition of integral constant expression has changed between C++03 and C++0x, so that int() is a valid integral constant expression, as is int(b?0:0)
So that makes my 'f' and 'g' examples valid. However, by [expr.const] a conditional-expression is not a constant expression if it contains a throw-expression, so Andreas was 100% correct in comment 2 and the original report is invalid. It should be return b ? (void*)0 : throw 5 -- redi at gcc dot gnu dot org changed: What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |RESOLVED Resolution| |INVALID http://gcc.gnu.org/bugzilla/show_bug.cgi?id=43932