aboutsummaryrefslogtreecommitdiff
path: root/clang/lib/AST/ByteCode/Compiler.cpp
diff options
context:
space:
mode:
authorTimm Baeder <tbaeder@redhat.com>2025-08-27 12:04:44 +0200
committerGitHub <noreply@github.com>2025-08-27 12:04:44 +0200
commit16494be2e8861ae988cb5decbede1f9242286b92 (patch)
treeca3d581be995a7890d7153b11111b1c4e62edfd8 /clang/lib/AST/ByteCode/Compiler.cpp
parent75b36d043e9992ec7c52c7d17f989c09a76011c7 (diff)
downloadllvm-16494be2e8861ae988cb5decbede1f9242286b92.zip
llvm-16494be2e8861ae988cb5decbede1f9242286b92.tar.gz
llvm-16494be2e8861ae988cb5decbede1f9242286b92.tar.bz2
[clang][bytecode] Reject dependent RequiresExprs (#155230)
Fixes #152899
Diffstat (limited to 'clang/lib/AST/ByteCode/Compiler.cpp')
-rw-r--r--clang/lib/AST/ByteCode/Compiler.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/clang/lib/AST/ByteCode/Compiler.cpp b/clang/lib/AST/ByteCode/Compiler.cpp
index ea6195c..8ed9e64 100644
--- a/clang/lib/AST/ByteCode/Compiler.cpp
+++ b/clang/lib/AST/ByteCode/Compiler.cpp
@@ -3895,6 +3895,8 @@ bool Compiler<Emitter>::VisitCXXUuidofExpr(const CXXUuidofExpr *E) {
template <class Emitter>
bool Compiler<Emitter>::VisitRequiresExpr(const RequiresExpr *E) {
assert(classifyPrim(E->getType()) == PT_Bool);
+ if (E->isValueDependent())
+ return false;
if (DiscardResult)
return true;
return this->emitConstBool(E->isSatisfied(), E);