File tree Expand file tree Collapse file tree 2 files changed +4
-4
lines changed
test/Interop/SwiftToCxx/class Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -70,7 +70,7 @@ void ClangClassTypePrinter::printClassTypeDecl(
70
70
os << " public:\n " ;
71
71
os << " static inline " ;
72
72
printer.printBaseName (typeDecl);
73
- os << " fromUnretained (void * _Nonnull ptr) noexcept { return " ;
73
+ os << " makeRetained (void * _Nonnull ptr) noexcept { return " ;
74
74
printer.printBaseName (typeDecl);
75
75
os << " (ptr); }\n " ;
76
76
os << " };\n " ;
@@ -85,7 +85,7 @@ void ClangClassTypePrinter::printClassTypeReturnScaffold(
85
85
type->getModuleContext (), moduleContext);
86
86
os << cxx_synthesis::getCxxImplNamespaceName () << " ::" ;
87
87
ClangValueTypePrinter::printCxxImplClassName (os, type);
88
- os << " ::fromUnretained (" ;
88
+ os << " ::makeRetained (" ;
89
89
bodyPrinter ();
90
90
os << " );\n " ;
91
91
}
Original file line number Diff line number Diff line change @@ -43,7 +43,7 @@ public final class ClassWithIntField {
43
43
// CHECK-EMPTY:
44
44
// CHECK-NEXT:class _impl_ClassWithIntField {
45
45
// CHECK-NEXT:public:
46
- // CHECK-NEXT:static inline ClassWithIntField fromUnretained (void * _Nonnull ptr) noexcept { return ClassWithIntField(ptr); }
46
+ // CHECK-NEXT:static inline ClassWithIntField makeRetained (void * _Nonnull ptr) noexcept { return ClassWithIntField(ptr); }
47
47
// CHECK-NEXT:};
48
48
// CHECK-EMPTY:
49
49
// CHECK-NEXT:} // namespace _impl
@@ -57,5 +57,5 @@ public func returnClassWithIntField() -> ClassWithIntField {
57
57
}
58
58
59
59
// CHECK: inline ClassWithIntField returnClassWithIntField() noexcept SWIFT_WARN_UNUSED_RESULT {
60
- // CHECK-NEXT: return _impl::_impl_ClassWithIntField::fromUnretained (_impl::$s5Class06returnA12WithIntFieldAA0acdE0CyF());
60
+ // CHECK-NEXT: return _impl::_impl_ClassWithIntField::makeRetained (_impl::$s5Class06returnA12WithIntFieldAA0acdE0CyF());
61
61
// CHECK-NEXT: }
You can’t perform that action at this time.
0 commit comments