Author: Lei Huang Date: 2022-06-16T17:20:31-05:00 New Revision: dba2ff500d5b29f2d18b93aed5caa5b4ef7c94dd
URL: https://github.com/llvm/llvm-project/commit/dba2ff500d5b29f2d18b93aed5caa5b4ef7c94dd DIFF: https://github.com/llvm/llvm-project/commit/dba2ff500d5b29f2d18b93aed5caa5b4ef7c94dd.diff LOG: fix x86 sanitizer failure due to use of or Added: Modified: clang/lib/CodeGen/CGBuiltin.cpp Removed: ################################################################################ diff --git a/clang/lib/CodeGen/CGBuiltin.cpp b/clang/lib/CodeGen/CGBuiltin.cpp index 662a6637bd4a..ce4ecc5c3284 100644 --- a/clang/lib/CodeGen/CGBuiltin.cpp +++ b/clang/lib/CodeGen/CGBuiltin.cpp @@ -15613,7 +15613,7 @@ Value *CodeGenFunction::EmitPPCBuiltinExpr(unsigned BuiltinID, RangeErrMsg += llvm::to_string(ValidMaxValue) + "]"; // Issue error if third argument is not within the valid range. - if (ConstArg < 0 or ConstArg > ValidMaxValue) + if (ConstArg < 0 || ConstArg > ValidMaxValue) CGM.Error(E->getExprLoc(), RangeErrMsg); // Input to vec_replace_elt is an element index, convert to byte index. _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits