aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/Support/CommandLine.cpp
diff options
context:
space:
mode:
authorMatheus Izvekov <mizvekov@gmail.com>2021-07-06 00:24:43 +0200
committerMatheus Izvekov <mizvekov@gmail.com>2021-07-08 20:23:19 +0200
commit5a1c50410ccc1973a1a0a4acca0c01677c28e9b6 (patch)
tree0f7747cc9c2e19d96681da3684d291d6f8ac4992 /llvm/lib/Support/CommandLine.cpp
parentde5582be26b771c31e4333520c12ea65cec03ee5 (diff)
downloadllvm-5a1c50410ccc1973a1a0a4acca0c01677c28e9b6.zip
llvm-5a1c50410ccc1973a1a0a4acca0c01677c28e9b6.tar.gz
llvm-5a1c50410ccc1973a1a0a4acca0c01677c28e9b6.tar.bz2
[clang] fix constexpr code generation for user conversions.
When building the member call to a user conversion function during an implicit cast, the expression was not being checked for immediate invocation, so we were never adding the ConstantExpr node to AST. This would cause the call to the user conversion operator to be emitted even if it was constantexpr evaluated, and this would even trip an assert when said user conversion was declared consteval: `Assertion failed: !cast<FunctionDecl>(GD.getDecl())->isConsteval() && "consteval function should never be emitted", file clang\lib\CodeGen\CodeGenModule.cpp, line 3530` Fixes PR48855. Signed-off-by: Matheus Izvekov <mizvekov@gmail.com> Reviewed By: rsmith Differential Revision: https://reviews.llvm.org/D105446
Diffstat (limited to 'llvm/lib/Support/CommandLine.cpp')
0 files changed, 0 insertions, 0 deletions