Skip to content

Commit f1519bb

Browse files
committed
Don't run test on linux - it does not apply
1 parent 38a731e commit f1519bb

File tree

2 files changed

+25
-19
lines changed

2 files changed

+25
-19
lines changed

test/IRGen/enum_resilience.swift

Lines changed: 0 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -22,10 +22,6 @@ import resilient_struct
2222
// ENUM_NOT_RES-NOT: @"$S14resilient_enum6MediumO6CanvasyA2CmFWC" =
2323

2424
// CHECK: %T15enum_resilience5ClassC = type <{ %swift.refcounted }>
25-
26-
// Because the enum is resilient we cannot pack the tag into the pointer inside of the resilient payload.
27-
// CHECK: %T15enum_resilience9ContainerC5Multi33_59077B69D65A4A3BEE0C93708067D5F0LLO.0 = type <{ [{{(8|4)}} x i8], [1 x i8] }>
28-
2925
// CHECK: %T15enum_resilience9ReferenceV = type <{ %T15enum_resilience5ClassC* }>
3026

3127
// Public fixed layout struct contains a public resilient struct,
@@ -330,18 +326,3 @@ private enum ProtGenEnumWithSize<T: Prot> {
330326

331327
// CHECK-LABEL: define linkonce_odr hidden %T15enum_resilience19ProtGenEnumWithSize33_59077B69D65A4A3BEE0C93708067D5F0LLO* @"$S15enum_resilience19ProtGenEnumWithSize33_59077B69D65A4A3BEE0C93708067D5F0LLOyxGAA0C0RzlWOh"(%T15enum_resilience19ProtGenEnumWithSize
332328
// CHECK: ret %T15enum_resilience19ProtGenEnumWithSize33_59077B69D65A4A3BEE0C93708067D5F0LLO* %0
333-
334-
335-
public class Container {
336-
private enum Multi {
337-
case none
338-
case some(Container)
339-
case data(ResilientRef)
340-
}
341-
private var e: Multi
342-
var i: Int
343-
init() {
344-
e = .none
345-
i = 0
346-
}
347-
}

test/IRGen/enum_resilience_objc.swift

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
// RUN: %empty-directory(%t)
2+
// RUN: %target-swift-frontend -emit-module -enable-resilience -emit-module-path=%t/resilient_struct.swiftmodule -module-name=resilient_struct %S/../Inputs/resilient_struct.swift
3+
// RUN: %target-swift-frontend -module-name enum_resilience -I %t -emit-ir -enable-resilience %s | %FileCheck %s -DINT=i%target-ptrsize
4+
// RUN: %target-swift-frontend -module-name enum_resilience -I %t -emit-ir -enable-resilience -O %s
5+
6+
// REQUIRES: objc_interop
7+
8+
// Because the enum is resilient we cannot pack the tag into the pointer inside of the resilient payload.
9+
// CHECK: %T15enum_resilience9ContainerC5Multi33_59077B69D65A4A3BEE0C93708067D5F0LLO.0 = type <{ [{{(8|4)}} x i8], [1 x i8] }>
10+
11+
import resilient_struct
12+
13+
public class Container {
14+
private enum Multi {
15+
case none
16+
case some(Container)
17+
case data(ResilientRef)
18+
}
19+
private var e: Multi
20+
var i: Int
21+
init() {
22+
e = .none
23+
i = 0
24+
}
25+
}

0 commit comments

Comments
 (0)