@@ -46,14 +46,17 @@ void * operator new[](std::size_t size) {
46
46
47
47
#if __cplusplus >= 201703L
48
48
void * operator new (std::size_t count, std::align_val_t al) {
49
+ (void )al; // unused
49
50
return operator new (count);
50
51
}
51
52
52
53
void * operator new [](std::size_t count, std::align_val_t al) {
54
+ (void )al; // unused
53
55
return operator new (count);
54
56
}
55
57
56
58
void * operator new (std::size_t size, std::align_val_t al, const std::nothrow_t tag) noexcept {
59
+ (void )al; (void )tag; // unused
57
60
#if defined(NEW_TERMINATES_ON_FAILURE)
58
61
// Cannot call throwing operator new as standard suggests, so call
59
62
// new_helper directly then
@@ -64,6 +67,7 @@ void * operator new(std::size_t size, std::align_val_t al, const std::nothrow_t
64
67
}
65
68
66
69
void * operator new [](std::size_t size, std::align_val_t al, const std::nothrow_t & tag) noexcept {
70
+ (void )al; (void )tag; // unused
67
71
#if defined(NEW_TERMINATES_ON_FAILURE)
68
72
// Cannot call throwing operator new[] as standard suggests, so call
69
73
// malloc directly then
@@ -75,6 +79,7 @@ void * operator new[](std::size_t size, std::align_val_t al, const std::nothrow_
75
79
#endif
76
80
77
81
void * operator new (std::size_t size, const std::nothrow_t tag) noexcept {
82
+ (void )tag; // unused
78
83
#if defined(NEW_TERMINATES_ON_FAILURE)
79
84
// Cannot call throwing operator new as standard suggests, so call
80
85
// new_helper directly then
@@ -84,6 +89,7 @@ void * operator new(std::size_t size, const std::nothrow_t tag) noexcept {
84
89
#endif
85
90
}
86
91
void * operator new [](std::size_t size, const std::nothrow_t & tag) noexcept {
92
+ (void )tag; // unused
87
93
#if defined(NEW_TERMINATES_ON_FAILURE)
88
94
// Cannot call throwing operator new[] as standard suggests, so call
89
95
// malloc directly then
@@ -111,17 +117,21 @@ void operator delete[](void * ptr) noexcept {
111
117
112
118
#if __cplusplus >= 201402L
113
119
void operator delete (void * ptr, std::size_t size) noexcept {
120
+ (void )size; // unused
114
121
operator delete (ptr);
115
122
}
116
123
void operator delete[] (void * ptr, std::size_t size) noexcept {
124
+ (void )size; // unused
117
125
operator delete[] (ptr);
118
126
}
119
127
#endif // __cplusplus >= 201402L
120
128
121
129
void operator delete (void * ptr, const std::nothrow_t & tag) noexcept {
130
+ (void )tag; // unused
122
131
operator delete (ptr);
123
132
}
124
133
void operator delete[] (void * ptr, const std::nothrow_t & tag) noexcept {
134
+ (void )tag; // unused
125
135
operator delete[] (ptr);
126
136
}
127
137
0 commit comments