Open
Description
Testcase:
struct A {int x[1]; };
A f();
typedef int *t[];
consteval int* f(int* x) { return x; }
int ** x = (t){f(f().x)};
Crashes with:
clang: clang/lib/AST/Expr.cpp:339: static clang::ConstantExpr *clang::ConstantExpr::Create(const clang::ASTContext &, clang::Expr *, clang::ConstantResultStorageKind, bool): Assertion `!isa<ConstantExpr>(E)' failed.
PLEASE submit a bug report to https://github.com/llvm/llvm-project/issues/ and include the crash backtrace, preprocessed source, and associated run script.
Stack dump:
0. Program arguments: clang -x c++ - -o - -S -std=c++20
1. <stdin>:5:25: current parser token ';'