[PATCH] D135799: libcxxabi [PR58117][NFC]: Open code lower bound

Nathan Sidwell via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Oct 20 04:26:44 PDT 2022


urnathan added a comment.

In D135799#3855483 <https://reviews.llvm.org/D135799#3855483>, @urnathan wrote:

> In D135799#3855419 <https://reviews.llvm.org/D135799#3855419>, @ldionne wrote:
>
>> I think it would actually be better to define `#define _LIBCPP_ENABLE_ASSERTIONS 0` at the top of the file. That way, we (1) retain the ability to use `std` algorithms, and we don't risk someone else breaking this in the future. WDYT?
>
> I thought you disliked that solution -- have you changed your mind?  (the define would work for me too)

I've realized the #define solution is unfriendly to header-units/clang-modules, and introduces an ODR problem -- the definitions for templates etc will not be the same.


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

https://reviews.llvm.org/D135799



More information about the llvm-commits mailing list