Open cassioneri opened 2 months ago
@llvm/issue-subscribers-clang-codegen
Author: Cassio Neri (cassioneri)
It looks a lot like: https://github.com/llvm/llvm-project/issues/88104
CC @zyn0217
Assertion: https://godbolt.org/z/x8KMz5vK8
clang++: /root/llvm-project/clang/lib/AST/Decl.cpp:2550:
clang::APValue* clang::VarDecl::evaluateValueImpl(llvm::SmallVectorImpl<std::pair<clang::SourceLocation, clang::PartialDiagnostic> >&, bool) const:
Assertion `!Init->isValueDependent()' failed.
This program crashes clang++ (since version 12.0.0):
Either of the following changes make it to compile:
decltype(&b)
withauto
;x
asconst
.See https://godbolt.org/z/1oxWGfE3T
Here is the crash report: --->8---
--->8--- Preprocessed source and associated script attached (with extensions changed to
txt
to bypass GitHub's refusal to attach.cpp
and.sh
) main-473bc6-sh.txt main-473bc6-cpp.txt