blob: caf6d64b0ca1b98cb2275f2f220ac16990962931 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
|
//===----------------------------------------------------------------------===//
//
// The LLVM Compiler Infrastructure
//
// This file is dual licensed under the MIT and the University of Illinois Open
// Source Licenses. See LICENSE.TXT for details.
//
//===----------------------------------------------------------------------===//
// <functional>
//
// bind2nd
// REQUIRES: verify-support
// MODULES_DEFINES: _LIBCPP_ENABLE_DEPRECATION_WARNINGS
// MODULES_DEFINES: _LIBCPP_ENABLE_CXX17_REMOVED_BINDERS
#define _LIBCPP_ENABLE_DEPRECATION_WARNINGS
#define _LIBCPP_ENABLE_CXX17_REMOVED_BINDERS
#include <functional>
#include "../test_func.h"
#include "test_macros.h"
int main()
{
#if TEST_STD_VER < 11
// expected-no-diagnostics
#else
// expected-error@* 1 {{'bind2nd<test_func, int>' is deprecated}}
#endif
std::bind2nd(test_func(1), 5);
}
|