Skip to content

Commit 50d4023

Browse files
committed
Explain passing template function as an argument
Addresses (maybe) #81055 (comment)
1 parent 730b4e7 commit 50d4023

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

libcxx/test/std/utilities/function.objects/func.bind.partial/bind_back.verify.cpp

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,9 @@ void test() {
2525
static_assert(f1() == 1); // expected-error {{static assertion expression is not an integral constant expression}}
2626
}
2727

28-
{ // Various failures
29-
auto d = std::bind_back(do_nothing, 2); // expected-error {{no matching function for call to 'bind_back'}}
28+
{ // Test calling `bind_back` with template function
29+
auto f1 = std::bind_back(do_nothing, 2);
30+
// expected-error@-1 {{no matching function for call to 'bind_back'}}
3031
}
3132

3233
{ // Mandates: is_constructible_v<decay_t<F>, F>

0 commit comments

Comments
 (0)