File tree Expand file tree Collapse file tree 2 files changed +17
-0
lines changed Expand file tree Collapse file tree 2 files changed +17
-0
lines changed Original file line number Diff line number Diff line change @@ -109,6 +109,14 @@ PrintOptions PrintOptions::printTextualInterfaceFile() {
109
109
}
110
110
}
111
111
112
+ // Skip extensions that extend things we wouldn't print.
113
+ if (auto *ED = dyn_cast<ExtensionDecl>(D)) {
114
+ if (!shouldPrint (ED->getExtendedNominal (), options))
115
+ return false ;
116
+ // FIXME: We also need to check the generic signature for constraints
117
+ // that we can't reference.
118
+ }
119
+
112
120
// Skip typealiases that just redeclare generic parameters.
113
121
if (auto *alias = dyn_cast<TypeAliasDecl>(D)) {
114
122
if (alias->isImplicit ()) {
Original file line number Diff line number Diff line change @@ -102,3 +102,12 @@ extension PublicStruct {
102
102
// CHECK: public private(set) static var secretlySettable: Int{{$}}
103
103
public private( set) static var secretlySettable : Int = 0
104
104
} // CHECK: {{^[}]$}}
105
+
106
+ extension InternalStruct_BAD : PublicProto {
107
+ internal static var dummy : Int { return 0 }
108
+ }
109
+
110
+ // CHECK: extension UFIStruct : PublicProto {{[{]$}}
111
+ extension UFIStruct : PublicProto {
112
+ internal static var dummy : Int { return 0 }
113
+ } // CHECK-NEXT: {{^[}]$}}
You can’t perform that action at this time.
0 commit comments