https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66963
Richard Biener rguenth at gcc dot gnu.org changed:
What|Removed |Added
Status|UNCONFIRMED |RESOLVED
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66963
--- Comment #6 from Nicolai Stange nicstange at gmail dot com ---
Thank you for your clarifications, Andrew and Joseph.
As far as I am concerned, this bug can be marked as resolved/rejected/whatever
you like.
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66963
--- Comment #5 from joseph at codesourcery dot com joseph at codesourcery dot
com ---
This is by design. __builtin_choose_expr requires an integer constant
expression which must be evaluated before the type of the result can be
known;
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66963
--- Comment #1 from Andrew Pinski pinskia at gcc dot gnu.org ---
I thought this is documented somewhere but __builtin_choose_expr only really
accept constant literals and not constexprs.
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66963
--- Comment #2 from Andrew Pinski pinskia at gcc dot gnu.org ---
(In reply to Andrew Pinski from comment #1)
I thought this is documented somewhere but __builtin_choose_expr only really
accept constant literals and not constexprs.
And the main
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66963
--- Comment #3 from Nicolai Stange nicstange at gmail dot com ---
(In reply to Andrew Pinski from comment #1)
I thought this is documented somewhere but __builtin_choose_expr only really
accept constant literals and not constexprs.
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66963
--- Comment #4 from Nicolai Stange nicstange at gmail dot com ---
Sorry, misunderstanding at my side. You probably did not mean constexprs in the
sense of C99, 6.6, but constexprs in the sense of constant folded expressions.