[libc-commits] [libc] [libc] implement stdc_leading_zeros_u* for stdbit.h (PR #79669)

Nick Desaulniers via libc-commits libc-commits at lists.llvm.org
Mon Jan 29 10:27:57 PST 2024


================
@@ -14,3 +14,22 @@ add_libc_test(
     # This is needed because the __containerof macro uses statement expression.
     -Wno-gnu-statement-expression-from-macro-expansion
 )
+
+add_libc_test(
+  stdbit_test
+  SUITE
+    libc_include_tests
+  SRCS
+    stdbit_test.cpp
+  DEPENDS
+    libc.__support.CPP.limits
+    libc.include.llvm-libc-macros.stdbit_macros
+    libc.src.stdbit.stdc_leading_zeros_uc
+    libc.src.stdbit.stdc_leading_zeros_ui
+    libc.src.stdbit.stdc_leading_zeros_ul
+    libc.src.stdbit.stdc_leading_zeros_ull
+    libc.src.stdbit.stdc_leading_zeros_us
+  COMPILE_OPTIONS
+    # stdbit is full of type generic macros implemented via C11 _Generic.
----------------
nickdesaulniers wrote:

added more info in dfbf115e640e, but let me know if there's a better way to word this.

https://github.com/llvm/llvm-project/pull/79669


More information about the libc-commits mailing list