File tree Expand file tree Collapse file tree 2 files changed +24
-0
lines changed
lib/AST/RequirementMachine Expand file tree Collapse file tree 2 files changed +24
-0
lines changed Original file line number Diff line number Diff line change @@ -277,6 +277,18 @@ namespace llvm {
277277 return LHS == RHS;
278278 }
279279 };
280+
281+ template <>
282+ struct PointerLikeTypeTraits <swift::rewriting::Symbol> {
283+ public:
284+ static inline void *getAsVoidPointer (swift::rewriting::Symbol Val) {
285+ return const_cast <void *>(Val.getOpaquePointer ());
286+ }
287+ static inline swift::rewriting::Symbol getFromVoidPointer (void *Ptr) {
288+ return swift::rewriting::Symbol::fromOpaquePointer (Ptr);
289+ }
290+ enum { NumLowBitsAvailable = 1 };
291+ };
280292} // end namespace llvm
281293
282294#endif
Original file line number Diff line number Diff line change @@ -229,6 +229,18 @@ namespace llvm {
229229 return LHS == RHS;
230230 }
231231 };
232+
233+ template <>
234+ struct PointerLikeTypeTraits <swift::rewriting::Term> {
235+ public:
236+ static inline void *getAsVoidPointer (swift::rewriting::Term Val) {
237+ return const_cast <void *>(Val.getOpaquePointer ());
238+ }
239+ static inline swift::rewriting::Term getFromVoidPointer (void *Ptr) {
240+ return swift::rewriting::Term::fromOpaquePointer (Ptr);
241+ }
242+ enum { NumLowBitsAvailable = 1 };
243+ };
232244} // end namespace llvm
233245
234246#endif
You can’t perform that action at this time.
0 commit comments