Skip to content

Commit d34a60d

Browse files
committed
[CMake] Instantiate missing C++ templates
(cherry picked from commit 71f5b47)
1 parent f1869c0 commit d34a60d

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

lib/SILOptimizer/Utils/BasicBlockOptUtils.cpp

+9
Original file line numberDiff line numberDiff line change
@@ -367,3 +367,12 @@ StaticInitCloner::clone(SingleValueInstruction *initVal) {
367367
}
368368
return cast<SingleValueInstruction>(getMappedValue(initVal));
369369
}
370+
371+
// START: Workaround for C++ interop
372+
#include <tuple>
373+
template std::pair<SILInstruction *, SILInstruction *> std::make_pair<>(SILInstruction *&&, SILInstruction *&&);
374+
template std::pair<SILValue, SILInstruction *> std::make_pair<>(SILValue &&, SILInstruction *&&);
375+
template std::pair<SILType, SILType> std::make_pair<>(SILType &&, SILType &&);
376+
template llvm::DomTreeNodeBase<SILBasicBlock> *&std::get<0>(std::tuple<llvm::DomTreeNodeBase<SILBasicBlock> *, std::default_delete<llvm::DomTreeNodeBase<SILBasicBlock>>> &);
377+
template std::default_delete<llvm::DomTreeNodeBase<SILBasicBlock>> &std::get<1>(std::tuple<llvm::DomTreeNodeBase<SILBasicBlock> *, std::default_delete<llvm::DomTreeNodeBase<SILBasicBlock>>> &);
378+
// END: Workaround for C++ interop

0 commit comments

Comments
 (0)