-
Notifications
You must be signed in to change notification settings - Fork 0
/
main.cpp
51 lines (34 loc) · 948 Bytes
/
main.cpp
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
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
#include <iostream>
#include "ffffff/debug_tools.h"
#include "ffffff/utils.hpp"
#include "ffffff/bind.hpp"
#include "ffffff/tmf.hpp"
#include "tu_1.h"
class Bar {
friend class fff::AsSingle<Bar>;
Bar() = default;
public:
Bar(const Bar&) = delete;
Bar(Bar&&) = delete;
Bar &operator=(const Bar&) = delete;
Bar &operator=(Bar&&) = delete;
void say_hello() const {
std::cout << "Say, Hello!\n";
}
};
class Foo {
int a, b, c, d;
};
int main() {
pipeop_test();
auto plus = [](int a, int b) {return a + b;};
auto ttt = std::bind(plus, 1, std::placeholders::_1);
static_assert(sizeof(ttt) == 8);
auto uuu = fff::static_l_bind<1>(plus);
static_assert(sizeof(uuu) == 1);
int zz = 1;
auto vvv = std::bind(plus, zz, std::placeholders::_1);
auto xxx = std::bind_front(plus, 6, 2);
static_assert(sizeof(vvv) == 8 and sizeof(xxx) == 12);
test1();
}