[libcxx-commits] [libcxx] [libcxxabi] [libc++] Introduce the notion of a minimum header version (PR #166074)

Nikolas Klauser via libcxx-commits libcxx-commits at lists.llvm.org
Mon Apr 20 03:49:34 PDT 2026


================
@@ -25,4 +27,6 @@ class _LIBCPP_EXPORTED_FROM_ABI bad_any_cast : public bad_cast {
 
 const char* bad_any_cast::what() const noexcept { return "bad any cast"; }
 
+#endif
+
 _LIBCPP_END_NAMESPACE_LFTS
----------------
philnik777 wrote:

Oops, the namespace end should indeed be inside the condition.



> If this isn't at all tested for values >= 7, why have this toggle?

It's currently not properly tested, but should be used in the future. The main reason this isn't tested is that I simply don't know which value this should be set to on different platforms. The plan is also to make this equal to the current libc++ version with `LIBCXX_ABI_UNSTABLE`, but that simply hasn't happened yet (which should also address your comment below). I'd be happy to hear about any problems similar to this if you find some while testing.

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


More information about the libcxx-commits mailing list