[libc-commits] [libc] [libc] fix typo introduced in inline_bcmp_byte_per_byte (PR #83356)
via libc-commits
libc-commits at lists.llvm.org
Wed Feb 28 15:51:23 PST 2024
llvmbot wrote:
<!--LLVM PR SUMMARY COMMENT-->
@llvm/pr-subscribers-libc
Author: Nick Desaulniers (nickdesaulniers)
<details>
<summary>Changes</summary>
My global find+replace was overzealous and broke post submit unit tests.
Link: #<!-- -->83345
---
Full diff: https://github.com/llvm/llvm-project/pull/83356.diff
1 Files Affected:
- (modified) libc/src/string/memory_utils/generic/byte_per_byte.h (+1-1)
``````````diff
diff --git a/libc/src/string/memory_utils/generic/byte_per_byte.h b/libc/src/string/memory_utils/generic/byte_per_byte.h
index 948da8ab2a8702..9515398794df40 100644
--- a/libc/src/string/memory_utils/generic/byte_per_byte.h
+++ b/libc/src/string/memory_utils/generic/byte_per_byte.h
@@ -56,7 +56,7 @@ inline_bcmp_byte_per_byte(CPtr p1, CPtr p2, size_t count, size_t offset = 0) {
LIBC_LOOP_NOUNROLL
for (; offset < count; ++offset)
if (p1[offset] != p2[offset])
- return BcmpReturnType::zero();
+ return BcmpReturnType::nonzero();
return BcmpReturnType::zero();
}
``````````
</details>
https://github.com/llvm/llvm-project/pull/83356
More information about the libc-commits
mailing list