https://gcc.gnu.org/bugzilla/show_bug.cgi?id=50169

--- Comment #8 from Nathan Ridge <zeratul976 at hotmail dot com> ---
(In reply to Eric Gallager from comment #7)
> (In reply to Nathan Ridge from comment #6)
> > Here is another test case that MSVC accepts but GCC rejects:
> > 
> > struct A {};
> > struct A* b = (1 == 1) ? new struct A : new struct A;
> 
> Is this really the same thing though?

I believe it's code that was made valid by DR2141, yes. I elaborate on my
reasoning in the corresponding clang bug:

https://bugs.llvm.org/show_bug.cgi?id=34993

Reply via email to