[libcxx-commits] [PATCH] D144279: [libc++][format] Fixes formatting vector<bool>

Louis Dionne via Phabricator via libcxx-commits libcxx-commits at lists.llvm.org
Fri Mar 3 13:23:20 PST 2023


ldionne accepted this revision.
ldionne added a comment.
This revision is now accepted and ready to land.

LGTM



================
Comment at: libcxx/include/__bit_reference:158
 public:
+    using __container = typename _Cp::__self;
+
----------------
philnik wrote:
> Mordante wrote:
> > philnik wrote:
> > > Why not just `_Cp`?
> > To make sure this is used with a `std::vector`, similar to the friend at line 155.
> How would it not be used with a `std::vector` or `std::bitset`? If a user tries to instantiate it with another class it's not exactly hard to add the alias.
FWIW I think the `__self` thing is really weird, but I would support changing that in its own patch if we want to do something about it.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D144279



More information about the libcxx-commits mailing list