Bug 93348 reports an ICE on certain cases of casts of expressions that may appear only in unevaluated parts of integer constant expressions, arising from the generation of nested C_MAYBE_CONST_EXPRs. This patch fixes it by adding a call to remove_c_maybe_const_expr in the integer-operands case, as is done in other similar cases. Bootstrapped with no regressions for x86_64-pc-linux-gnu. PR c/93348 gcc/c: * c-typeck.c (build_c_cast): Call remove_c_maybe_const_expr on argument with integer operands. gcc/testsuite: * gcc.c-torture/compile/pr93348-1.c: New test.
Name |
Last commit
|
Last update |
---|---|---|
.. | ||
ChangeLog | Loading commit data... | |
Make-lang.in | Loading commit data... | |
c-aux-info.c | Loading commit data... | |
c-convert.c | Loading commit data... | |
c-decl.c | Loading commit data... | |
c-errors.c | Loading commit data... | |
c-fold.c | Loading commit data... | |
c-lang.c | Loading commit data... | |
c-lang.h | Loading commit data... | |
c-objc-common.c | Loading commit data... | |
c-objc-common.h | Loading commit data... | |
c-parser.c | Loading commit data... | |
c-parser.h | Loading commit data... | |
c-tree.h | Loading commit data... | |
c-typeck.c | Loading commit data... | |
config-lang.in | Loading commit data... | |
gccspec.c | Loading commit data... | |
gimple-parser.c | Loading commit data... | |
gimple-parser.h | Loading commit data... |