[PATCH] D55045: Add a version of std::function that includes a few optimizations.

Jordan Soyke via Phabricator reviews at reviews.llvm.org
Fri Nov 30 21:07:22 PST 2018

jsoyke added inline comments.

Comment at: include/functional:1610
+// DO NOT SUBMIT: The optimized function doesn't work with allocators. It should
+// probably just require C++ > 14 before sending out a patch.
EricWF wrote:
> This implementation must work in all dialects (likely including C++03 w/ Clang extensions :-S ). So it has to support allocators.
> At minimum it needs to support calling the allocator constructors. We may be able to get away with ignoring the allocator though. I'll have to ask my other maintainers.
> Let me know if you want some help adding allocator support.
Done, but I think I should add some test coverage before declaring triumph.

I wouldn't mind ignoring the arguments though if that's preferable for some reason, a few code paths already do (copying from an existing std::function for example).

  rCXX libc++



More information about the libcxx-commits mailing list