Eric Niebler
Eric Niebler
Ah, should be something like `{ T{} } -> convertible_to`. The concepts language feature changed between the Concepts TS and C++20.
I don't test on MSVC. Patches welcome.
See [`take` from the Haskell Prelude](https://hackage.haskell.org/package/base-4.9.0.0/docs/Prelude.html#v:take) for a description. Meta already has `drop`, but I haven't found a way to implement `take` in O(1) so I haven't provided it.
I could add `is_callable_with`, which would be an alias for `has_type`. Why you think that a test for `is_convertible` is appropriate for metaprograms? > BTW, in order to avoid confusion...
That's why I suggested `is_callable_with`. And I think checking for `is_convertible` is actively hostile to metaprograms. At compile time, one type is not really "convertible" to another.
> Naming id a Callable that doesn't behaves as the identify Callable is disturbing. I'm not sure understand. What exactly is the problem?
> It's a misnomer to say that id is both a trait and a callable; the class template id is a trait, and its specializations are callables. (Yes, Trait is...
What, in your opinion, should `invoke` be?
> > It's a misnomer to say that id is both a trait and a callable; the class template id is a trait, and its specializations are callables. (Yes, Trait...
Use the source, Luke.