mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
Previously, Clang modules didn't have empty lines between top-level decls. This was inconsistent with Swift module.
493 lines
11 KiB
Plaintext
493 lines
11 KiB
Plaintext
import FooHelper
|
|
|
|
public func fooSubFunc1(_ a: Int32) -> Int32
|
|
|
|
public struct FooSubEnum1 : Equatable, RawRepresentable {
|
|
|
|
public init(_ rawValue: UInt32)
|
|
|
|
public init(rawValue: UInt32)
|
|
|
|
public var rawValue: UInt32
|
|
}
|
|
|
|
public var FooSubEnum1X: FooSubEnum1 { get }
|
|
|
|
public var FooSubEnum1Y: FooSubEnum1 { get }
|
|
|
|
public var FooSubUnnamedEnumeratorA1: Int { get }
|
|
|
|
|
|
[
|
|
{
|
|
key.kind: source.lang.swift.syntaxtype.keyword,
|
|
key.offset: 0,
|
|
key.length: 6
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.syntaxtype.identifier,
|
|
key.offset: 7,
|
|
key.length: 9
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.syntaxtype.attribute.builtin,
|
|
key.offset: 18,
|
|
key.length: 6
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.syntaxtype.keyword,
|
|
key.offset: 25,
|
|
key.length: 4
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.syntaxtype.identifier,
|
|
key.offset: 30,
|
|
key.length: 11
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.syntaxtype.keyword,
|
|
key.offset: 42,
|
|
key.length: 1
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.syntaxtype.identifier,
|
|
key.offset: 44,
|
|
key.length: 1
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.syntaxtype.typeidentifier,
|
|
key.offset: 47,
|
|
key.length: 5
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.syntaxtype.typeidentifier,
|
|
key.offset: 57,
|
|
key.length: 5
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.syntaxtype.attribute.builtin,
|
|
key.offset: 64,
|
|
key.length: 6
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.syntaxtype.keyword,
|
|
key.offset: 71,
|
|
key.length: 6
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.syntaxtype.identifier,
|
|
key.offset: 78,
|
|
key.length: 11
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.syntaxtype.typeidentifier,
|
|
key.offset: 92,
|
|
key.length: 9
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.syntaxtype.typeidentifier,
|
|
key.offset: 103,
|
|
key.length: 16
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.syntaxtype.attribute.builtin,
|
|
key.offset: 127,
|
|
key.length: 6
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.syntaxtype.keyword,
|
|
key.offset: 134,
|
|
key.length: 4
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.syntaxtype.keyword,
|
|
key.offset: 139,
|
|
key.length: 1
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.syntaxtype.identifier,
|
|
key.offset: 141,
|
|
key.length: 8
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.syntaxtype.typeidentifier,
|
|
key.offset: 151,
|
|
key.length: 6
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.syntaxtype.attribute.builtin,
|
|
key.offset: 164,
|
|
key.length: 6
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.syntaxtype.keyword,
|
|
key.offset: 171,
|
|
key.length: 4
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.syntaxtype.identifier,
|
|
key.offset: 176,
|
|
key.length: 8
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.syntaxtype.typeidentifier,
|
|
key.offset: 186,
|
|
key.length: 6
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.syntaxtype.attribute.builtin,
|
|
key.offset: 199,
|
|
key.length: 6
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.syntaxtype.keyword,
|
|
key.offset: 206,
|
|
key.length: 3
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.syntaxtype.identifier,
|
|
key.offset: 210,
|
|
key.length: 8
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.syntaxtype.typeidentifier,
|
|
key.offset: 220,
|
|
key.length: 6
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.syntaxtype.attribute.builtin,
|
|
key.offset: 230,
|
|
key.length: 6
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.syntaxtype.keyword,
|
|
key.offset: 237,
|
|
key.length: 3
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.syntaxtype.identifier,
|
|
key.offset: 241,
|
|
key.length: 12
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.syntaxtype.typeidentifier,
|
|
key.offset: 255,
|
|
key.length: 11
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.syntaxtype.keyword,
|
|
key.offset: 269,
|
|
key.length: 3
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.syntaxtype.attribute.builtin,
|
|
key.offset: 276,
|
|
key.length: 6
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.syntaxtype.keyword,
|
|
key.offset: 283,
|
|
key.length: 3
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.syntaxtype.identifier,
|
|
key.offset: 287,
|
|
key.length: 12
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.syntaxtype.typeidentifier,
|
|
key.offset: 301,
|
|
key.length: 11
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.syntaxtype.keyword,
|
|
key.offset: 315,
|
|
key.length: 3
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.syntaxtype.attribute.builtin,
|
|
key.offset: 322,
|
|
key.length: 6
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.syntaxtype.keyword,
|
|
key.offset: 329,
|
|
key.length: 3
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.syntaxtype.identifier,
|
|
key.offset: 333,
|
|
key.length: 25
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.syntaxtype.typeidentifier,
|
|
key.offset: 360,
|
|
key.length: 3
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.syntaxtype.keyword,
|
|
key.offset: 366,
|
|
key.length: 3
|
|
}
|
|
]
|
|
[
|
|
{
|
|
key.kind: source.lang.swift.ref.module,
|
|
key.offset: 7,
|
|
key.length: 9
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.ref.struct,
|
|
key.offset: 47,
|
|
key.length: 5,
|
|
key.is_system: 1
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.ref.struct,
|
|
key.offset: 57,
|
|
key.length: 5,
|
|
key.is_system: 1
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.ref.protocol,
|
|
key.offset: 92,
|
|
key.length: 9,
|
|
key.is_system: 1
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.ref.protocol,
|
|
key.offset: 103,
|
|
key.length: 16,
|
|
key.is_system: 1
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.ref.struct,
|
|
key.offset: 151,
|
|
key.length: 6,
|
|
key.is_system: 1
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.ref.struct,
|
|
key.offset: 186,
|
|
key.length: 6,
|
|
key.is_system: 1
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.ref.struct,
|
|
key.offset: 220,
|
|
key.length: 6,
|
|
key.is_system: 1
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.ref.struct,
|
|
key.offset: 255,
|
|
key.length: 11
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.ref.struct,
|
|
key.offset: 301,
|
|
key.length: 11
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.ref.struct,
|
|
key.offset: 360,
|
|
key.length: 3,
|
|
key.is_system: 1
|
|
}
|
|
]
|
|
[
|
|
{
|
|
key.kind: source.lang.swift.decl.function.free,
|
|
key.accessibility: source.lang.swift.accessibility.public,
|
|
key.name: "fooSubFunc1(_:)",
|
|
key.offset: 25,
|
|
key.length: 37,
|
|
key.typename: "Int32",
|
|
key.nameoffset: 30,
|
|
key.namelength: 23,
|
|
key.attributes: [
|
|
{
|
|
key.offset: 18,
|
|
key.length: 6,
|
|
key.attribute: source.decl.attribute.public
|
|
}
|
|
],
|
|
key.substructure: [
|
|
{
|
|
key.kind: source.lang.swift.decl.var.parameter,
|
|
key.name: "a",
|
|
key.offset: 42,
|
|
key.length: 10,
|
|
key.typename: "Int32"
|
|
}
|
|
]
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.decl.struct,
|
|
key.accessibility: source.lang.swift.accessibility.public,
|
|
key.name: "FooSubEnum1",
|
|
key.offset: 71,
|
|
key.length: 157,
|
|
key.nameoffset: 78,
|
|
key.namelength: 11,
|
|
key.bodyoffset: 121,
|
|
key.bodylength: 106,
|
|
key.inheritedtypes: [
|
|
{
|
|
key.name: "Equatable"
|
|
},
|
|
{
|
|
key.name: "RawRepresentable"
|
|
}
|
|
],
|
|
key.attributes: [
|
|
{
|
|
key.offset: 64,
|
|
key.length: 6,
|
|
key.attribute: source.decl.attribute.public
|
|
}
|
|
],
|
|
key.elements: [
|
|
{
|
|
key.kind: source.lang.swift.structure.elem.typeref,
|
|
key.offset: 92,
|
|
key.length: 9
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.structure.elem.typeref,
|
|
key.offset: 103,
|
|
key.length: 16
|
|
}
|
|
],
|
|
key.substructure: [
|
|
{
|
|
key.kind: source.lang.swift.decl.function.method.instance,
|
|
key.accessibility: source.lang.swift.accessibility.public,
|
|
key.name: "init(_:)",
|
|
key.offset: 134,
|
|
key.length: 24,
|
|
key.nameoffset: 134,
|
|
key.namelength: 24,
|
|
key.attributes: [
|
|
{
|
|
key.offset: 127,
|
|
key.length: 6,
|
|
key.attribute: source.decl.attribute.public
|
|
}
|
|
],
|
|
key.substructure: [
|
|
{
|
|
key.kind: source.lang.swift.decl.var.parameter,
|
|
key.name: "rawValue",
|
|
key.offset: 139,
|
|
key.length: 18,
|
|
key.typename: "UInt32"
|
|
}
|
|
]
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.decl.function.method.instance,
|
|
key.accessibility: source.lang.swift.accessibility.public,
|
|
key.name: "init(rawValue:)",
|
|
key.offset: 171,
|
|
key.length: 22,
|
|
key.nameoffset: 171,
|
|
key.namelength: 22,
|
|
key.attributes: [
|
|
{
|
|
key.offset: 164,
|
|
key.length: 6,
|
|
key.attribute: source.decl.attribute.public
|
|
}
|
|
],
|
|
key.substructure: [
|
|
{
|
|
key.kind: source.lang.swift.decl.var.parameter,
|
|
key.name: "rawValue",
|
|
key.offset: 176,
|
|
key.length: 16,
|
|
key.typename: "UInt32",
|
|
key.nameoffset: 176,
|
|
key.namelength: 8
|
|
}
|
|
]
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.decl.var.instance,
|
|
key.accessibility: source.lang.swift.accessibility.public,
|
|
key.setter_accessibility: source.lang.swift.accessibility.public,
|
|
key.name: "rawValue",
|
|
key.offset: 206,
|
|
key.length: 20,
|
|
key.typename: "UInt32",
|
|
key.nameoffset: 210,
|
|
key.namelength: 8,
|
|
key.attributes: [
|
|
{
|
|
key.offset: 199,
|
|
key.length: 6,
|
|
key.attribute: source.decl.attribute.public
|
|
}
|
|
]
|
|
}
|
|
]
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.decl.var.global,
|
|
key.accessibility: source.lang.swift.accessibility.public,
|
|
key.name: "FooSubEnum1X",
|
|
key.offset: 237,
|
|
key.length: 37,
|
|
key.typename: "FooSubEnum1",
|
|
key.nameoffset: 241,
|
|
key.namelength: 12,
|
|
key.bodyoffset: 268,
|
|
key.bodylength: 5,
|
|
key.attributes: [
|
|
{
|
|
key.offset: 230,
|
|
key.length: 6,
|
|
key.attribute: source.decl.attribute.public
|
|
}
|
|
]
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.decl.var.global,
|
|
key.accessibility: source.lang.swift.accessibility.public,
|
|
key.name: "FooSubEnum1Y",
|
|
key.offset: 283,
|
|
key.length: 37,
|
|
key.typename: "FooSubEnum1",
|
|
key.nameoffset: 287,
|
|
key.namelength: 12,
|
|
key.bodyoffset: 314,
|
|
key.bodylength: 5,
|
|
key.attributes: [
|
|
{
|
|
key.offset: 276,
|
|
key.length: 6,
|
|
key.attribute: source.decl.attribute.public
|
|
}
|
|
]
|
|
},
|
|
{
|
|
key.kind: source.lang.swift.decl.var.global,
|
|
key.accessibility: source.lang.swift.accessibility.public,
|
|
key.name: "FooSubUnnamedEnumeratorA1",
|
|
key.offset: 329,
|
|
key.length: 42,
|
|
key.typename: "Int",
|
|
key.nameoffset: 333,
|
|
key.namelength: 25,
|
|
key.bodyoffset: 365,
|
|
key.bodylength: 5,
|
|
key.attributes: [
|
|
{
|
|
key.offset: 322,
|
|
key.length: 6,
|
|
key.attribute: source.decl.attribute.public
|
|
}
|
|
]
|
|
}
|
|
]
|