[libcxx-commits] [PATCH] D99041: [libcxx] moves `std::invoke` into `__functional_base`

Louis Dionne via Phabricator via libcxx-commits libcxx-commits at lists.llvm.org
Mon Mar 22 08:32:22 PDT 2021

ldionne requested changes to this revision.
ldionne added a comment.
This revision now requires changes to proceed.

Regarding using `__invoke` in the concept: I'm against that, the reason is not about introducing a bug in the future, it's just about reasoning. I want to be able to read the concept and have it be pretty much verbatim the same as specified in the Standard. There are better ways to get rid of header dependencies than changing the code to use a proxy function instead of the real one.

I am in the camp of @cjdb here:

> Agreed, +100, etc.. I'm considering writing to libc++ mailing to suggest we move all names into their own headers (e.g. <__functional/invoke>, <__functional/function>, etc.) and the standard headers just include <__header_name/*> (where * is a placeholder and not what we really include).

I would support such an effort. I'm not exactly sure what granularity we need to reach, however it's clear to me that moving stuff into `__functional_base` is just a band-aid. We should also split up `__functional_base` itself.

  rG LLVM Github Monorepo



More information about the libcxx-commits mailing list