[libcxx-commits] [PATCH] D98750: Apply [[standalone_debug]] to some types in the STL.

Louis Dionne via Phabricator via libcxx-commits libcxx-commits at lists.llvm.org
Wed Mar 31 09:48:32 PDT 2021

ldionne added a comment.

In D98750#2660132 <https://reviews.llvm.org/D98750#2660132>, @akhuang wrote:

> In D98750#2659984 <https://reviews.llvm.org/D98750#2659984>, @ldionne wrote:
>> It feels like I've done that before (if so please refresh my memory), but here's a patch trying to remove the UB we have in `std::list`: https://reviews.llvm.org/D99624. Could you please try it out and see if it fixes the issues you were seeing with `__list_node`? If it does, then I believe we can apply similar fixes to the other types and fix the underlying problem instead of applying this attribute which will only hide the issue.
> Thanks! I tried out the other patch and it does fix the issues with `__list_node`.

Thanks for trying it out. Depending on the outcome of the discussion currently happening on D99624 <https://reviews.llvm.org/D99624>, I would suggest that we follow a similar path for the other types instead of "hiding" the issue with the attribute.

If it is instead the case that D99624 <https://reviews.llvm.org/D99624> isn't actually fixing any UB (see discussion over there), then I believe it would be OK to move forward with this patch.

Also, how do you reproduce the issue you're fixing here? Is there a reasonably easy way to do that so we could add something to the test suite?

  rG LLVM Github Monorepo



More information about the libcxx-commits mailing list