https://github.com/tbaederr created https://github.com/llvm/llvm-project/pull/217877
None >From 1be9e95870868640f82daf35c946c5644f6ee6a6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Timm=20B=C3=A4der?= <[email protected]> Date: Fri, 21 Aug 2026 12:45:57 +0200 Subject: [PATCH] [clang][bytecode][NFC] Remove unsed parameter --- clang/lib/AST/ByteCode/EvalEmitter.cpp | 4 ++-- clang/lib/AST/ByteCode/EvaluationResult.cpp | 1 - clang/lib/AST/ByteCode/EvaluationResult.h | 4 ++-- 3 files changed, 4 insertions(+), 5 deletions(-) diff --git a/clang/lib/AST/ByteCode/EvalEmitter.cpp b/clang/lib/AST/ByteCode/EvalEmitter.cpp index 59eb2731534ce..6233be831f9f2 100644 --- a/clang/lib/AST/ByteCode/EvalEmitter.cpp +++ b/clang/lib/AST/ByteCode/EvalEmitter.cpp @@ -254,7 +254,7 @@ template <> bool EvalEmitter::emitRet<PT_Ptr>(SourceInfo Info) { if (this->PtrCB) return (*this->PtrCB)(S, CodePtr(), Ptr); - if (!EvalResult.checkDynamicAllocations(S, Ctx, Ptr, Info)) + if (!EvalResult.checkDynamicAllocations(S, Ptr, Info)) return false; if (CheckFullyInitialized && !EvalResult.checkFullyInitialized(S, Ptr)) return false; @@ -324,7 +324,7 @@ bool EvalEmitter::emitRetVoid(SourceInfo Info) { bool EvalEmitter::emitRetValue(SourceInfo Info) { const auto &Ptr = S.Stk.pop<Pointer>(); - if (!EvalResult.checkDynamicAllocations(S, Ctx, Ptr, Info)) + if (!EvalResult.checkDynamicAllocations(S, Ptr, Info)) return false; if (CheckFullyInitialized && !EvalResult.checkFullyInitialized(S, Ptr)) return false; diff --git a/clang/lib/AST/ByteCode/EvaluationResult.cpp b/clang/lib/AST/ByteCode/EvaluationResult.cpp index 19a2744f73f15..6597ea062a8fb 100644 --- a/clang/lib/AST/ByteCode/EvaluationResult.cpp +++ b/clang/lib/AST/ByteCode/EvaluationResult.cpp @@ -244,7 +244,6 @@ static void collectBlocks(PtrView Ptr, llvm::SetVector<const Block *> &Blocks, } bool EvaluationResult::checkDynamicAllocations(InterpState &S, - const Context &Ctx, const Pointer &Ptr, SourceInfo Info) { if (!Ptr.isBlockPointer()) diff --git a/clang/lib/AST/ByteCode/EvaluationResult.h b/clang/lib/AST/ByteCode/EvaluationResult.h index 1edd9bc55406a..b8d8ddf981f5a 100644 --- a/clang/lib/AST/ByteCode/EvaluationResult.h +++ b/clang/lib/AST/ByteCode/EvaluationResult.h @@ -80,8 +80,8 @@ class EvaluationResult final { bool checkFullyInitialized(InterpState &S, const Pointer &Ptr) const; /// Check that none of the blocks the given pointer (transitively) points /// to are dynamically allocated. - bool checkDynamicAllocations(InterpState &S, const Context &Ctx, - const Pointer &Ptr, SourceInfo Info); + bool checkDynamicAllocations(InterpState &S, const Pointer &Ptr, + SourceInfo Info); QualType getSourceType() const { if (const auto *D = Source.asValueDecl()) _______________________________________________ cfe-commits mailing list [email protected] https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
