comparison: sources/basics.h
sources/basics.h
- changeset 15
- 33da84af4bba
- parent 14
- 33b8f428bacb
- child 17
- 50341dec533e
equal
deleted
inserted
replaced
29 */ |
29 */ |
30 |
30 |
31 #pragma once |
31 #pragma once |
32 #include <algorithm> |
32 #include <algorithm> |
33 #include <functional> |
33 #include <functional> |
34 #include <memory> |
|
35 |
34 |
36 #define FUNCTION auto |
35 #define FUNCTION auto |
37 #define STATIC |
36 #define STATIC |
38 #define METHOD auto |
37 #define METHOD auto |
39 #define MACRO_TO_STRING_2(A) #A |
38 #define MACRO_TO_STRING_2(A) #A |
42 class String; |
41 class String; |
43 |
42 |
44 using std::swap; |
43 using std::swap; |
45 using std::min; |
44 using std::min; |
46 using std::max; |
45 using std::max; |
47 |
|
48 template<typename T> |
|
49 using SharedPointer = std::shared_ptr<T>; |
|
50 |
|
51 template<typename T> |
|
52 using WeakPointer = std::weak_ptr<T>; |
|
53 |
46 |
54 enum Color |
47 enum Color |
55 { |
48 { |
56 BLACK, |
49 BLACK, |
57 RED, |
50 RED, |