[libcxx-commits] [PATCH] D60368: Add bind_front function (P0356R5)
Zoe Carver via Phabricator via libcxx-commits
libcxx-commits at lists.llvm.org
Tue Apr 23 10:56:07 PDT 2019
zoecarver marked 3 inline comments as done.
zoecarver added inline comments.
================
Comment at: include/functional:2875
+template<class _Fn, class... _Args>
+inline auto bind_front(_Fn&& __f, _Args&&... __args)
+{
----------------
The return type of this function is not specified, it might be beneficial to make it a `constexpr` (though that would require other parts of this to be updated and might not work). Thoughts?
================
Comment at: test/std/utilities/function.objects/func.bind_front/bind_front.fail.cpp:30
+ auto p = std::bind_front(pass, c);
+ static_assert(p() == 1); // expected-error {{static_assert expression is not an integral constant expression}}
+
----------------
I am unsure of how to format the fail tests.
================
Comment at: test/std/utilities/function.objects/func.not_fn/not_fn.pass.cpp:432
- try {
- (void)std::not_fn(cp);
- assert(false);
----------------
I am not sure why this was expected to throw. I //think// this can simply be moved (but I might be wrong).
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D60368/new/
https://reviews.llvm.org/D60368
More information about the libcxx-commits
mailing list