[libc-commits] [PATCH] D73472: [libc] Add utils for memory functions

Alex Brachet via Phabricator via libc-commits libc-commits at lists.llvm.org
Wed Jan 29 15:56:33 PST 2020


abrachet added inline comments.


================
Comment at: libc/test/src/string/details/utils_test.cpp:25
+  for (size_t i = 0; i < kExpectedValues.size(); ++i)
+    ASSERT_EQ((int)is_power2_or_zero(i), kExpectedValues[i]);
+}
----------------
I think all of the `ASSERT_*`'s could be `EXPECT_*` instead. As a matter of preference I think ASSERT should be used to test invariants that would lead to other failures or crashes. No strong preference.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D73472/new/

https://reviews.llvm.org/D73472





More information about the libc-commits mailing list