Skip to content

Commit f487c0e

Browse files
[AST] Fix warnings
This patch fixes: clang/lib/AST/ByteCode/InterpBuiltin.cpp:1827:21: error: unused variable 'ASTCtx' [-Werror,-Wunused-variable] clang/lib/AST/ByteCode/InterpBuiltin.cpp:2724:18: error: unused variable 'Arg2Type' [-Werror,-Wunused-variable] clang/lib/AST/ByteCode/InterpBuiltin.cpp:2725:18: error: unused variable 'Arg3Type' [-Werror,-Wunused-variable] clang/lib/AST/ByteCode/InterpBuiltin.cpp:2748:18: error: unused variable 'ElemT' [-Werror,-Wunused-variable]
1 parent a6da68e commit f487c0e

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

clang/lib/AST/ByteCode/InterpBuiltin.cpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1830,6 +1830,7 @@ static bool interp__builtin_elementwise_countzeroes(InterpState &S,
18301830
assert(Call->getArg(1)->getType()->isVectorType() &&
18311831
ASTCtx.hasSameUnqualifiedType(Call->getArg(0)->getType(),
18321832
Call->getArg(1)->getType()));
1833+
(void)ASTCtx;
18331834
ZeroArg = S.Stk.pop<Pointer>();
18341835
assert(ZeroArg.getFieldDesc()->isPrimitiveArray());
18351836
}
@@ -2728,6 +2729,8 @@ static bool interp__builtin_elementwise_fma(InterpState &S, CodePtr OpPC,
27282729
if (!Arg1Type->isVectorType()) {
27292730
assert(!Arg2Type->isVectorType());
27302731
assert(!Arg3Type->isVectorType());
2732+
(void)Arg2Type;
2733+
(void)Arg3Type;
27312734

27322735
const Floating &Z = S.Stk.pop<Floating>();
27332736
const Floating &Y = S.Stk.pop<Floating>();
@@ -2753,6 +2756,7 @@ static bool interp__builtin_elementwise_fma(InterpState &S, CodePtr OpPC,
27532756
assert(NumElems == Arg2Type->castAs<VectorType>()->getNumElements() &&
27542757
NumElems == Arg3Type->castAs<VectorType>()->getNumElements());
27552758
assert(ElemT->isRealFloatingType());
2759+
(void)ElemT;
27562760

27572761
const Pointer &VZ = S.Stk.pop<Pointer>();
27582762
const Pointer &VY = S.Stk.pop<Pointer>();

0 commit comments

Comments
 (0)