File tree Expand file tree Collapse file tree 2 files changed +3
-10
lines changed Expand file tree Collapse file tree 2 files changed +3
-10
lines changed Original file line number Diff line number Diff line change @@ -95,14 +95,6 @@ struct aligned_alloc<Alignment_, true> {
95
95
free (ptr);
96
96
#endif
97
97
}
98
-
99
- #if defined(_WIN32)
100
- // FIXME: why is this even needed? This is not permitted as per the C++
101
- // standrd new.delete.placement (§17.6.3.4).
102
- [[nodiscard]] void *operator new (std::size_t size, void *where) noexcept {
103
- return ::operator new (size, where);
104
- }
105
- #endif
106
98
};
107
99
108
100
// / The default implementation for swift::atomic<T>, which just wraps
Original file line number Diff line number Diff line change 51
51
#include " EnumImpl.h"
52
52
53
53
#include < cstring>
54
+ #include < new>
54
55
#include < type_traits>
55
56
56
57
namespace swift {
@@ -99,11 +100,11 @@ struct NativeBox {
99
100
}
100
101
101
102
static T *initializeWithCopy (T *dest, T *src) {
102
- return new (dest) T (*src);
103
+ return :: new (dest) T (*src);
103
104
}
104
105
105
106
static T *initializeWithTake (T *dest, T *src) {
106
- T *result = new (dest) T (std::move (*src));
107
+ T *result = :: new (dest) T (std::move (*src));
107
108
src->T ::~T ();
108
109
return result;
109
110
}
You can’t perform that action at this time.
0 commit comments