File tree Expand file tree Collapse file tree 1 file changed +7
-2
lines changed Expand file tree Collapse file tree 1 file changed +7
-2
lines changed Original file line number Diff line number Diff line change @@ -180,8 +180,9 @@ template <typename T> class ImmutablePointerSetFactory {
180
180
using PtrTy = typename std::add_pointer<T>::type;
181
181
182
182
using PtrSet = ImmutablePointerSet<T>;
183
- static constexpr unsigned AllocAlignment =
184
- (alignof (PtrSet) > alignof (PtrTy)) ? alignof(PtrSet) : alignof(PtrTy);
183
+ // This is computed out-of-line so that ImmutablePointerSetFactory is
184
+ // treated as a complete type.
185
+ static const unsigned AllocAlignment;
185
186
186
187
llvm::BumpPtrAllocator &Allocator;
187
188
llvm::FoldingSetVector<PtrSet> Set;
@@ -347,6 +348,10 @@ template <typename T>
347
348
ImmutablePointerSet<T> ImmutablePointerSetFactory<T>::EmptyPtrSet =
348
349
ImmutablePointerSet<T>(nullptr , {});
349
350
351
+ template <typename T>
352
+ constexpr unsigned ImmutablePointerSetFactory<T>::AllocAlignment =
353
+ (alignof (PtrSet) > alignof (PtrTy)) ? alignof(PtrSet) : alignof(PtrTy);
354
+
350
355
} // end swift namespace
351
356
352
357
#endif // SWIFT_BASIC_IMMUTABLEPOINTERSET_H
You can’t perform that action at this time.
0 commit comments