Skip to content

Commit 92e5060

Browse files
[AST] Fix a warning
This patch fixes: clang/lib/AST/ByteCode/InterpBuiltin.cpp:2603:15: error: unused variable 'VT1' [-Werror,-Wunused-variable]
1 parent de80c36 commit 92e5060

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

clang/lib/AST/ByteCode/InterpBuiltin.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2600,7 +2600,8 @@ static bool
26002600
interp__builtin_x86_pack(InterpState &S, CodePtr, const CallExpr *E,
26012601
llvm::function_ref<APInt(const APSInt &)> PackFn) {
26022602
const auto *VT0 = E->getArg(0)->getType()->castAs<VectorType>();
2603-
const auto *VT1 = E->getArg(1)->getType()->castAs<VectorType>();
2603+
[[maybe_unused]] const auto *VT1 =
2604+
E->getArg(1)->getType()->castAs<VectorType>();
26042605
assert(VT0 && VT1 && "pack builtin VT0 and VT1 must be VectorType");
26052606
assert(VT0->getElementType() == VT1->getElementType() &&
26062607
VT0->getNumElements() == VT1->getNumElements() &&

0 commit comments

Comments
 (0)