1.2. Reconstruction of Swift Code#

1.2.1. Enums#

1public enum Foo<T: Bar, U, V, W> {
2    case bar
3    case baz(param: String)
4    case foobar(Int32)
5}
1public enum test.Foo<A, B, C, D> {
2    // Cases: 3, 1 empty
3    case baz(param: Swift.String)
4    case foobar // $s\x02_\x91\xff\xff
5    case bar
6}

1.3. Protocols#

1public protocol Bar: Foo, Equatable {
2    associatedtype Baz
3    associatedtype FooBar
4
5    var id: UInt64 { get set }
6}
 1public protocol test.Bar: A, B where B: Foo {
 2    associatedtype Baz
 3    associatedtype FooBar
 4    // 7 Requirements
 5    // static var BaseProtocol
 6    // static var BaseProtocol
 7    // static var AssociatedTypeAccessFunction
 8    // static var AssociatedTypeAccessFunction
 9    // var Getter
10    // var Setter
11    // var ModifyCoroutine
12}