File tree Expand file tree Collapse file tree 2 files changed +18
-0
lines changed Expand file tree Collapse file tree 2 files changed +18
-0
lines changed Original file line number Diff line number Diff line change @@ -1636,6 +1636,9 @@ void IRGenModule::emitStructDecl(StructDecl *st) {
1636
1636
}
1637
1637
1638
1638
void IRGenModule::maybeEmitOpaqueTypeDecl (OpaqueTypeDecl *opaque) {
1639
+ if (opaque->getASTContext ().LangOpts .hasFeature (Feature::Embedded))
1640
+ return ;
1641
+
1639
1642
if (!opaque->isAvailableDuringLowering ())
1640
1643
return ;
1641
1644
Original file line number Diff line number Diff line change
1
+ // RUN: %target-swift-emit-ir %s -target %target-cpu-apple-macos14 -enable-experimental-feature Embedded | %FileCheck %s
2
+
3
+ // REQUIRES: swift_in_compiler
4
+ // REQUIRES: VENDOR=apple
5
+ // REQUIRES: OS=macosx
6
+
7
+ protocol Proto { }
8
+
9
+ struct MyStruct : Proto { }
10
+
11
+ func foo( ) -> some Proto {
12
+ MyStruct ( )
13
+ }
14
+
15
+ // CHECK: define {{.*}}@main(
You can’t perform that action at this time.
0 commit comments