From c6c185677dc6cd0aed1f671db8ee3da73c4d1f09 Mon Sep 17 00:00:00 2001 From: Anthony Latsis Date: Thu, 11 Sep 2025 16:36:43 +0100 Subject: [PATCH] [test] Adjust `api-digester/dump-module.swift` for rebranch again I missed that https://github.com/swiftlang/swift/pull/84193 would break the test on x86. This makes the expected output is arch-dependent. --- .../cake-abi-arm64.json} | 0 .../Outputs/dump-module/cake-abi-x86_64.json | 2360 +++++++++++++++++ .../cake-arm64.json} | 0 .../Outputs/dump-module/cake-x86_64.json | 2247 ++++++++++++++++ test/api-digester/dump-module.swift | 23 +- 5 files changed, 4623 insertions(+), 7 deletions(-) rename test/api-digester/Outputs/{cake-abi.json => dump-module/cake-abi-arm64.json} (100%) create mode 100644 test/api-digester/Outputs/dump-module/cake-abi-x86_64.json rename test/api-digester/Outputs/{cake.json => dump-module/cake-arm64.json} (100%) create mode 100644 test/api-digester/Outputs/dump-module/cake-x86_64.json diff --git a/test/api-digester/Outputs/cake-abi.json b/test/api-digester/Outputs/dump-module/cake-abi-arm64.json similarity index 100% rename from test/api-digester/Outputs/cake-abi.json rename to test/api-digester/Outputs/dump-module/cake-abi-arm64.json diff --git a/test/api-digester/Outputs/dump-module/cake-abi-x86_64.json b/test/api-digester/Outputs/dump-module/cake-abi-x86_64.json new file mode 100644 index 0000000000000..a1697144c7a31 --- /dev/null +++ b/test/api-digester/Outputs/dump-module/cake-abi-x86_64.json @@ -0,0 +1,2360 @@ +{ + "ABIRoot": { + "kind": "Root", + "name": "cake", + "printedName": "cake", + "children": [ + { + "kind": "Import", + "name": "SwiftOnoneSupport", + "printedName": "SwiftOnoneSupport", + "declKind": "Import", + "moduleName": "cake" + }, + { + "kind": "Import", + "name": "_Concurrency", + "printedName": "_Concurrency", + "declKind": "Import", + "moduleName": "cake" + }, + { + "kind": "Import", + "name": "_StringProcessing", + "printedName": "_StringProcessing", + "declKind": "Import", + "moduleName": "cake" + }, + { + "kind": "Import", + "name": "_SwiftConcurrencyShims", + "printedName": "_SwiftConcurrencyShims", + "declKind": "Import", + "moduleName": "cake" + }, + { + "kind": "Import", + "name": "cake", + "printedName": "cake", + "declKind": "Import", + "moduleName": "cake", + "declAttributes": [ + "Exported" + ] + }, + { + "kind": "TypeDecl", + "name": "P1", + "printedName": "P1", + "children": [ + { + "kind": "Function", + "name": "+", + "printedName": "+(_:_:)", + "children": [ + { + "kind": "TypeNominal", + "name": "GenericTypeParam", + "printedName": "τ_0_0" + }, + { + "kind": "TypeNominal", + "name": "GenericTypeParam", + "printedName": "τ_0_0" + }, + { + "kind": "TypeNominal", + "name": "GenericTypeParam", + "printedName": "τ_0_0" + } + ], + "declKind": "Func", + "usr": "s:4cake2P1PAAE1poiyxx_xtFZ", + "mangledName": "$s4cake2P1PAAE1poiyxx_xtFZ", + "moduleName": "cake", + "genericSig": "<τ_0_0 where τ_0_0 : cake.P1>", + "sugared_genericSig": "", + "static": true, + "isFromExtension": true, + "funcSelfKind": "NonMutating" + } + ], + "declKind": "Protocol", + "usr": "s:4cake2P1P", + "mangledName": "$s4cake2P1P", + "moduleName": "cake", + "conformances": [ + { + "kind": "Conformance", + "name": "Escapable", + "printedName": "Escapable", + "usr": "s:s9EscapableP", + "mangledName": "$ss9EscapableP" + }, + { + "kind": "Conformance", + "name": "Copyable", + "printedName": "Copyable", + "usr": "s:s8CopyableP", + "mangledName": "$ss8CopyableP" + } + ] + }, + { + "kind": "TypeDecl", + "name": "P2", + "printedName": "P2", + "declKind": "Protocol", + "usr": "s:4cake2P2P", + "mangledName": "$s4cake2P2P", + "moduleName": "cake", + "conformances": [ + { + "kind": "Conformance", + "name": "Escapable", + "printedName": "Escapable", + "usr": "s:s9EscapableP", + "mangledName": "$ss9EscapableP" + }, + { + "kind": "Conformance", + "name": "Copyable", + "printedName": "Copyable", + "usr": "s:s8CopyableP", + "mangledName": "$ss8CopyableP" + } + ] + }, + { + "kind": "TypeDecl", + "name": "P3", + "printedName": "P3", + "declKind": "Protocol", + "usr": "s:4cake2P3P", + "mangledName": "$s4cake2P3P", + "moduleName": "cake", + "genericSig": "<τ_0_0 : cake.P1, τ_0_0 : cake.P2>", + "sugared_genericSig": "", + "conformances": [ + { + "kind": "Conformance", + "name": "Escapable", + "printedName": "Escapable", + "usr": "s:s9EscapableP", + "mangledName": "$ss9EscapableP" + }, + { + "kind": "Conformance", + "name": "Copyable", + "printedName": "Copyable", + "usr": "s:s8CopyableP", + "mangledName": "$ss8CopyableP" + }, + { + "kind": "Conformance", + "name": "P1", + "printedName": "P1", + "usr": "s:4cake2P1P", + "mangledName": "$s4cake2P1P" + }, + { + "kind": "Conformance", + "name": "P2", + "printedName": "P2", + "usr": "s:4cake2P2P", + "mangledName": "$s4cake2P2P" + } + ] + }, + { + "kind": "TypeDecl", + "name": "S1", + "printedName": "S1", + "children": [ + { + "kind": "Function", + "name": "foo1", + "printedName": "foo1()", + "children": [ + { + "kind": "TypeNominal", + "name": "Void", + "printedName": "()" + } + ], + "declKind": "Func", + "usr": "s:4cake2S1V4foo1yyFZ", + "mangledName": "$s4cake2S1V4foo1yyFZ", + "moduleName": "cake", + "static": true, + "funcSelfKind": "NonMutating" + }, + { + "kind": "Function", + "name": "foo2", + "printedName": "foo2()", + "children": [ + { + "kind": "TypeNominal", + "name": "Void", + "printedName": "()" + } + ], + "declKind": "Func", + "usr": "s:4cake2S1V4foo2yyF", + "mangledName": "$s4cake2S1V4foo2yyF", + "moduleName": "cake", + "funcSelfKind": "Mutating" + }, + { + "kind": "Function", + "name": "foo6", + "printedName": "foo6()", + "children": [ + { + "kind": "TypeNominal", + "name": "Void", + "printedName": "()" + } + ], + "declKind": "Func", + "usr": "s:4cake2S1V4foo6yyF", + "mangledName": "$s4cake2S1V4foo6yyF", + "moduleName": "cake", + "funcSelfKind": "NonMutating" + } + ], + "declKind": "Struct", + "usr": "s:4cake2S1V", + "mangledName": "$s4cake2S1V", + "moduleName": "cake", + "declAttributes": [ + "Frozen" + ], + "conformances": [ + { + "kind": "Conformance", + "name": "P1", + "printedName": "P1", + "usr": "s:4cake2P1P", + "mangledName": "$s4cake2P1P" + }, + { + "kind": "Conformance", + "name": "Sendable", + "printedName": "Sendable", + "usr": "s:s8SendableP", + "mangledName": "$ss8SendableP" + }, + { + "kind": "Conformance", + "name": "BitwiseCopyable", + "printedName": "BitwiseCopyable", + "usr": "s:s15BitwiseCopyableP", + "mangledName": "$ss15BitwiseCopyableP" + }, + { + "kind": "Conformance", + "name": "Copyable", + "printedName": "Copyable", + "usr": "s:s8CopyableP", + "mangledName": "$ss8CopyableP" + }, + { + "kind": "Conformance", + "name": "Escapable", + "printedName": "Escapable", + "usr": "s:s9EscapableP", + "mangledName": "$ss9EscapableP" + }, + { + "kind": "Conformance", + "name": "SendableMetatype", + "printedName": "SendableMetatype", + "usr": "s:s16SendableMetatypeP", + "mangledName": "$ss16SendableMetatypeP" + }, + { + "kind": "Conformance", + "name": "P2", + "printedName": "P2", + "usr": "s:4cake2P2P", + "mangledName": "$s4cake2P2P" + } + ] + }, + { + "kind": "TypeDecl", + "name": "C0", + "printedName": "C0", + "children": [ + { + "kind": "Function", + "name": "conditionalFooExt", + "printedName": "conditionalFooExt()", + "children": [ + { + "kind": "TypeNominal", + "name": "Void", + "printedName": "()" + } + ], + "declKind": "Func", + "usr": "s:4cake2C0CA2A2S1VRszAERs_AERs0_rlE17conditionalFooExtyyF", + "mangledName": "$s4cake2C0CA2A2S1VRszAERs_AERs0_rlE17conditionalFooExtyyF", + "moduleName": "cake", + "genericSig": "<τ_0_0, τ_0_1, τ_0_2 where τ_0_0 == cake.S1, τ_0_1 == cake.S1, τ_0_2 == cake.S1>", + "sugared_genericSig": "", + "isFromExtension": true, + "funcSelfKind": "NonMutating" + }, + { + "kind": "Function", + "name": "unconditionalFooExt", + "printedName": "unconditionalFooExt()", + "children": [ + { + "kind": "TypeNominal", + "name": "Void", + "printedName": "()" + } + ], + "declKind": "Func", + "usr": "s:4cake2C0C19unconditionalFooExtyyF", + "mangledName": "$s4cake2C0C19unconditionalFooExtyyF", + "moduleName": "cake", + "genericSig": "<τ_0_0, τ_0_1, τ_0_2>", + "sugared_genericSig": "", + "isFromExtension": true, + "funcSelfKind": "NonMutating" + } + ], + "declKind": "Class", + "usr": "s:4cake2C0C", + "mangledName": "$s4cake2C0C", + "moduleName": "cake", + "genericSig": "<τ_0_0, τ_0_1, τ_0_2>", + "sugared_genericSig": "", + "hasMissingDesignatedInitializers": true, + "conformances": [ + { + "kind": "Conformance", + "name": "Copyable", + "printedName": "Copyable", + "usr": "s:s8CopyableP", + "mangledName": "$ss8CopyableP" + }, + { + "kind": "Conformance", + "name": "Escapable", + "printedName": "Escapable", + "usr": "s:s9EscapableP", + "mangledName": "$ss9EscapableP" + } + ] + }, + { + "kind": "TypeDecl", + "name": "C1", + "printedName": "C1", + "children": [ + { + "kind": "Function", + "name": "foo1", + "printedName": "foo1()", + "children": [ + { + "kind": "TypeNominal", + "name": "Void", + "printedName": "()" + } + ], + "declKind": "Func", + "usr": "s:4cake2C1C4foo1yyFZ", + "mangledName": "$s4cake2C1C4foo1yyFZ", + "moduleName": "cake", + "static": true, + "funcSelfKind": "NonMutating" + }, + { + "kind": "Var", + "name": "Ins", + "printedName": "Ins", + "children": [ + { + "kind": "TypeNominal", + "name": "WeakStorage", + "printedName": "cake.C1?" + } + ], + "declKind": "Var", + "usr": "s:4cake2C1C3InsACSgvp", + "mangledName": "$s4cake2C1C3InsACSgvp", + "moduleName": "cake", + "declAttributes": [ + "HasInitialValue", + "ReferenceOwnership", + "HasStorage" + ], + "fixedbinaryorder": 0, + "ownership": 1, + "hasStorage": true, + "accessors": [ + { + "kind": "Accessor", + "name": "Get", + "printedName": "Get()", + "children": [ + { + "kind": "TypeNominal", + "name": "Optional", + "printedName": "cake.C1?", + "children": [ + { + "kind": "TypeNominal", + "name": "C1", + "printedName": "cake.C1", + "usr": "s:4cake2C1C" + } + ], + "usr": "s:Sq" + } + ], + "declKind": "Accessor", + "usr": "s:4cake2C1C3InsACSgvg", + "mangledName": "$s4cake2C1C3InsACSgvg", + "moduleName": "cake", + "implicit": true, + "declAttributes": [ + "Transparent" + ], + "accessorKind": "get" + }, + { + "kind": "Accessor", + "name": "Set", + "printedName": "Set()", + "children": [ + { + "kind": "TypeNominal", + "name": "Void", + "printedName": "()" + }, + { + "kind": "TypeNominal", + "name": "Optional", + "printedName": "cake.C1?", + "children": [ + { + "kind": "TypeNominal", + "name": "C1", + "printedName": "cake.C1", + "usr": "s:4cake2C1C" + } + ], + "usr": "s:Sq" + } + ], + "declKind": "Accessor", + "usr": "s:4cake2C1C3InsACSgvs", + "mangledName": "$s4cake2C1C3InsACSgvs", + "moduleName": "cake", + "implicit": true, + "declAttributes": [ + "Transparent" + ], + "accessorKind": "set" + }, + { + "kind": "Accessor", + "name": "Modify", + "printedName": "Modify()", + "children": [ + { + "kind": "TypeNominal", + "name": "Void", + "printedName": "()" + } + ], + "declKind": "Accessor", + "usr": "s:4cake2C1C3InsACSgvM", + "mangledName": "$s4cake2C1C3InsACSgvM", + "moduleName": "cake", + "implicit": true, + "declAttributes": [ + "Transparent" + ], + "accessorKind": "_modify" + } + ] + }, + { + "kind": "Var", + "name": "Ins2", + "printedName": "Ins2", + "children": [ + { + "kind": "TypeNominal", + "name": "UnownedStorage", + "printedName": "cake.C1" + } + ], + "declKind": "Var", + "usr": "s:4cake2C1C4Ins2ACvp", + "mangledName": "$s4cake2C1C4Ins2ACvp", + "moduleName": "cake", + "declAttributes": [ + "HasInitialValue", + "ReferenceOwnership", + "HasStorage" + ], + "fixedbinaryorder": 1, + "ownership": 2, + "hasStorage": true, + "accessors": [ + { + "kind": "Accessor", + "name": "Get", + "printedName": "Get()", + "children": [ + { + "kind": "TypeNominal", + "name": "C1", + "printedName": "cake.C1", + "usr": "s:4cake2C1C" + } + ], + "declKind": "Accessor", + "usr": "s:4cake2C1C4Ins2ACvg", + "mangledName": "$s4cake2C1C4Ins2ACvg", + "moduleName": "cake", + "implicit": true, + "declAttributes": [ + "Transparent" + ], + "accessorKind": "get" + }, + { + "kind": "Accessor", + "name": "Set", + "printedName": "Set()", + "children": [ + { + "kind": "TypeNominal", + "name": "Void", + "printedName": "()" + }, + { + "kind": "TypeNominal", + "name": "C1", + "printedName": "cake.C1", + "usr": "s:4cake2C1C" + } + ], + "declKind": "Accessor", + "usr": "s:4cake2C1C4Ins2ACvs", + "mangledName": "$s4cake2C1C4Ins2ACvs", + "moduleName": "cake", + "implicit": true, + "declAttributes": [ + "Transparent" + ], + "accessorKind": "set" + }, + { + "kind": "Accessor", + "name": "Modify", + "printedName": "Modify()", + "children": [ + { + "kind": "TypeNominal", + "name": "Void", + "printedName": "()" + } + ], + "declKind": "Accessor", + "usr": "s:4cake2C1C4Ins2ACvM", + "mangledName": "$s4cake2C1C4Ins2ACvM", + "moduleName": "cake", + "implicit": true, + "declAttributes": [ + "Transparent" + ], + "accessorKind": "_modify" + } + ] + } + ], + "declKind": "Class", + "usr": "s:4cake2C1C", + "mangledName": "$s4cake2C1C", + "moduleName": "cake", + "superclassUsr": "s:4cake2C0C", + "hasMissingDesignatedInitializers": true, + "inheritsConvenienceInitializers": true, + "superclassNames": [ + "cake.C0" + ], + "conformances": [ + { + "kind": "Conformance", + "name": "Copyable", + "printedName": "Copyable", + "usr": "s:s8CopyableP", + "mangledName": "$ss8CopyableP" + }, + { + "kind": "Conformance", + "name": "Escapable", + "printedName": "Escapable", + "usr": "s:s9EscapableP", + "mangledName": "$ss9EscapableP" + } + ] + }, + { + "kind": "Function", + "name": "foo1", + "printedName": "foo1(_:b:)", + "children": [ + { + "kind": "TypeNominal", + "name": "Void", + "printedName": "()" + }, + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "hasDefaultArg": true, + "usr": "s:Si" + }, + { + "kind": "TypeNominal", + "name": "S1", + "printedName": "cake.S1", + "usr": "s:4cake2S1V" + } + ], + "declKind": "Func", + "usr": "s:4cake4foo1_1bySi_AA2S1VtF", + "mangledName": "$s4cake4foo1_1bySi_AA2S1VtF", + "moduleName": "cake", + "funcSelfKind": "NonMutating" + }, + { + "kind": "Function", + "name": "foo2", + "printedName": "foo2(_:b:)", + "children": [ + { + "kind": "TypeNominal", + "name": "Void", + "printedName": "()" + }, + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "hasDefaultArg": true, + "usr": "s:Si" + }, + { + "kind": "TypeNominal", + "name": "S1", + "printedName": "cake.S1", + "usr": "s:4cake2S1V" + } + ], + "declKind": "Func", + "usr": "s:4cake4foo2_1bySi_AA2S1VtF", + "mangledName": "$s4cake4foo2_1bySi_AA2S1VtF", + "moduleName": "cake", + "funcSelfKind": "NonMutating" + }, + { + "kind": "TypeDecl", + "name": "Number", + "printedName": "Number", + "children": [ + { + "kind": "Var", + "name": "one", + "printedName": "one", + "children": [ + { + "kind": "TypeFunc", + "name": "Function", + "printedName": "(cake.Number.Type) -> cake.Number", + "children": [ + { + "kind": "TypeNominal", + "name": "Number", + "printedName": "cake.Number", + "usr": "s:4cake6NumberO" + }, + { + "kind": "TypeNominal", + "name": "Metatype", + "printedName": "cake.Number.Type", + "children": [ + { + "kind": "TypeNominal", + "name": "Number", + "printedName": "cake.Number", + "usr": "s:4cake6NumberO" + } + ] + } + ] + } + ], + "declKind": "EnumElement", + "usr": "s:4cake6NumberO3oneyA2CmF", + "mangledName": "$s4cake6NumberO3oneyA2CmF", + "moduleName": "cake", + "fixedbinaryorder": 0 + }, + { + "kind": "Constructor", + "name": "init", + "printedName": "init(rawValue:)", + "children": [ + { + "kind": "TypeNominal", + "name": "Optional", + "printedName": "cake.Number?", + "children": [ + { + "kind": "TypeNominal", + "name": "Number", + "printedName": "cake.Number", + "usr": "s:4cake6NumberO" + } + ], + "usr": "s:Sq" + }, + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + } + ], + "declKind": "Constructor", + "usr": "s:4cake6NumberO8rawValueACSgSi_tcfc", + "mangledName": "$s4cake6NumberO8rawValueACSgSi_tcfc", + "moduleName": "cake", + "implicit": true, + "declAttributes": [ + "Inlinable" + ], + "init_kind": "Designated" + }, + { + "kind": "Var", + "name": "rawValue", + "printedName": "rawValue", + "children": [ + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + } + ], + "declKind": "Var", + "usr": "s:4cake6NumberO8rawValueSivp", + "mangledName": "$s4cake6NumberO8rawValueSivp", + "moduleName": "cake", + "implicit": true, + "accessors": [ + { + "kind": "Accessor", + "name": "Get", + "printedName": "Get()", + "children": [ + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + } + ], + "declKind": "Accessor", + "usr": "s:4cake6NumberO8rawValueSivg", + "mangledName": "$s4cake6NumberO8rawValueSivg", + "moduleName": "cake", + "implicit": true, + "declAttributes": [ + "Inlinable" + ], + "accessorKind": "get" + } + ] + } + ], + "declKind": "Enum", + "usr": "s:4cake6NumberO", + "mangledName": "$s4cake6NumberO", + "moduleName": "cake", + "enumRawTypeName": "Int", + "isEnumExhaustive": true, + "conformances": [ + { + "kind": "Conformance", + "name": "Equatable", + "printedName": "Equatable", + "usr": "s:SQ", + "mangledName": "$sSQ" + }, + { + "kind": "Conformance", + "name": "Hashable", + "printedName": "Hashable", + "usr": "s:SH", + "mangledName": "$sSH" + }, + { + "kind": "Conformance", + "name": "RawRepresentable", + "printedName": "RawRepresentable", + "children": [ + { + "kind": "TypeWitness", + "name": "RawValue", + "printedName": "RawValue", + "children": [ + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + } + ] + } + ], + "usr": "s:SY", + "mangledName": "$sSY" + }, + { + "kind": "Conformance", + "name": "Copyable", + "printedName": "Copyable", + "usr": "s:s8CopyableP", + "mangledName": "$ss8CopyableP" + }, + { + "kind": "Conformance", + "name": "Escapable", + "printedName": "Escapable", + "usr": "s:s9EscapableP", + "mangledName": "$ss9EscapableP" + } + ] + }, + { + "kind": "Function", + "name": "foo3", + "printedName": "foo3(_:)", + "children": [ + { + "kind": "TypeNominal", + "name": "Void", + "printedName": "()" + }, + { + "kind": "TypeNominal", + "name": "Dictionary", + "printedName": "[Swift.Int : Swift.String]", + "children": [ + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + }, + { + "kind": "TypeNominal", + "name": "String", + "printedName": "Swift.String", + "usr": "s:SS" + } + ], + "usr": "s:SD" + } + ], + "declKind": "Func", + "usr": "s:4cake4foo3yySDySiSSGF", + "mangledName": "$s4cake4foo3yySDySiSSGF", + "moduleName": "cake", + "funcSelfKind": "NonMutating" + }, + { + "kind": "TypeDecl", + "name": "fixedLayoutStruct", + "printedName": "fixedLayoutStruct", + "children": [ + { + "kind": "Var", + "name": "a", + "printedName": "a", + "children": [ + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + } + ], + "declKind": "Var", + "usr": "s:4cake17fixedLayoutStructV1aSivp", + "mangledName": "$s4cake17fixedLayoutStructV1aSivp", + "moduleName": "cake", + "declAttributes": [ + "HasInitialValue", + "HasStorage" + ], + "fixedbinaryorder": 0, + "hasStorage": true, + "accessors": [ + { + "kind": "Accessor", + "name": "Get", + "printedName": "Get()", + "children": [ + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + } + ], + "declKind": "Accessor", + "usr": "s:4cake17fixedLayoutStructV1aSivg", + "mangledName": "$s4cake17fixedLayoutStructV1aSivg", + "moduleName": "cake", + "implicit": true, + "declAttributes": [ + "Transparent" + ], + "accessorKind": "get" + }, + { + "kind": "Accessor", + "name": "Set", + "printedName": "Set()", + "children": [ + { + "kind": "TypeNominal", + "name": "Void", + "printedName": "()" + }, + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + } + ], + "declKind": "Accessor", + "usr": "s:4cake17fixedLayoutStructV1aSivs", + "mangledName": "$s4cake17fixedLayoutStructV1aSivs", + "moduleName": "cake", + "implicit": true, + "declAttributes": [ + "Transparent" + ], + "accessorKind": "set" + }, + { + "kind": "Accessor", + "name": "Modify", + "printedName": "Modify()", + "children": [ + { + "kind": "TypeNominal", + "name": "Void", + "printedName": "()" + } + ], + "declKind": "Accessor", + "usr": "s:4cake17fixedLayoutStructV1aSivM", + "mangledName": "$s4cake17fixedLayoutStructV1aSivM", + "moduleName": "cake", + "implicit": true, + "declAttributes": [ + "Transparent" + ], + "accessorKind": "_modify" + } + ] + }, + { + "kind": "Var", + "name": "b", + "printedName": "b", + "children": [ + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + } + ], + "declKind": "Var", + "usr": "s:4cake17fixedLayoutStructV1b33_3D8926C30F7417F2EF9A277D0C73FBDBLLSivp", + "mangledName": "$s4cake17fixedLayoutStructV1b33_3D8926C30F7417F2EF9A277D0C73FBDBLLSivp", + "moduleName": "cake", + "isInternal": true, + "declAttributes": [ + "HasInitialValue", + "HasStorage" + ], + "fixedbinaryorder": 1, + "hasStorage": true + }, + { + "kind": "Var", + "name": "c", + "printedName": "c", + "children": [ + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + } + ], + "declKind": "Var", + "usr": "s:4cake17fixedLayoutStructV1cSivp", + "mangledName": "$s4cake17fixedLayoutStructV1cSivp", + "moduleName": "cake", + "isInternal": true, + "declAttributes": [ + "HasInitialValue", + "HasStorage" + ], + "fixedbinaryorder": 2, + "hasStorage": true + } + ], + "declKind": "Struct", + "usr": "s:4cake17fixedLayoutStructV", + "mangledName": "$s4cake17fixedLayoutStructV", + "moduleName": "cake", + "declAttributes": [ + "Frozen" + ], + "conformances": [ + { + "kind": "Conformance", + "name": "Sendable", + "printedName": "Sendable", + "usr": "s:s8SendableP", + "mangledName": "$ss8SendableP" + }, + { + "kind": "Conformance", + "name": "BitwiseCopyable", + "printedName": "BitwiseCopyable", + "usr": "s:s15BitwiseCopyableP", + "mangledName": "$ss15BitwiseCopyableP" + }, + { + "kind": "Conformance", + "name": "Copyable", + "printedName": "Copyable", + "usr": "s:s8CopyableP", + "mangledName": "$ss8CopyableP" + }, + { + "kind": "Conformance", + "name": "Escapable", + "printedName": "Escapable", + "usr": "s:s9EscapableP", + "mangledName": "$ss9EscapableP" + }, + { + "kind": "Conformance", + "name": "SendableMetatype", + "printedName": "SendableMetatype", + "usr": "s:s16SendableMetatypeP", + "mangledName": "$ss16SendableMetatypeP" + } + ] + }, + { + "kind": "TypeDecl", + "name": "ProWithAssociatedType", + "printedName": "ProWithAssociatedType", + "children": [ + { + "kind": "AssociatedType", + "name": "A", + "printedName": "A", + "declKind": "AssociatedType", + "usr": "s:4cake21ProWithAssociatedTypeP1AQa", + "mangledName": "$s4cake21ProWithAssociatedTypeP1AQa", + "moduleName": "cake", + "protocolReq": true + }, + { + "kind": "AssociatedType", + "name": "B", + "printedName": "B", + "children": [ + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + } + ], + "declKind": "AssociatedType", + "usr": "s:4cake21ProWithAssociatedTypeP1BQa", + "mangledName": "$s4cake21ProWithAssociatedTypeP1BQa", + "moduleName": "cake", + "protocolReq": true + }, + { + "kind": "Function", + "name": "NonReqFunc", + "printedName": "NonReqFunc()", + "children": [ + { + "kind": "TypeNominal", + "name": "Void", + "printedName": "()" + } + ], + "declKind": "Func", + "usr": "s:4cake21ProWithAssociatedTypePAAE10NonReqFuncyyF", + "mangledName": "$s4cake21ProWithAssociatedTypePAAE10NonReqFuncyyF", + "moduleName": "cake", + "genericSig": "<τ_0_0 where τ_0_0 : cake.ProWithAssociatedType>", + "sugared_genericSig": "", + "isFromExtension": true, + "funcSelfKind": "NonMutating" + }, + { + "kind": "Var", + "name": "NonReqVar", + "printedName": "NonReqVar", + "children": [ + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + } + ], + "declKind": "Var", + "usr": "s:4cake21ProWithAssociatedTypePAAE9NonReqVarSivp", + "mangledName": "$s4cake21ProWithAssociatedTypePAAE9NonReqVarSivp", + "moduleName": "cake", + "isFromExtension": true, + "accessors": [ + { + "kind": "Accessor", + "name": "Get", + "printedName": "Get()", + "children": [ + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + } + ], + "declKind": "Accessor", + "usr": "s:4cake21ProWithAssociatedTypePAAE9NonReqVarSivg", + "mangledName": "$s4cake21ProWithAssociatedTypePAAE9NonReqVarSivg", + "moduleName": "cake", + "genericSig": "<τ_0_0 where τ_0_0 : cake.ProWithAssociatedType>", + "sugared_genericSig": "", + "isFromExtension": true, + "accessorKind": "get" + } + ] + } + ], + "declKind": "Protocol", + "usr": "s:4cake21ProWithAssociatedTypeP", + "mangledName": "$s4cake21ProWithAssociatedTypeP", + "moduleName": "cake", + "conformances": [ + { + "kind": "Conformance", + "name": "Escapable", + "printedName": "Escapable", + "usr": "s:s9EscapableP", + "mangledName": "$ss9EscapableP" + }, + { + "kind": "Conformance", + "name": "Copyable", + "printedName": "Copyable", + "usr": "s:s8CopyableP", + "mangledName": "$ss8CopyableP" + } + ] + }, + { + "kind": "TypeDecl", + "name": "SubsContainer", + "printedName": "SubsContainer", + "children": [ + { + "kind": "Subscript", + "name": "subscript", + "printedName": "subscript(getter:)", + "children": [ + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + }, + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + } + ], + "declKind": "Subscript", + "usr": "s:4cake13SubsContainerP6getterS2i_tcip", + "mangledName": "$s4cake13SubsContainerP6getterS2i_tcip", + "moduleName": "cake", + "genericSig": "<τ_0_0 where τ_0_0 : cake.SubsContainer>", + "sugared_genericSig": "", + "protocolReq": true, + "accessors": [ + { + "kind": "Accessor", + "name": "Get", + "printedName": "Get()", + "children": [ + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + }, + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + } + ], + "declKind": "Accessor", + "usr": "s:4cake13SubsContainerP6getterS2i_tcig", + "mangledName": "$s4cake13SubsContainerP6getterS2i_tcig", + "moduleName": "cake", + "genericSig": "<τ_0_0 where τ_0_0 : cake.SubsContainer>", + "sugared_genericSig": "", + "protocolReq": true, + "reqNewWitnessTableEntry": true, + "accessorKind": "get" + } + ] + }, + { + "kind": "Subscript", + "name": "subscript", + "printedName": "subscript(setter:)", + "children": [ + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + }, + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + } + ], + "declKind": "Subscript", + "usr": "s:4cake13SubsContainerP6setterS2i_tcip", + "mangledName": "$s4cake13SubsContainerP6setterS2i_tcip", + "moduleName": "cake", + "genericSig": "<τ_0_0 where τ_0_0 : cake.SubsContainer>", + "sugared_genericSig": "", + "protocolReq": true, + "accessors": [ + { + "kind": "Accessor", + "name": "Get", + "printedName": "Get()", + "children": [ + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + }, + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + } + ], + "declKind": "Accessor", + "usr": "s:4cake13SubsContainerP6setterS2i_tcig", + "mangledName": "$s4cake13SubsContainerP6setterS2i_tcig", + "moduleName": "cake", + "genericSig": "<τ_0_0 where τ_0_0 : cake.SubsContainer>", + "sugared_genericSig": "", + "protocolReq": true, + "reqNewWitnessTableEntry": true, + "accessorKind": "get" + }, + { + "kind": "Accessor", + "name": "Set", + "printedName": "Set()", + "children": [ + { + "kind": "TypeNominal", + "name": "Void", + "printedName": "()" + }, + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + }, + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + } + ], + "declKind": "Accessor", + "usr": "s:4cake13SubsContainerP6setterS2i_tcis", + "mangledName": "$s4cake13SubsContainerP6setterS2i_tcis", + "moduleName": "cake", + "genericSig": "<τ_0_0 where τ_0_0 : cake.SubsContainer>", + "sugared_genericSig": "", + "protocolReq": true, + "reqNewWitnessTableEntry": true, + "accessorKind": "set" + }, + { + "kind": "Accessor", + "name": "Modify", + "printedName": "Modify()", + "children": [ + { + "kind": "TypeNominal", + "name": "Void", + "printedName": "()" + }, + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + } + ], + "declKind": "Accessor", + "usr": "s:4cake13SubsContainerP6setterS2i_tciM", + "mangledName": "$s4cake13SubsContainerP6setterS2i_tciM", + "moduleName": "cake", + "genericSig": "<τ_0_0 where τ_0_0 : cake.SubsContainer>", + "sugared_genericSig": "", + "protocolReq": true, + "implicit": true, + "reqNewWitnessTableEntry": true, + "accessorKind": "_modify" + } + ] + } + ], + "declKind": "Protocol", + "usr": "s:4cake13SubsContainerP", + "mangledName": "$s4cake13SubsContainerP", + "moduleName": "cake", + "conformances": [ + { + "kind": "Conformance", + "name": "Escapable", + "printedName": "Escapable", + "usr": "s:s9EscapableP", + "mangledName": "$ss9EscapableP" + }, + { + "kind": "Conformance", + "name": "Copyable", + "printedName": "Copyable", + "usr": "s:s8CopyableP", + "mangledName": "$ss8CopyableP" + } + ] + }, + { + "kind": "TypeDecl", + "name": "PSuper", + "printedName": "PSuper", + "children": [ + { + "kind": "AssociatedType", + "name": "T", + "printedName": "T", + "declKind": "AssociatedType", + "usr": "s:4cake6PSuperP1TQa", + "mangledName": "$s4cake6PSuperP1TQa", + "moduleName": "cake", + "protocolReq": true + }, + { + "kind": "Function", + "name": "foo", + "printedName": "foo()", + "children": [ + { + "kind": "TypeNominal", + "name": "Void", + "printedName": "()" + } + ], + "declKind": "Func", + "usr": "s:4cake6PSuperP3fooyyF", + "mangledName": "$s4cake6PSuperP3fooyyF", + "moduleName": "cake", + "genericSig": "<τ_0_0 where τ_0_0 : cake.PSuper>", + "sugared_genericSig": "", + "protocolReq": true, + "reqNewWitnessTableEntry": true, + "funcSelfKind": "NonMutating" + }, + { + "kind": "Function", + "name": "futureFoo", + "printedName": "futureFoo()", + "children": [ + { + "kind": "TypeNominal", + "name": "Void", + "printedName": "()" + } + ], + "declKind": "Func", + "usr": "s:4cake6PSuperPAAE9futureFooyyF", + "mangledName": "$s4cake6PSuperPAAE9futureFooyyF", + "moduleName": "cake", + "genericSig": "<τ_0_0 where τ_0_0 : cake.PSuper>", + "sugared_genericSig": "", + "isFromExtension": true, + "funcSelfKind": "NonMutating" + } + ], + "declKind": "Protocol", + "usr": "s:4cake6PSuperP", + "mangledName": "$s4cake6PSuperP", + "moduleName": "cake", + "conformances": [ + { + "kind": "Conformance", + "name": "Escapable", + "printedName": "Escapable", + "usr": "s:s9EscapableP", + "mangledName": "$ss9EscapableP" + }, + { + "kind": "Conformance", + "name": "Copyable", + "printedName": "Copyable", + "usr": "s:s8CopyableP", + "mangledName": "$ss8CopyableP" + } + ] + }, + { + "kind": "TypeDecl", + "name": "PSub", + "printedName": "PSub", + "children": [ + { + "kind": "AssociatedType", + "name": "T", + "printedName": "T", + "declKind": "AssociatedType", + "usr": "s:4cake4PSubP1TQa", + "mangledName": "$s4cake4PSubP1TQa", + "moduleName": "cake", + "protocolReq": true, + "overriding": true + }, + { + "kind": "Function", + "name": "foo", + "printedName": "foo()", + "children": [ + { + "kind": "TypeNominal", + "name": "Void", + "printedName": "()" + } + ], + "declKind": "Func", + "usr": "s:4cake4PSubP3fooyyF", + "mangledName": "$s4cake4PSubP3fooyyF", + "moduleName": "cake", + "genericSig": "<τ_0_0 where τ_0_0 : cake.PSub>", + "sugared_genericSig": "", + "protocolReq": true, + "overriding": true, + "declAttributes": [ + "Override" + ], + "funcSelfKind": "NonMutating" + } + ], + "declKind": "Protocol", + "usr": "s:4cake4PSubP", + "mangledName": "$s4cake4PSubP", + "moduleName": "cake", + "genericSig": "<τ_0_0 : cake.PSuper>", + "sugared_genericSig": "", + "conformances": [ + { + "kind": "Conformance", + "name": "Escapable", + "printedName": "Escapable", + "usr": "s:s9EscapableP", + "mangledName": "$ss9EscapableP" + }, + { + "kind": "Conformance", + "name": "Copyable", + "printedName": "Copyable", + "usr": "s:s8CopyableP", + "mangledName": "$ss8CopyableP" + }, + { + "kind": "Conformance", + "name": "PSuper", + "printedName": "PSuper", + "usr": "s:4cake6PSuperP", + "mangledName": "$s4cake6PSuperP" + } + ] + }, + { + "kind": "Var", + "name": "GlobalVar", + "printedName": "GlobalVar", + "children": [ + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + } + ], + "declKind": "Var", + "usr": "s:4cake9GlobalVarSivp", + "mangledName": "$s4cake9GlobalVarSivp", + "moduleName": "cake", + "declAttributes": [ + "HasInitialValue", + "HasStorage" + ], + "isLet": true, + "hasStorage": true + }, + { + "kind": "OperatorDecl", + "name": "..*..", + "printedName": "..*..", + "declKind": "InfixOperator", + "moduleName": "cake", + "declAttributes": [ + "Infix" + ] + }, + { + "kind": "TypeDecl", + "name": "UsableFromInlineClass", + "printedName": "UsableFromInlineClass", + "children": [ + { + "kind": "Var", + "name": "Prop", + "printedName": "Prop", + "children": [ + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + } + ], + "declKind": "Var", + "usr": "s:4cake21UsableFromInlineClassC4Prop33_3D8926C30F7417F2EF9A277D0C73FBDBLLSivp", + "mangledName": "$s4cake21UsableFromInlineClassC4Prop33_3D8926C30F7417F2EF9A277D0C73FBDBLLSivp", + "moduleName": "cake", + "isInternal": true, + "declAttributes": [ + "HasInitialValue", + "HasStorage" + ], + "fixedbinaryorder": 0, + "hasStorage": true + } + ], + "declKind": "Class", + "usr": "s:4cake21UsableFromInlineClassC", + "mangledName": "$s4cake21UsableFromInlineClassC", + "moduleName": "cake", + "declAttributes": [ + "FixedLayout", + "UsableFromInline" + ], + "hasMissingDesignatedInitializers": true, + "conformances": [ + { + "kind": "Conformance", + "name": "Copyable", + "printedName": "Copyable", + "usr": "s:s8CopyableP", + "mangledName": "$ss8CopyableP" + }, + { + "kind": "Conformance", + "name": "Escapable", + "printedName": "Escapable", + "usr": "s:s9EscapableP", + "mangledName": "$ss9EscapableP" + } + ] + }, + { + "kind": "TypeDecl", + "name": "FutureContainer", + "printedName": "FutureContainer", + "children": [ + { + "kind": "Function", + "name": "futureFoo", + "printedName": "futureFoo()", + "children": [ + { + "kind": "TypeNominal", + "name": "Void", + "printedName": "()" + } + ], + "declKind": "Func", + "usr": "s:4cake15FutureContainerC9futureFooyyF", + "mangledName": "$s4cake15FutureContainerC9futureFooyyF", + "moduleName": "cake", + "intro_Macosx": "10.15", + "intro_iOS": "13", + "intro_tvOS": "13", + "intro_watchOS": "6", + "declAttributes": [ + "Available", + "Available", + "Available", + "Available" + ], + "funcSelfKind": "NonMutating" + }, + { + "kind": "Function", + "name": "NotfutureFoo", + "printedName": "NotfutureFoo()", + "children": [ + { + "kind": "TypeNominal", + "name": "Void", + "printedName": "()" + } + ], + "declKind": "Func", + "usr": "s:4cake15FutureContainerC12NotfutureFooyyF", + "mangledName": "$s4cake15FutureContainerC12NotfutureFooyyF", + "moduleName": "cake", + "intro_Macosx": "10.15", + "declAttributes": [ + "Available" + ], + "funcSelfKind": "NonMutating" + } + ], + "declKind": "Class", + "usr": "s:4cake15FutureContainerC", + "mangledName": "$s4cake15FutureContainerC", + "moduleName": "cake", + "hasMissingDesignatedInitializers": true, + "conformances": [ + { + "kind": "Conformance", + "name": "Copyable", + "printedName": "Copyable", + "usr": "s:s8CopyableP", + "mangledName": "$ss8CopyableP" + }, + { + "kind": "Conformance", + "name": "Escapable", + "printedName": "Escapable", + "usr": "s:s9EscapableP", + "mangledName": "$ss9EscapableP" + }, + { + "kind": "Conformance", + "name": "P1", + "printedName": "P1", + "usr": "s:4cake2P1P", + "mangledName": "$s4cake2P1P" + }, + { + "kind": "Conformance", + "name": "P2", + "printedName": "P2", + "usr": "s:4cake2P2P", + "mangledName": "$s4cake2P2P" + } + ] + }, + { + "kind": "TypeDecl", + "name": "PlatformIntroClass", + "printedName": "PlatformIntroClass", + "declKind": "Class", + "usr": "s:4cake18PlatformIntroClassC", + "mangledName": "$s4cake18PlatformIntroClassC", + "moduleName": "cake", + "intro_Macosx": "10.1", + "intro_iOS": "10.2", + "intro_tvOS": "10.3", + "intro_watchOS": "3.4", + "declAttributes": [ + "Available", + "Available", + "Available", + "Available" + ], + "hasMissingDesignatedInitializers": true, + "conformances": [ + { + "kind": "Conformance", + "name": "Copyable", + "printedName": "Copyable", + "usr": "s:s8CopyableP", + "mangledName": "$ss8CopyableP" + }, + { + "kind": "Conformance", + "name": "Escapable", + "printedName": "Escapable", + "usr": "s:s9EscapableP", + "mangledName": "$ss9EscapableP" + } + ] + }, + { + "kind": "TypeDecl", + "name": "SwiftIntroClass", + "printedName": "SwiftIntroClass", + "declKind": "Class", + "usr": "s:4cake15SwiftIntroClassC", + "mangledName": "$s4cake15SwiftIntroClassC", + "moduleName": "cake", + "intro_swift": "5", + "declAttributes": [ + "Available" + ], + "hasMissingDesignatedInitializers": true, + "conformances": [ + { + "kind": "Conformance", + "name": "Copyable", + "printedName": "Copyable", + "usr": "s:s8CopyableP", + "mangledName": "$ss8CopyableP" + }, + { + "kind": "Conformance", + "name": "Escapable", + "printedName": "Escapable", + "usr": "s:s9EscapableP", + "mangledName": "$ss9EscapableP" + } + ] + }, + { + "kind": "TypeDecl", + "name": "SwiftObjcClass", + "printedName": "SwiftObjcClass", + "children": [ + { + "kind": "Function", + "name": "foo", + "printedName": "foo(a:b:c:)", + "children": [ + { + "kind": "TypeNominal", + "name": "Void", + "printedName": "()" + }, + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + }, + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + }, + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + } + ], + "declKind": "Func", + "usr": "c:@M@cake@objc(cs)NewObjCClass(im)ObjCFool:ObjCA:ObjCB:", + "mangledName": "$s4cake14SwiftObjcClassC3foo1a1b1cySi_S2itF", + "moduleName": "cake", + "objc_name": "ObjCFool:ObjCA:ObjCB:", + "declAttributes": [ + "ObjC" + ], + "funcSelfKind": "NonMutating" + } + ], + "declKind": "Class", + "usr": "c:@M@cake@objc(cs)NewObjCClass", + "mangledName": "$s4cake14SwiftObjcClassC", + "moduleName": "cake", + "objc_name": "NewObjCClass", + "declAttributes": [ + "ObjC" + ], + "hasMissingDesignatedInitializers": true, + "conformances": [ + { + "kind": "Conformance", + "name": "Copyable", + "printedName": "Copyable", + "usr": "s:s8CopyableP", + "mangledName": "$ss8CopyableP" + }, + { + "kind": "Conformance", + "name": "Escapable", + "printedName": "Escapable", + "usr": "s:s9EscapableP", + "mangledName": "$ss9EscapableP" + } + ] + }, + { + "kind": "Function", + "name": "silgenNamedFunc", + "printedName": "silgenNamedFunc()", + "children": [ + { + "kind": "TypeNominal", + "name": "Void", + "printedName": "()" + } + ], + "declKind": "Func", + "usr": "s:4cake15silgenNamedFuncyyF", + "mangledName": "silgenName", + "moduleName": "cake", + "declAttributes": [ + "SILGenName" + ], + "funcSelfKind": "NonMutating" + }, + { + "kind": "TypeDecl", + "name": "SinkingClass", + "printedName": "SinkingClass", + "children": [ + { + "kind": "Constructor", + "name": "init", + "printedName": "init()", + "children": [ + { + "kind": "TypeNominal", + "name": "SinkingClass", + "printedName": "Bread.SinkingClass", + "usr": "s:4cake12SinkingClassC" + } + ], + "declKind": "Constructor", + "usr": "s:4cake12SinkingClassCACycfc", + "mangledName": "$s5Bread12SinkingClassCACycfc", + "moduleName": "cake", + "spi_group_names": [ + "top_secret_2", + "top_secret_1" + ], + "init_kind": "Designated" + } + ], + "declKind": "Class", + "usr": "s:4cake12SinkingClassC", + "mangledName": "$s5Bread12SinkingClassC", + "moduleName": "cake", + "intro_Macosx": "10.7", + "declAttributes": [ + "SPIAccessControl", + "SPIAccessControl", + "OriginallyDefinedIn", + "Available" + ], + "spi_group_names": [ + "top_secret_2", + "top_secret_1" + ], + "conformances": [ + { + "kind": "Conformance", + "name": "Copyable", + "printedName": "Copyable", + "usr": "s:s8CopyableP", + "mangledName": "$ss8CopyableP" + }, + { + "kind": "Conformance", + "name": "Escapable", + "printedName": "Escapable", + "usr": "s:s9EscapableP", + "mangledName": "$ss9EscapableP" + } + ] + }, + { + "kind": "TypeDecl", + "name": "Int", + "printedName": "Int", + "children": [ + { + "kind": "Function", + "name": "foo", + "printedName": "foo()", + "children": [ + { + "kind": "TypeNominal", + "name": "Void", + "printedName": "()" + } + ], + "declKind": "Func", + "usr": "s:Si4cakeE3fooyyF", + "mangledName": "$sSi4cakeE3fooyyF", + "moduleName": "cake", + "isFromExtension": true, + "funcSelfKind": "NonMutating" + }, + { + "kind": "Function", + "name": "bar", + "printedName": "bar()", + "children": [ + { + "kind": "TypeNominal", + "name": "Void", + "printedName": "()" + } + ], + "declKind": "Func", + "usr": "s:Si4cakeE3baryyF", + "mangledName": "$sSi4cakeE3baryyF", + "moduleName": "cake", + "isFromExtension": true, + "funcSelfKind": "NonMutating" + } + ], + "declKind": "Struct", + "usr": "s:Si", + "mangledName": "$sSi", + "moduleName": "Swift", + "declAttributes": [ + "Frozen" + ], + "isExternal": true, + "conformances": [ + { + "kind": "Conformance", + "name": "FixedWidthInteger", + "printedName": "FixedWidthInteger", + "usr": "s:s17FixedWidthIntegerP", + "mangledName": "$ss17FixedWidthIntegerP" + }, + { + "kind": "Conformance", + "name": "SignedInteger", + "printedName": "SignedInteger", + "usr": "s:SZ", + "mangledName": "$sSZ" + }, + { + "kind": "Conformance", + "name": "_ExpressibleByBuiltinIntegerLiteral", + "printedName": "_ExpressibleByBuiltinIntegerLiteral", + "usr": "s:s35_ExpressibleByBuiltinIntegerLiteralP", + "mangledName": "$ss35_ExpressibleByBuiltinIntegerLiteralP" + }, + { + "kind": "Conformance", + "name": "BinaryInteger", + "printedName": "BinaryInteger", + "children": [ + { + "kind": "TypeWitness", + "name": "Words", + "printedName": "Words", + "children": [ + { + "kind": "TypeNominal", + "name": "Words", + "printedName": "Swift.Int.Words", + "usr": "s:Si5WordsV" + } + ] + } + ], + "usr": "s:Sz", + "mangledName": "$sSz" + }, + { + "kind": "Conformance", + "name": "LosslessStringConvertible", + "printedName": "LosslessStringConvertible", + "usr": "s:s25LosslessStringConvertibleP", + "mangledName": "$ss25LosslessStringConvertibleP" + }, + { + "kind": "Conformance", + "name": "SignedNumeric", + "printedName": "SignedNumeric", + "usr": "s:s13SignedNumericP", + "mangledName": "$ss13SignedNumericP" + }, + { + "kind": "Conformance", + "name": "Numeric", + "printedName": "Numeric", + "children": [ + { + "kind": "TypeWitness", + "name": "Magnitude", + "printedName": "Magnitude", + "children": [ + { + "kind": "TypeNominal", + "name": "UInt", + "printedName": "Swift.UInt", + "usr": "s:Su" + } + ] + } + ], + "usr": "s:Sj", + "mangledName": "$sSj" + }, + { + "kind": "Conformance", + "name": "CustomStringConvertible", + "printedName": "CustomStringConvertible", + "usr": "s:s23CustomStringConvertibleP", + "mangledName": "$ss23CustomStringConvertibleP" + }, + { + "kind": "Conformance", + "name": "Strideable", + "printedName": "Strideable", + "children": [ + { + "kind": "TypeWitness", + "name": "Stride", + "printedName": "Stride", + "children": [ + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + } + ] + } + ], + "usr": "s:Sx", + "mangledName": "$sSx" + }, + { + "kind": "Conformance", + "name": "AdditiveArithmetic", + "printedName": "AdditiveArithmetic", + "usr": "s:s18AdditiveArithmeticP", + "mangledName": "$ss18AdditiveArithmeticP" + }, + { + "kind": "Conformance", + "name": "ExpressibleByIntegerLiteral", + "printedName": "ExpressibleByIntegerLiteral", + "children": [ + { + "kind": "TypeWitness", + "name": "IntegerLiteralType", + "printedName": "IntegerLiteralType", + "children": [ + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + } + ] + } + ], + "usr": "s:s27ExpressibleByIntegerLiteralP", + "mangledName": "$ss27ExpressibleByIntegerLiteralP" + }, + { + "kind": "Conformance", + "name": "Comparable", + "printedName": "Comparable", + "usr": "s:SL", + "mangledName": "$sSL" + }, + { + "kind": "Conformance", + "name": "Copyable", + "printedName": "Copyable", + "usr": "s:s8CopyableP", + "mangledName": "$ss8CopyableP" + }, + { + "kind": "Conformance", + "name": "Escapable", + "printedName": "Escapable", + "usr": "s:s9EscapableP", + "mangledName": "$ss9EscapableP" + }, + { + "kind": "Conformance", + "name": "P1", + "printedName": "P1", + "usr": "s:4cake2P1P", + "mangledName": "$s4cake2P1P" + }, + { + "kind": "Conformance", + "name": "Encodable", + "printedName": "Encodable", + "usr": "s:SE", + "mangledName": "$sSE" + }, + { + "kind": "Conformance", + "name": "Decodable", + "printedName": "Decodable", + "usr": "s:Se", + "mangledName": "$sSe" + }, + { + "kind": "Conformance", + "name": "CodingKeyRepresentable", + "printedName": "CodingKeyRepresentable", + "usr": "s:s22CodingKeyRepresentableP", + "mangledName": "$ss22CodingKeyRepresentableP" + }, + { + "kind": "Conformance", + "name": "CustomReflectable", + "printedName": "CustomReflectable", + "usr": "s:s17CustomReflectableP", + "mangledName": "$ss17CustomReflectableP" + }, + { + "kind": "Conformance", + "name": "_CustomPlaygroundQuickLookable", + "printedName": "_CustomPlaygroundQuickLookable", + "usr": "s:s30_CustomPlaygroundQuickLookableP", + "mangledName": "$ss30_CustomPlaygroundQuickLookableP" + }, + { + "kind": "Conformance", + "name": "MirrorPath", + "printedName": "MirrorPath", + "usr": "s:s10MirrorPathP", + "mangledName": "$ss10MirrorPathP" + }, + { + "kind": "Conformance", + "name": "CVarArg", + "printedName": "CVarArg", + "usr": "s:s7CVarArgP", + "mangledName": "$ss7CVarArgP" + }, + { + "kind": "Conformance", + "name": "Hashable", + "printedName": "Hashable", + "usr": "s:SH", + "mangledName": "$sSH" + }, + { + "kind": "Conformance", + "name": "Equatable", + "printedName": "Equatable", + "usr": "s:SQ", + "mangledName": "$sSQ" + }, + { + "kind": "Conformance", + "name": "_HasCustomAnyHashableRepresentation", + "printedName": "_HasCustomAnyHashableRepresentation", + "usr": "s:s35_HasCustomAnyHashableRepresentationP", + "mangledName": "$ss35_HasCustomAnyHashableRepresentationP" + }, + { + "kind": "Conformance", + "name": "Sendable", + "printedName": "Sendable", + "usr": "s:s8SendableP", + "mangledName": "$ss8SendableP" + }, + { + "kind": "Conformance", + "name": "SendableMetatype", + "printedName": "SendableMetatype", + "usr": "s:s16SendableMetatypeP", + "mangledName": "$ss16SendableMetatypeP" + }, + { + "kind": "Conformance", + "name": "SIMDScalar", + "printedName": "SIMDScalar", + "children": [ + { + "kind": "TypeWitness", + "name": "SIMDMaskScalar", + "printedName": "SIMDMaskScalar", + "children": [ + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + } + ] + }, + { + "kind": "TypeWitness", + "name": "SIMD2Storage", + "printedName": "SIMD2Storage", + "children": [ + { + "kind": "TypeNominal", + "name": "SIMD2Storage", + "printedName": "Swift.Int.SIMD2Storage", + "usr": "s:Si12SIMD2StorageV" + } + ] + }, + { + "kind": "TypeWitness", + "name": "SIMD4Storage", + "printedName": "SIMD4Storage", + "children": [ + { + "kind": "TypeNominal", + "name": "SIMD4Storage", + "printedName": "Swift.Int.SIMD4Storage", + "usr": "s:Si12SIMD4StorageV" + } + ] + }, + { + "kind": "TypeWitness", + "name": "SIMD8Storage", + "printedName": "SIMD8Storage", + "children": [ + { + "kind": "TypeNominal", + "name": "SIMD8Storage", + "printedName": "Swift.Int.SIMD8Storage", + "usr": "s:Si12SIMD8StorageV" + } + ] + }, + { + "kind": "TypeWitness", + "name": "SIMD16Storage", + "printedName": "SIMD16Storage", + "children": [ + { + "kind": "TypeNominal", + "name": "SIMD16Storage", + "printedName": "Swift.Int.SIMD16Storage", + "usr": "s:Si13SIMD16StorageV" + } + ] + }, + { + "kind": "TypeWitness", + "name": "SIMD32Storage", + "printedName": "SIMD32Storage", + "children": [ + { + "kind": "TypeNominal", + "name": "SIMD32Storage", + "printedName": "Swift.Int.SIMD32Storage", + "usr": "s:Si13SIMD32StorageV" + } + ] + }, + { + "kind": "TypeWitness", + "name": "SIMD64Storage", + "printedName": "SIMD64Storage", + "children": [ + { + "kind": "TypeNominal", + "name": "SIMD64Storage", + "printedName": "Swift.Int.SIMD64Storage", + "usr": "s:Si13SIMD64StorageV" + } + ] + } + ], + "usr": "s:s10SIMDScalarP", + "mangledName": "$ss10SIMDScalarP" + }, + { + "kind": "Conformance", + "name": "BitwiseCopyable", + "printedName": "BitwiseCopyable", + "usr": "s:s15BitwiseCopyableP", + "mangledName": "$ss15BitwiseCopyableP" + } + ] + } + ], + "json_format_version": 8 + } +} \ No newline at end of file diff --git a/test/api-digester/Outputs/cake.json b/test/api-digester/Outputs/dump-module/cake-arm64.json similarity index 100% rename from test/api-digester/Outputs/cake.json rename to test/api-digester/Outputs/dump-module/cake-arm64.json diff --git a/test/api-digester/Outputs/dump-module/cake-x86_64.json b/test/api-digester/Outputs/dump-module/cake-x86_64.json new file mode 100644 index 0000000000000..5f1d958671cea --- /dev/null +++ b/test/api-digester/Outputs/dump-module/cake-x86_64.json @@ -0,0 +1,2247 @@ +{ + "ABIRoot": { + "kind": "Root", + "name": "cake", + "printedName": "cake", + "children": [ + { + "kind": "Import", + "name": "SwiftOnoneSupport", + "printedName": "SwiftOnoneSupport", + "declKind": "Import", + "moduleName": "cake" + }, + { + "kind": "Import", + "name": "_Concurrency", + "printedName": "_Concurrency", + "declKind": "Import", + "moduleName": "cake" + }, + { + "kind": "Import", + "name": "_StringProcessing", + "printedName": "_StringProcessing", + "declKind": "Import", + "moduleName": "cake" + }, + { + "kind": "Import", + "name": "_SwiftConcurrencyShims", + "printedName": "_SwiftConcurrencyShims", + "declKind": "Import", + "moduleName": "cake" + }, + { + "kind": "Import", + "name": "cake", + "printedName": "cake", + "declKind": "Import", + "moduleName": "cake", + "declAttributes": [ + "Exported" + ] + }, + { + "kind": "TypeDecl", + "name": "P1", + "printedName": "P1", + "children": [ + { + "kind": "Function", + "name": "+", + "printedName": "+(_:_:)", + "children": [ + { + "kind": "TypeNominal", + "name": "GenericTypeParam", + "printedName": "Self" + }, + { + "kind": "TypeNominal", + "name": "GenericTypeParam", + "printedName": "Self" + }, + { + "kind": "TypeNominal", + "name": "GenericTypeParam", + "printedName": "Self" + } + ], + "declKind": "Func", + "usr": "s:4cake2P1PAAE1poiyxx_xtFZ", + "mangledName": "$s4cake2P1PAAE1poiyxx_xtFZ", + "moduleName": "cake", + "genericSig": "", + "static": true, + "isFromExtension": true, + "funcSelfKind": "NonMutating" + } + ], + "declKind": "Protocol", + "usr": "s:4cake2P1P", + "mangledName": "$s4cake2P1P", + "moduleName": "cake", + "conformances": [ + { + "kind": "Conformance", + "name": "Escapable", + "printedName": "Escapable", + "usr": "s:s9EscapableP", + "mangledName": "$ss9EscapableP" + }, + { + "kind": "Conformance", + "name": "Copyable", + "printedName": "Copyable", + "usr": "s:s8CopyableP", + "mangledName": "$ss8CopyableP" + } + ] + }, + { + "kind": "TypeDecl", + "name": "P2", + "printedName": "P2", + "declKind": "Protocol", + "usr": "s:4cake2P2P", + "mangledName": "$s4cake2P2P", + "moduleName": "cake", + "conformances": [ + { + "kind": "Conformance", + "name": "Escapable", + "printedName": "Escapable", + "usr": "s:s9EscapableP", + "mangledName": "$ss9EscapableP" + }, + { + "kind": "Conformance", + "name": "Copyable", + "printedName": "Copyable", + "usr": "s:s8CopyableP", + "mangledName": "$ss8CopyableP" + } + ] + }, + { + "kind": "TypeDecl", + "name": "P3", + "printedName": "P3", + "declKind": "Protocol", + "usr": "s:4cake2P3P", + "mangledName": "$s4cake2P3P", + "moduleName": "cake", + "genericSig": "", + "conformances": [ + { + "kind": "Conformance", + "name": "Escapable", + "printedName": "Escapable", + "usr": "s:s9EscapableP", + "mangledName": "$ss9EscapableP" + }, + { + "kind": "Conformance", + "name": "Copyable", + "printedName": "Copyable", + "usr": "s:s8CopyableP", + "mangledName": "$ss8CopyableP" + }, + { + "kind": "Conformance", + "name": "P1", + "printedName": "P1", + "usr": "s:4cake2P1P", + "mangledName": "$s4cake2P1P" + }, + { + "kind": "Conformance", + "name": "P2", + "printedName": "P2", + "usr": "s:4cake2P2P", + "mangledName": "$s4cake2P2P" + } + ] + }, + { + "kind": "TypeDecl", + "name": "S1", + "printedName": "S1", + "children": [ + { + "kind": "Function", + "name": "foo1", + "printedName": "foo1()", + "children": [ + { + "kind": "TypeNominal", + "name": "Void", + "printedName": "()" + } + ], + "declKind": "Func", + "usr": "s:4cake2S1V4foo1yyFZ", + "mangledName": "$s4cake2S1V4foo1yyFZ", + "moduleName": "cake", + "static": true, + "funcSelfKind": "NonMutating" + }, + { + "kind": "Function", + "name": "foo2", + "printedName": "foo2()", + "children": [ + { + "kind": "TypeNominal", + "name": "Void", + "printedName": "()" + } + ], + "declKind": "Func", + "usr": "s:4cake2S1V4foo2yyF", + "mangledName": "$s4cake2S1V4foo2yyF", + "moduleName": "cake", + "funcSelfKind": "Mutating" + }, + { + "kind": "Function", + "name": "foo6", + "printedName": "foo6()", + "children": [ + { + "kind": "TypeNameAlias", + "name": "Void", + "printedName": "Swift.Void", + "children": [ + { + "kind": "TypeNominal", + "name": "Void", + "printedName": "()" + } + ] + } + ], + "declKind": "Func", + "usr": "s:4cake2S1V4foo6yyF", + "mangledName": "$s4cake2S1V4foo6yyF", + "moduleName": "cake", + "funcSelfKind": "NonMutating" + } + ], + "declKind": "Struct", + "usr": "s:4cake2S1V", + "mangledName": "$s4cake2S1V", + "moduleName": "cake", + "declAttributes": [ + "Frozen" + ], + "conformances": [ + { + "kind": "Conformance", + "name": "P1", + "printedName": "P1", + "usr": "s:4cake2P1P", + "mangledName": "$s4cake2P1P" + }, + { + "kind": "Conformance", + "name": "Sendable", + "printedName": "Sendable", + "usr": "s:s8SendableP", + "mangledName": "$ss8SendableP" + }, + { + "kind": "Conformance", + "name": "BitwiseCopyable", + "printedName": "BitwiseCopyable", + "usr": "s:s15BitwiseCopyableP", + "mangledName": "$ss15BitwiseCopyableP" + }, + { + "kind": "Conformance", + "name": "Copyable", + "printedName": "Copyable", + "usr": "s:s8CopyableP", + "mangledName": "$ss8CopyableP" + }, + { + "kind": "Conformance", + "name": "Escapable", + "printedName": "Escapable", + "usr": "s:s9EscapableP", + "mangledName": "$ss9EscapableP" + }, + { + "kind": "Conformance", + "name": "SendableMetatype", + "printedName": "SendableMetatype", + "usr": "s:s16SendableMetatypeP", + "mangledName": "$ss16SendableMetatypeP" + }, + { + "kind": "Conformance", + "name": "P2", + "printedName": "P2", + "usr": "s:4cake2P2P", + "mangledName": "$s4cake2P2P" + } + ] + }, + { + "kind": "TypeDecl", + "name": "C0", + "printedName": "C0", + "children": [ + { + "kind": "Function", + "name": "conditionalFooExt", + "printedName": "conditionalFooExt()", + "children": [ + { + "kind": "TypeNominal", + "name": "Void", + "printedName": "()" + } + ], + "declKind": "Func", + "usr": "s:4cake2C0CA2A2S1VRszAERs_AERs0_rlE17conditionalFooExtyyF", + "mangledName": "$s4cake2C0CA2A2S1VRszAERs_AERs0_rlE17conditionalFooExtyyF", + "moduleName": "cake", + "genericSig": "", + "isFromExtension": true, + "funcSelfKind": "NonMutating" + }, + { + "kind": "Function", + "name": "unconditionalFooExt", + "printedName": "unconditionalFooExt()", + "children": [ + { + "kind": "TypeNominal", + "name": "Void", + "printedName": "()" + } + ], + "declKind": "Func", + "usr": "s:4cake2C0C19unconditionalFooExtyyF", + "mangledName": "$s4cake2C0C19unconditionalFooExtyyF", + "moduleName": "cake", + "genericSig": "", + "isFromExtension": true, + "funcSelfKind": "NonMutating" + } + ], + "declKind": "Class", + "usr": "s:4cake2C0C", + "mangledName": "$s4cake2C0C", + "moduleName": "cake", + "genericSig": "", + "hasMissingDesignatedInitializers": true, + "conformances": [ + { + "kind": "Conformance", + "name": "Copyable", + "printedName": "Copyable", + "usr": "s:s8CopyableP", + "mangledName": "$ss8CopyableP" + }, + { + "kind": "Conformance", + "name": "Escapable", + "printedName": "Escapable", + "usr": "s:s9EscapableP", + "mangledName": "$ss9EscapableP" + } + ] + }, + { + "kind": "TypeAlias", + "name": "C0Alias", + "printedName": "C0Alias", + "children": [ + { + "kind": "TypeNominal", + "name": "C0", + "printedName": "cake.C0", + "children": [ + { + "kind": "TypeNominal", + "name": "S1", + "printedName": "cake.S1", + "usr": "s:4cake2S1V" + }, + { + "kind": "TypeNominal", + "name": "S1", + "printedName": "cake.S1", + "usr": "s:4cake2S1V" + }, + { + "kind": "TypeNominal", + "name": "S1", + "printedName": "cake.S1", + "usr": "s:4cake2S1V" + } + ], + "usr": "s:4cake2C0C" + } + ], + "declKind": "TypeAlias", + "usr": "s:4cake7C0Aliasa", + "mangledName": "$s4cake7C0Aliasa", + "moduleName": "cake" + }, + { + "kind": "TypeDecl", + "name": "C1", + "printedName": "C1", + "children": [ + { + "kind": "Function", + "name": "foo1", + "printedName": "foo1()", + "children": [ + { + "kind": "TypeNominal", + "name": "Void", + "printedName": "()" + } + ], + "declKind": "Func", + "usr": "s:4cake2C1C4foo1yyFZ", + "mangledName": "$s4cake2C1C4foo1yyFZ", + "moduleName": "cake", + "static": true, + "isOpen": true, + "funcSelfKind": "NonMutating" + }, + { + "kind": "Var", + "name": "Ins", + "printedName": "Ins", + "children": [ + { + "kind": "TypeNominal", + "name": "WeakStorage", + "printedName": "cake.C1?" + } + ], + "declKind": "Var", + "usr": "s:4cake2C1C3InsACSgvp", + "mangledName": "$s4cake2C1C3InsACSgvp", + "moduleName": "cake", + "declAttributes": [ + "HasInitialValue", + "ReferenceOwnership", + "HasStorage" + ], + "ownership": 1, + "hasStorage": true, + "accessors": [ + { + "kind": "Accessor", + "name": "Get", + "printedName": "Get()", + "children": [ + { + "kind": "TypeNominal", + "name": "Optional", + "printedName": "cake.C1?", + "children": [ + { + "kind": "TypeNominal", + "name": "C1", + "printedName": "cake.C1", + "usr": "s:4cake2C1C" + } + ], + "usr": "s:Sq" + } + ], + "declKind": "Accessor", + "usr": "s:4cake2C1C3InsACSgvg", + "mangledName": "$s4cake2C1C3InsACSgvg", + "moduleName": "cake", + "implicit": true, + "declAttributes": [ + "Transparent" + ], + "accessorKind": "get" + }, + { + "kind": "Accessor", + "name": "Set", + "printedName": "Set()", + "children": [ + { + "kind": "TypeNominal", + "name": "Void", + "printedName": "()" + }, + { + "kind": "TypeNominal", + "name": "Optional", + "printedName": "cake.C1?", + "children": [ + { + "kind": "TypeNominal", + "name": "C1", + "printedName": "cake.C1", + "usr": "s:4cake2C1C" + } + ], + "usr": "s:Sq" + } + ], + "declKind": "Accessor", + "usr": "s:4cake2C1C3InsACSgvs", + "mangledName": "$s4cake2C1C3InsACSgvs", + "moduleName": "cake", + "implicit": true, + "declAttributes": [ + "Transparent" + ], + "accessorKind": "set" + } + ] + }, + { + "kind": "Var", + "name": "Ins2", + "printedName": "Ins2", + "children": [ + { + "kind": "TypeNominal", + "name": "UnownedStorage", + "printedName": "cake.C1" + } + ], + "declKind": "Var", + "usr": "s:4cake2C1C4Ins2ACvp", + "mangledName": "$s4cake2C1C4Ins2ACvp", + "moduleName": "cake", + "declAttributes": [ + "HasInitialValue", + "ReferenceOwnership", + "HasStorage" + ], + "ownership": 2, + "hasStorage": true, + "accessors": [ + { + "kind": "Accessor", + "name": "Get", + "printedName": "Get()", + "children": [ + { + "kind": "TypeNominal", + "name": "C1", + "printedName": "cake.C1", + "usr": "s:4cake2C1C" + } + ], + "declKind": "Accessor", + "usr": "s:4cake2C1C4Ins2ACvg", + "mangledName": "$s4cake2C1C4Ins2ACvg", + "moduleName": "cake", + "implicit": true, + "declAttributes": [ + "Transparent" + ], + "accessorKind": "get" + }, + { + "kind": "Accessor", + "name": "Set", + "printedName": "Set()", + "children": [ + { + "kind": "TypeNominal", + "name": "Void", + "printedName": "()" + }, + { + "kind": "TypeNominal", + "name": "C1", + "printedName": "cake.C1", + "usr": "s:4cake2C1C" + } + ], + "declKind": "Accessor", + "usr": "s:4cake2C1C4Ins2ACvs", + "mangledName": "$s4cake2C1C4Ins2ACvs", + "moduleName": "cake", + "implicit": true, + "declAttributes": [ + "Transparent" + ], + "accessorKind": "set" + } + ] + } + ], + "declKind": "Class", + "usr": "s:4cake2C1C", + "mangledName": "$s4cake2C1C", + "moduleName": "cake", + "superclassUsr": "s:4cake2C0C", + "hasMissingDesignatedInitializers": true, + "inheritsConvenienceInitializers": true, + "superclassNames": [ + "cake.C0" + ], + "conformances": [ + { + "kind": "Conformance", + "name": "Copyable", + "printedName": "Copyable", + "usr": "s:s8CopyableP", + "mangledName": "$ss8CopyableP" + }, + { + "kind": "Conformance", + "name": "Escapable", + "printedName": "Escapable", + "usr": "s:s9EscapableP", + "mangledName": "$ss9EscapableP" + } + ] + }, + { + "kind": "Function", + "name": "foo1", + "printedName": "foo1(_:b:)", + "children": [ + { + "kind": "TypeNominal", + "name": "Void", + "printedName": "()" + }, + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "hasDefaultArg": true, + "usr": "s:Si" + }, + { + "kind": "TypeNominal", + "name": "S1", + "printedName": "cake.S1", + "usr": "s:4cake2S1V" + } + ], + "declKind": "Func", + "usr": "s:4cake4foo1_1bySi_AA2S1VtF", + "mangledName": "$s4cake4foo1_1bySi_AA2S1VtF", + "moduleName": "cake", + "funcSelfKind": "NonMutating" + }, + { + "kind": "Function", + "name": "foo2", + "printedName": "foo2(_:b:)", + "children": [ + { + "kind": "TypeNominal", + "name": "Void", + "printedName": "()" + }, + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "hasDefaultArg": true, + "usr": "s:Si" + }, + { + "kind": "TypeNominal", + "name": "S1", + "printedName": "cake.S1", + "usr": "s:4cake2S1V" + } + ], + "declKind": "Func", + "usr": "s:4cake4foo2_1bySi_AA2S1VtF", + "mangledName": "$s4cake4foo2_1bySi_AA2S1VtF", + "moduleName": "cake", + "funcSelfKind": "NonMutating" + }, + { + "kind": "TypeDecl", + "name": "Number", + "printedName": "Number", + "children": [ + { + "kind": "Var", + "name": "one", + "printedName": "one", + "children": [ + { + "kind": "TypeFunc", + "name": "Function", + "printedName": "(cake.Number.Type) -> cake.Number", + "children": [ + { + "kind": "TypeNominal", + "name": "Number", + "printedName": "cake.Number", + "usr": "s:4cake6NumberO" + }, + { + "kind": "TypeNominal", + "name": "Metatype", + "printedName": "cake.Number.Type", + "children": [ + { + "kind": "TypeNominal", + "name": "Number", + "printedName": "cake.Number", + "usr": "s:4cake6NumberO" + } + ] + } + ] + } + ], + "declKind": "EnumElement", + "usr": "s:4cake6NumberO3oneyA2CmF", + "mangledName": "$s4cake6NumberO3oneyA2CmF", + "moduleName": "cake" + }, + { + "kind": "Constructor", + "name": "init", + "printedName": "init(rawValue:)", + "children": [ + { + "kind": "TypeNominal", + "name": "Optional", + "printedName": "cake.Number?", + "children": [ + { + "kind": "TypeNominal", + "name": "Number", + "printedName": "cake.Number", + "usr": "s:4cake6NumberO" + } + ], + "usr": "s:Sq" + }, + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + } + ], + "declKind": "Constructor", + "usr": "s:4cake6NumberO8rawValueACSgSi_tcfc", + "mangledName": "$s4cake6NumberO8rawValueACSgSi_tcfc", + "moduleName": "cake", + "implicit": true, + "declAttributes": [ + "Inlinable" + ], + "init_kind": "Designated" + }, + { + "kind": "TypeAlias", + "name": "RawValue", + "printedName": "RawValue", + "children": [ + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + } + ], + "declKind": "TypeAlias", + "usr": "s:4cake6NumberO8RawValuea", + "mangledName": "$s4cake6NumberO8RawValuea", + "moduleName": "cake", + "implicit": true + }, + { + "kind": "Var", + "name": "rawValue", + "printedName": "rawValue", + "children": [ + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + } + ], + "declKind": "Var", + "usr": "s:4cake6NumberO8rawValueSivp", + "mangledName": "$s4cake6NumberO8rawValueSivp", + "moduleName": "cake", + "implicit": true, + "accessors": [ + { + "kind": "Accessor", + "name": "Get", + "printedName": "Get()", + "children": [ + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + } + ], + "declKind": "Accessor", + "usr": "s:4cake6NumberO8rawValueSivg", + "mangledName": "$s4cake6NumberO8rawValueSivg", + "moduleName": "cake", + "implicit": true, + "declAttributes": [ + "Inlinable" + ], + "accessorKind": "get" + } + ] + } + ], + "declKind": "Enum", + "usr": "s:4cake6NumberO", + "mangledName": "$s4cake6NumberO", + "moduleName": "cake", + "enumRawTypeName": "Int", + "isEnumExhaustive": true, + "conformances": [ + { + "kind": "Conformance", + "name": "Equatable", + "printedName": "Equatable", + "usr": "s:SQ", + "mangledName": "$sSQ" + }, + { + "kind": "Conformance", + "name": "Hashable", + "printedName": "Hashable", + "usr": "s:SH", + "mangledName": "$sSH" + }, + { + "kind": "Conformance", + "name": "RawRepresentable", + "printedName": "RawRepresentable", + "children": [ + { + "kind": "TypeWitness", + "name": "RawValue", + "printedName": "RawValue", + "children": [ + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + } + ] + } + ], + "usr": "s:SY", + "mangledName": "$sSY" + }, + { + "kind": "Conformance", + "name": "Copyable", + "printedName": "Copyable", + "usr": "s:s8CopyableP", + "mangledName": "$ss8CopyableP" + }, + { + "kind": "Conformance", + "name": "Escapable", + "printedName": "Escapable", + "usr": "s:s9EscapableP", + "mangledName": "$ss9EscapableP" + } + ] + }, + { + "kind": "Function", + "name": "foo3", + "printedName": "foo3(_:)", + "children": [ + { + "kind": "TypeNominal", + "name": "Void", + "printedName": "()" + }, + { + "kind": "TypeNominal", + "name": "Dictionary", + "printedName": "[Swift.Int : Swift.String]", + "children": [ + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + }, + { + "kind": "TypeNominal", + "name": "String", + "printedName": "Swift.String", + "usr": "s:SS" + } + ], + "usr": "s:SD" + } + ], + "declKind": "Func", + "usr": "s:4cake4foo3yySDySiSSGF", + "mangledName": "$s4cake4foo3yySDySiSSGF", + "moduleName": "cake", + "funcSelfKind": "NonMutating" + }, + { + "kind": "TypeDecl", + "name": "fixedLayoutStruct", + "printedName": "fixedLayoutStruct", + "children": [ + { + "kind": "Var", + "name": "a", + "printedName": "a", + "children": [ + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + } + ], + "declKind": "Var", + "usr": "s:4cake17fixedLayoutStructV1aSivp", + "mangledName": "$s4cake17fixedLayoutStructV1aSivp", + "moduleName": "cake", + "declAttributes": [ + "HasInitialValue", + "HasStorage" + ], + "hasStorage": true, + "accessors": [ + { + "kind": "Accessor", + "name": "Get", + "printedName": "Get()", + "children": [ + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + } + ], + "declKind": "Accessor", + "usr": "s:4cake17fixedLayoutStructV1aSivg", + "mangledName": "$s4cake17fixedLayoutStructV1aSivg", + "moduleName": "cake", + "implicit": true, + "declAttributes": [ + "Transparent" + ], + "accessorKind": "get" + }, + { + "kind": "Accessor", + "name": "Set", + "printedName": "Set()", + "children": [ + { + "kind": "TypeNominal", + "name": "Void", + "printedName": "()" + }, + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + } + ], + "declKind": "Accessor", + "usr": "s:4cake17fixedLayoutStructV1aSivs", + "mangledName": "$s4cake17fixedLayoutStructV1aSivs", + "moduleName": "cake", + "implicit": true, + "declAttributes": [ + "Transparent" + ], + "accessorKind": "set" + } + ] + } + ], + "declKind": "Struct", + "usr": "s:4cake17fixedLayoutStructV", + "mangledName": "$s4cake17fixedLayoutStructV", + "moduleName": "cake", + "declAttributes": [ + "Frozen" + ], + "conformances": [ + { + "kind": "Conformance", + "name": "Sendable", + "printedName": "Sendable", + "usr": "s:s8SendableP", + "mangledName": "$ss8SendableP" + }, + { + "kind": "Conformance", + "name": "BitwiseCopyable", + "printedName": "BitwiseCopyable", + "usr": "s:s15BitwiseCopyableP", + "mangledName": "$ss15BitwiseCopyableP" + }, + { + "kind": "Conformance", + "name": "Copyable", + "printedName": "Copyable", + "usr": "s:s8CopyableP", + "mangledName": "$ss8CopyableP" + }, + { + "kind": "Conformance", + "name": "Escapable", + "printedName": "Escapable", + "usr": "s:s9EscapableP", + "mangledName": "$ss9EscapableP" + }, + { + "kind": "Conformance", + "name": "SendableMetatype", + "printedName": "SendableMetatype", + "usr": "s:s16SendableMetatypeP", + "mangledName": "$ss16SendableMetatypeP" + } + ] + }, + { + "kind": "TypeDecl", + "name": "ProWithAssociatedType", + "printedName": "ProWithAssociatedType", + "children": [ + { + "kind": "AssociatedType", + "name": "A", + "printedName": "A", + "declKind": "AssociatedType", + "usr": "s:4cake21ProWithAssociatedTypeP1AQa", + "mangledName": "$s4cake21ProWithAssociatedTypeP1AQa", + "moduleName": "cake", + "protocolReq": true + }, + { + "kind": "AssociatedType", + "name": "B", + "printedName": "B", + "children": [ + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + } + ], + "declKind": "AssociatedType", + "usr": "s:4cake21ProWithAssociatedTypeP1BQa", + "mangledName": "$s4cake21ProWithAssociatedTypeP1BQa", + "moduleName": "cake", + "protocolReq": true + }, + { + "kind": "Function", + "name": "NonReqFunc", + "printedName": "NonReqFunc()", + "children": [ + { + "kind": "TypeNominal", + "name": "Void", + "printedName": "()" + } + ], + "declKind": "Func", + "usr": "s:4cake21ProWithAssociatedTypePAAE10NonReqFuncyyF", + "mangledName": "$s4cake21ProWithAssociatedTypePAAE10NonReqFuncyyF", + "moduleName": "cake", + "genericSig": "", + "isFromExtension": true, + "funcSelfKind": "NonMutating" + }, + { + "kind": "Var", + "name": "NonReqVar", + "printedName": "NonReqVar", + "children": [ + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + } + ], + "declKind": "Var", + "usr": "s:4cake21ProWithAssociatedTypePAAE9NonReqVarSivp", + "mangledName": "$s4cake21ProWithAssociatedTypePAAE9NonReqVarSivp", + "moduleName": "cake", + "isFromExtension": true, + "accessors": [ + { + "kind": "Accessor", + "name": "Get", + "printedName": "Get()", + "children": [ + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + } + ], + "declKind": "Accessor", + "usr": "s:4cake21ProWithAssociatedTypePAAE9NonReqVarSivg", + "mangledName": "$s4cake21ProWithAssociatedTypePAAE9NonReqVarSivg", + "moduleName": "cake", + "genericSig": "", + "isFromExtension": true, + "accessorKind": "get" + } + ] + }, + { + "kind": "TypeAlias", + "name": "NonReqAlias", + "printedName": "NonReqAlias", + "children": [ + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + } + ], + "declKind": "TypeAlias", + "usr": "s:4cake21ProWithAssociatedTypePAAE11NonReqAliasa", + "mangledName": "$s4cake21ProWithAssociatedTypePAAE11NonReqAliasa", + "moduleName": "cake", + "genericSig": "", + "isFromExtension": true + } + ], + "declKind": "Protocol", + "usr": "s:4cake21ProWithAssociatedTypeP", + "mangledName": "$s4cake21ProWithAssociatedTypeP", + "moduleName": "cake", + "conformances": [ + { + "kind": "Conformance", + "name": "Escapable", + "printedName": "Escapable", + "usr": "s:s9EscapableP", + "mangledName": "$ss9EscapableP" + }, + { + "kind": "Conformance", + "name": "Copyable", + "printedName": "Copyable", + "usr": "s:s8CopyableP", + "mangledName": "$ss8CopyableP" + } + ] + }, + { + "kind": "TypeDecl", + "name": "SubsContainer", + "printedName": "SubsContainer", + "children": [ + { + "kind": "Subscript", + "name": "subscript", + "printedName": "subscript(getter:)", + "children": [ + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + }, + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + } + ], + "declKind": "Subscript", + "usr": "s:4cake13SubsContainerP6getterS2i_tcip", + "mangledName": "$s4cake13SubsContainerP6getterS2i_tcip", + "moduleName": "cake", + "genericSig": "", + "protocolReq": true, + "accessors": [ + { + "kind": "Accessor", + "name": "Get", + "printedName": "Get()", + "children": [ + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + }, + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + } + ], + "declKind": "Accessor", + "usr": "s:4cake13SubsContainerP6getterS2i_tcig", + "mangledName": "$s4cake13SubsContainerP6getterS2i_tcig", + "moduleName": "cake", + "genericSig": "", + "protocolReq": true, + "reqNewWitnessTableEntry": true, + "accessorKind": "get" + } + ] + }, + { + "kind": "Subscript", + "name": "subscript", + "printedName": "subscript(setter:)", + "children": [ + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + }, + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + } + ], + "declKind": "Subscript", + "usr": "s:4cake13SubsContainerP6setterS2i_tcip", + "mangledName": "$s4cake13SubsContainerP6setterS2i_tcip", + "moduleName": "cake", + "genericSig": "", + "protocolReq": true, + "accessors": [ + { + "kind": "Accessor", + "name": "Get", + "printedName": "Get()", + "children": [ + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + }, + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + } + ], + "declKind": "Accessor", + "usr": "s:4cake13SubsContainerP6setterS2i_tcig", + "mangledName": "$s4cake13SubsContainerP6setterS2i_tcig", + "moduleName": "cake", + "genericSig": "", + "protocolReq": true, + "reqNewWitnessTableEntry": true, + "accessorKind": "get" + }, + { + "kind": "Accessor", + "name": "Set", + "printedName": "Set()", + "children": [ + { + "kind": "TypeNominal", + "name": "Void", + "printedName": "()" + }, + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + }, + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + } + ], + "declKind": "Accessor", + "usr": "s:4cake13SubsContainerP6setterS2i_tcis", + "mangledName": "$s4cake13SubsContainerP6setterS2i_tcis", + "moduleName": "cake", + "genericSig": "", + "protocolReq": true, + "reqNewWitnessTableEntry": true, + "accessorKind": "set" + } + ] + } + ], + "declKind": "Protocol", + "usr": "s:4cake13SubsContainerP", + "mangledName": "$s4cake13SubsContainerP", + "moduleName": "cake", + "conformances": [ + { + "kind": "Conformance", + "name": "Escapable", + "printedName": "Escapable", + "usr": "s:s9EscapableP", + "mangledName": "$ss9EscapableP" + }, + { + "kind": "Conformance", + "name": "Copyable", + "printedName": "Copyable", + "usr": "s:s8CopyableP", + "mangledName": "$ss8CopyableP" + } + ] + }, + { + "kind": "TypeDecl", + "name": "PSuper", + "printedName": "PSuper", + "children": [ + { + "kind": "AssociatedType", + "name": "T", + "printedName": "T", + "declKind": "AssociatedType", + "usr": "s:4cake6PSuperP1TQa", + "mangledName": "$s4cake6PSuperP1TQa", + "moduleName": "cake", + "protocolReq": true + }, + { + "kind": "Function", + "name": "foo", + "printedName": "foo()", + "children": [ + { + "kind": "TypeNominal", + "name": "Void", + "printedName": "()" + } + ], + "declKind": "Func", + "usr": "s:4cake6PSuperP3fooyyF", + "mangledName": "$s4cake6PSuperP3fooyyF", + "moduleName": "cake", + "genericSig": "", + "protocolReq": true, + "reqNewWitnessTableEntry": true, + "funcSelfKind": "NonMutating" + }, + { + "kind": "Function", + "name": "futureFoo", + "printedName": "futureFoo()", + "children": [ + { + "kind": "TypeNominal", + "name": "Void", + "printedName": "()" + } + ], + "declKind": "Func", + "usr": "s:4cake6PSuperPAAE9futureFooyyF", + "mangledName": "$s4cake6PSuperPAAE9futureFooyyF", + "moduleName": "cake", + "genericSig": "", + "isFromExtension": true, + "funcSelfKind": "NonMutating" + } + ], + "declKind": "Protocol", + "usr": "s:4cake6PSuperP", + "mangledName": "$s4cake6PSuperP", + "moduleName": "cake", + "conformances": [ + { + "kind": "Conformance", + "name": "Escapable", + "printedName": "Escapable", + "usr": "s:s9EscapableP", + "mangledName": "$ss9EscapableP" + }, + { + "kind": "Conformance", + "name": "Copyable", + "printedName": "Copyable", + "usr": "s:s8CopyableP", + "mangledName": "$ss8CopyableP" + } + ] + }, + { + "kind": "TypeDecl", + "name": "PSub", + "printedName": "PSub", + "children": [ + { + "kind": "AssociatedType", + "name": "T", + "printedName": "T", + "declKind": "AssociatedType", + "usr": "s:4cake4PSubP1TQa", + "mangledName": "$s4cake4PSubP1TQa", + "moduleName": "cake", + "protocolReq": true, + "overriding": true + }, + { + "kind": "Function", + "name": "foo", + "printedName": "foo()", + "children": [ + { + "kind": "TypeNominal", + "name": "Void", + "printedName": "()" + } + ], + "declKind": "Func", + "usr": "s:4cake4PSubP3fooyyF", + "mangledName": "$s4cake4PSubP3fooyyF", + "moduleName": "cake", + "genericSig": "", + "protocolReq": true, + "overriding": true, + "declAttributes": [ + "Override" + ], + "funcSelfKind": "NonMutating" + } + ], + "declKind": "Protocol", + "usr": "s:4cake4PSubP", + "mangledName": "$s4cake4PSubP", + "moduleName": "cake", + "genericSig": "", + "conformances": [ + { + "kind": "Conformance", + "name": "Escapable", + "printedName": "Escapable", + "usr": "s:s9EscapableP", + "mangledName": "$ss9EscapableP" + }, + { + "kind": "Conformance", + "name": "Copyable", + "printedName": "Copyable", + "usr": "s:s8CopyableP", + "mangledName": "$ss8CopyableP" + }, + { + "kind": "Conformance", + "name": "PSuper", + "printedName": "PSuper", + "usr": "s:4cake6PSuperP", + "mangledName": "$s4cake6PSuperP" + } + ] + }, + { + "kind": "Var", + "name": "GlobalVar", + "printedName": "GlobalVar", + "children": [ + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + } + ], + "declKind": "Var", + "usr": "s:4cake9GlobalVarSivp", + "mangledName": "$s4cake9GlobalVarSivp", + "moduleName": "cake", + "declAttributes": [ + "HasInitialValue", + "HasStorage" + ], + "isLet": true, + "hasStorage": true + }, + { + "kind": "OperatorDecl", + "name": "..*..", + "printedName": "..*..", + "declKind": "InfixOperator", + "moduleName": "cake", + "declAttributes": [ + "Infix" + ] + }, + { + "kind": "TypeDecl", + "name": "FutureContainer", + "printedName": "FutureContainer", + "children": [ + { + "kind": "Function", + "name": "futureFoo", + "printedName": "futureFoo()", + "children": [ + { + "kind": "TypeNominal", + "name": "Void", + "printedName": "()" + } + ], + "declKind": "Func", + "usr": "s:4cake15FutureContainerC9futureFooyyF", + "mangledName": "$s4cake15FutureContainerC9futureFooyyF", + "moduleName": "cake", + "intro_Macosx": "10.15", + "intro_iOS": "13", + "intro_tvOS": "13", + "intro_watchOS": "6", + "declAttributes": [ + "Available", + "Available", + "Available", + "Available" + ], + "funcSelfKind": "NonMutating" + }, + { + "kind": "Function", + "name": "NotfutureFoo", + "printedName": "NotfutureFoo()", + "children": [ + { + "kind": "TypeNominal", + "name": "Void", + "printedName": "()" + } + ], + "declKind": "Func", + "usr": "s:4cake15FutureContainerC12NotfutureFooyyF", + "mangledName": "$s4cake15FutureContainerC12NotfutureFooyyF", + "moduleName": "cake", + "intro_Macosx": "10.15", + "declAttributes": [ + "Available" + ], + "funcSelfKind": "NonMutating" + } + ], + "declKind": "Class", + "usr": "s:4cake15FutureContainerC", + "mangledName": "$s4cake15FutureContainerC", + "moduleName": "cake", + "hasMissingDesignatedInitializers": true, + "conformances": [ + { + "kind": "Conformance", + "name": "Copyable", + "printedName": "Copyable", + "usr": "s:s8CopyableP", + "mangledName": "$ss8CopyableP" + }, + { + "kind": "Conformance", + "name": "Escapable", + "printedName": "Escapable", + "usr": "s:s9EscapableP", + "mangledName": "$ss9EscapableP" + }, + { + "kind": "Conformance", + "name": "P1", + "printedName": "P1", + "usr": "s:4cake2P1P", + "mangledName": "$s4cake2P1P" + }, + { + "kind": "Conformance", + "name": "P2", + "printedName": "P2", + "usr": "s:4cake2P2P", + "mangledName": "$s4cake2P2P" + } + ] + }, + { + "kind": "TypeDecl", + "name": "PlatformIntroClass", + "printedName": "PlatformIntroClass", + "declKind": "Class", + "usr": "s:4cake18PlatformIntroClassC", + "mangledName": "$s4cake18PlatformIntroClassC", + "moduleName": "cake", + "intro_Macosx": "10.1", + "intro_iOS": "10.2", + "intro_tvOS": "10.3", + "intro_watchOS": "3.4", + "declAttributes": [ + "Available", + "Available", + "Available", + "Available" + ], + "hasMissingDesignatedInitializers": true, + "conformances": [ + { + "kind": "Conformance", + "name": "Copyable", + "printedName": "Copyable", + "usr": "s:s8CopyableP", + "mangledName": "$ss8CopyableP" + }, + { + "kind": "Conformance", + "name": "Escapable", + "printedName": "Escapable", + "usr": "s:s9EscapableP", + "mangledName": "$ss9EscapableP" + } + ] + }, + { + "kind": "TypeDecl", + "name": "SwiftIntroClass", + "printedName": "SwiftIntroClass", + "declKind": "Class", + "usr": "s:4cake15SwiftIntroClassC", + "mangledName": "$s4cake15SwiftIntroClassC", + "moduleName": "cake", + "intro_swift": "5", + "declAttributes": [ + "Available" + ], + "hasMissingDesignatedInitializers": true, + "conformances": [ + { + "kind": "Conformance", + "name": "Copyable", + "printedName": "Copyable", + "usr": "s:s8CopyableP", + "mangledName": "$ss8CopyableP" + }, + { + "kind": "Conformance", + "name": "Escapable", + "printedName": "Escapable", + "usr": "s:s9EscapableP", + "mangledName": "$ss9EscapableP" + } + ] + }, + { + "kind": "TypeDecl", + "name": "SwiftObjcClass", + "printedName": "SwiftObjcClass", + "children": [ + { + "kind": "Function", + "name": "foo", + "printedName": "foo(a:b:c:)", + "children": [ + { + "kind": "TypeNominal", + "name": "Void", + "printedName": "()" + }, + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + }, + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + }, + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + } + ], + "declKind": "Func", + "usr": "c:@M@cake@objc(cs)NewObjCClass(im)ObjCFool:ObjCA:ObjCB:", + "mangledName": "$s4cake14SwiftObjcClassC3foo1a1b1cySi_S2itF", + "moduleName": "cake", + "objc_name": "ObjCFool:ObjCA:ObjCB:", + "declAttributes": [ + "ObjC" + ], + "funcSelfKind": "NonMutating" + } + ], + "declKind": "Class", + "usr": "c:@M@cake@objc(cs)NewObjCClass", + "mangledName": "$s4cake14SwiftObjcClassC", + "moduleName": "cake", + "objc_name": "NewObjCClass", + "declAttributes": [ + "ObjC" + ], + "hasMissingDesignatedInitializers": true, + "conformances": [ + { + "kind": "Conformance", + "name": "Copyable", + "printedName": "Copyable", + "usr": "s:s8CopyableP", + "mangledName": "$ss8CopyableP" + }, + { + "kind": "Conformance", + "name": "Escapable", + "printedName": "Escapable", + "usr": "s:s9EscapableP", + "mangledName": "$ss9EscapableP" + } + ] + }, + { + "kind": "Function", + "name": "emitIntoClientFunc", + "printedName": "emitIntoClientFunc()", + "children": [ + { + "kind": "TypeNominal", + "name": "Void", + "printedName": "()" + } + ], + "declKind": "Func", + "usr": "s:4cake18emitIntoClientFuncyyF", + "mangledName": "$s4cake18emitIntoClientFuncyyF", + "moduleName": "cake", + "declAttributes": [ + "AlwaysEmitIntoClient" + ], + "funcSelfKind": "NonMutating" + }, + { + "kind": "Function", + "name": "silgenNamedFunc", + "printedName": "silgenNamedFunc()", + "children": [ + { + "kind": "TypeNominal", + "name": "Void", + "printedName": "()" + } + ], + "declKind": "Func", + "usr": "s:4cake15silgenNamedFuncyyF", + "mangledName": "silgenName", + "moduleName": "cake", + "declAttributes": [ + "SILGenName" + ], + "funcSelfKind": "NonMutating" + }, + { + "kind": "TypeDecl", + "name": "SinkingClass", + "printedName": "SinkingClass", + "children": [ + { + "kind": "Constructor", + "name": "init", + "printedName": "init()", + "children": [ + { + "kind": "TypeNominal", + "name": "SinkingClass", + "printedName": "Bread.SinkingClass", + "usr": "s:4cake12SinkingClassC" + } + ], + "declKind": "Constructor", + "usr": "s:4cake12SinkingClassCACycfc", + "mangledName": "$s5Bread12SinkingClassCACycfc", + "moduleName": "cake", + "spi_group_names": [ + "top_secret_2", + "top_secret_1" + ], + "init_kind": "Designated" + } + ], + "declKind": "Class", + "usr": "s:4cake12SinkingClassC", + "mangledName": "$s5Bread12SinkingClassC", + "moduleName": "cake", + "intro_Macosx": "10.7", + "declAttributes": [ + "SPIAccessControl", + "SPIAccessControl", + "OriginallyDefinedIn", + "Available" + ], + "spi_group_names": [ + "top_secret_2", + "top_secret_1" + ], + "conformances": [ + { + "kind": "Conformance", + "name": "Copyable", + "printedName": "Copyable", + "usr": "s:s8CopyableP", + "mangledName": "$ss8CopyableP" + }, + { + "kind": "Conformance", + "name": "Escapable", + "printedName": "Escapable", + "usr": "s:s9EscapableP", + "mangledName": "$ss9EscapableP" + } + ] + }, + { + "kind": "TypeDecl", + "name": "Int", + "printedName": "Int", + "children": [ + { + "kind": "Function", + "name": "foo", + "printedName": "foo()", + "children": [ + { + "kind": "TypeNominal", + "name": "Void", + "printedName": "()" + } + ], + "declKind": "Func", + "usr": "s:Si4cakeE3fooyyF", + "mangledName": "$sSi4cakeE3fooyyF", + "moduleName": "cake", + "isFromExtension": true, + "funcSelfKind": "NonMutating" + }, + { + "kind": "Function", + "name": "bar", + "printedName": "bar()", + "children": [ + { + "kind": "TypeNominal", + "name": "Void", + "printedName": "()" + } + ], + "declKind": "Func", + "usr": "s:Si4cakeE3baryyF", + "mangledName": "$sSi4cakeE3baryyF", + "moduleName": "cake", + "isFromExtension": true, + "funcSelfKind": "NonMutating" + } + ], + "declKind": "Struct", + "usr": "s:Si", + "mangledName": "$sSi", + "moduleName": "Swift", + "declAttributes": [ + "Frozen" + ], + "isExternal": true, + "conformances": [ + { + "kind": "Conformance", + "name": "FixedWidthInteger", + "printedName": "FixedWidthInteger", + "usr": "s:s17FixedWidthIntegerP", + "mangledName": "$ss17FixedWidthIntegerP" + }, + { + "kind": "Conformance", + "name": "SignedInteger", + "printedName": "SignedInteger", + "usr": "s:SZ", + "mangledName": "$sSZ" + }, + { + "kind": "Conformance", + "name": "BinaryInteger", + "printedName": "BinaryInteger", + "children": [ + { + "kind": "TypeWitness", + "name": "Words", + "printedName": "Words", + "children": [ + { + "kind": "TypeNominal", + "name": "Words", + "printedName": "Swift.Int.Words", + "usr": "s:Si5WordsV" + } + ] + } + ], + "usr": "s:Sz", + "mangledName": "$sSz" + }, + { + "kind": "Conformance", + "name": "LosslessStringConvertible", + "printedName": "LosslessStringConvertible", + "usr": "s:s25LosslessStringConvertibleP", + "mangledName": "$ss25LosslessStringConvertibleP" + }, + { + "kind": "Conformance", + "name": "SignedNumeric", + "printedName": "SignedNumeric", + "usr": "s:s13SignedNumericP", + "mangledName": "$ss13SignedNumericP" + }, + { + "kind": "Conformance", + "name": "Numeric", + "printedName": "Numeric", + "children": [ + { + "kind": "TypeWitness", + "name": "Magnitude", + "printedName": "Magnitude", + "children": [ + { + "kind": "TypeNameAlias", + "name": "Magnitude", + "printedName": "Swift.Int.Magnitude", + "children": [ + { + "kind": "TypeNominal", + "name": "UInt", + "printedName": "Swift.UInt", + "usr": "s:Su" + } + ] + } + ] + } + ], + "usr": "s:Sj", + "mangledName": "$sSj" + }, + { + "kind": "Conformance", + "name": "CustomStringConvertible", + "printedName": "CustomStringConvertible", + "usr": "s:s23CustomStringConvertibleP", + "mangledName": "$ss23CustomStringConvertibleP" + }, + { + "kind": "Conformance", + "name": "Strideable", + "printedName": "Strideable", + "children": [ + { + "kind": "TypeWitness", + "name": "Stride", + "printedName": "Stride", + "children": [ + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + } + ] + } + ], + "usr": "s:Sx", + "mangledName": "$sSx" + }, + { + "kind": "Conformance", + "name": "AdditiveArithmetic", + "printedName": "AdditiveArithmetic", + "usr": "s:s18AdditiveArithmeticP", + "mangledName": "$ss18AdditiveArithmeticP" + }, + { + "kind": "Conformance", + "name": "ExpressibleByIntegerLiteral", + "printedName": "ExpressibleByIntegerLiteral", + "children": [ + { + "kind": "TypeWitness", + "name": "IntegerLiteralType", + "printedName": "IntegerLiteralType", + "children": [ + { + "kind": "TypeNameAlias", + "name": "IntegerLiteralType", + "printedName": "Swift.Int.IntegerLiteralType", + "children": [ + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + } + ] + } + ] + } + ], + "usr": "s:s27ExpressibleByIntegerLiteralP", + "mangledName": "$ss27ExpressibleByIntegerLiteralP" + }, + { + "kind": "Conformance", + "name": "Comparable", + "printedName": "Comparable", + "usr": "s:SL", + "mangledName": "$sSL" + }, + { + "kind": "Conformance", + "name": "Copyable", + "printedName": "Copyable", + "usr": "s:s8CopyableP", + "mangledName": "$ss8CopyableP" + }, + { + "kind": "Conformance", + "name": "Escapable", + "printedName": "Escapable", + "usr": "s:s9EscapableP", + "mangledName": "$ss9EscapableP" + }, + { + "kind": "Conformance", + "name": "P1", + "printedName": "P1", + "usr": "s:4cake2P1P", + "mangledName": "$s4cake2P1P" + }, + { + "kind": "Conformance", + "name": "Encodable", + "printedName": "Encodable", + "usr": "s:SE", + "mangledName": "$sSE" + }, + { + "kind": "Conformance", + "name": "Decodable", + "printedName": "Decodable", + "usr": "s:Se", + "mangledName": "$sSe" + }, + { + "kind": "Conformance", + "name": "CodingKeyRepresentable", + "printedName": "CodingKeyRepresentable", + "usr": "s:s22CodingKeyRepresentableP", + "mangledName": "$ss22CodingKeyRepresentableP" + }, + { + "kind": "Conformance", + "name": "CustomReflectable", + "printedName": "CustomReflectable", + "usr": "s:s17CustomReflectableP", + "mangledName": "$ss17CustomReflectableP" + }, + { + "kind": "Conformance", + "name": "MirrorPath", + "printedName": "MirrorPath", + "usr": "s:s10MirrorPathP", + "mangledName": "$ss10MirrorPathP" + }, + { + "kind": "Conformance", + "name": "CVarArg", + "printedName": "CVarArg", + "usr": "s:s7CVarArgP", + "mangledName": "$ss7CVarArgP" + }, + { + "kind": "Conformance", + "name": "Hashable", + "printedName": "Hashable", + "usr": "s:SH", + "mangledName": "$sSH" + }, + { + "kind": "Conformance", + "name": "Equatable", + "printedName": "Equatable", + "usr": "s:SQ", + "mangledName": "$sSQ" + }, + { + "kind": "Conformance", + "name": "Sendable", + "printedName": "Sendable", + "usr": "s:s8SendableP", + "mangledName": "$ss8SendableP" + }, + { + "kind": "Conformance", + "name": "SendableMetatype", + "printedName": "SendableMetatype", + "usr": "s:s16SendableMetatypeP", + "mangledName": "$ss16SendableMetatypeP" + }, + { + "kind": "Conformance", + "name": "SIMDScalar", + "printedName": "SIMDScalar", + "children": [ + { + "kind": "TypeWitness", + "name": "SIMDMaskScalar", + "printedName": "SIMDMaskScalar", + "children": [ + { + "kind": "TypeNameAlias", + "name": "SIMDMaskScalar", + "printedName": "Swift.Int.SIMDMaskScalar", + "children": [ + { + "kind": "TypeNominal", + "name": "Int", + "printedName": "Swift.Int", + "usr": "s:Si" + } + ] + } + ] + }, + { + "kind": "TypeWitness", + "name": "SIMD2Storage", + "printedName": "SIMD2Storage", + "children": [ + { + "kind": "TypeNominal", + "name": "SIMD2Storage", + "printedName": "Swift.Int.SIMD2Storage", + "usr": "s:Si12SIMD2StorageV" + } + ] + }, + { + "kind": "TypeWitness", + "name": "SIMD4Storage", + "printedName": "SIMD4Storage", + "children": [ + { + "kind": "TypeNominal", + "name": "SIMD4Storage", + "printedName": "Swift.Int.SIMD4Storage", + "usr": "s:Si12SIMD4StorageV" + } + ] + }, + { + "kind": "TypeWitness", + "name": "SIMD8Storage", + "printedName": "SIMD8Storage", + "children": [ + { + "kind": "TypeNominal", + "name": "SIMD8Storage", + "printedName": "Swift.Int.SIMD8Storage", + "usr": "s:Si12SIMD8StorageV" + } + ] + }, + { + "kind": "TypeWitness", + "name": "SIMD16Storage", + "printedName": "SIMD16Storage", + "children": [ + { + "kind": "TypeNominal", + "name": "SIMD16Storage", + "printedName": "Swift.Int.SIMD16Storage", + "usr": "s:Si13SIMD16StorageV" + } + ] + }, + { + "kind": "TypeWitness", + "name": "SIMD32Storage", + "printedName": "SIMD32Storage", + "children": [ + { + "kind": "TypeNominal", + "name": "SIMD32Storage", + "printedName": "Swift.Int.SIMD32Storage", + "usr": "s:Si13SIMD32StorageV" + } + ] + }, + { + "kind": "TypeWitness", + "name": "SIMD64Storage", + "printedName": "SIMD64Storage", + "children": [ + { + "kind": "TypeNominal", + "name": "SIMD64Storage", + "printedName": "Swift.Int.SIMD64Storage", + "usr": "s:Si13SIMD64StorageV" + } + ] + } + ], + "usr": "s:s10SIMDScalarP", + "mangledName": "$ss10SIMDScalarP" + }, + { + "kind": "Conformance", + "name": "BitwiseCopyable", + "printedName": "BitwiseCopyable", + "usr": "s:s15BitwiseCopyableP", + "mangledName": "$ss15BitwiseCopyableP" + } + ] + } + ], + "json_format_version": 8 + } +} \ No newline at end of file diff --git a/test/api-digester/dump-module.swift b/test/api-digester/dump-module.swift index 9f37802413831..d76a056961bad 100644 --- a/test/api-digester/dump-module.swift +++ b/test/api-digester/dump-module.swift @@ -1,19 +1,28 @@ // REQUIRES: OS=macosx + // RUN: %empty-directory(%t.mod) // RUN: %empty-directory(%t.sdk) // RUN: %empty-directory(%t.module-cache) + +// There is a difference in the order of conformances between x86_64 and arm64. +// See https://github.com/swiftlang/swift/pull/84193 for context. +// RUN: expected_sdk="%S/Outputs/dump-module/cake-%target-cpu.json" +// RUN: expected_sdk_abi="%S/Outputs/dump-module/cake-abi-%target-cpu.json" + // RUN: %target-swift-frontend -disable-objc-attr-requires-foundation-module -emit-module -o %t.mod/cake.swiftmodule %S/Inputs/cake.swift -parse-as-library -I %S/Inputs/ClangCake %clang-importer-sdk-nosource + // RUN: %api-digester -dump-sdk -module cake -o %t.dump.json -module-cache-path %t.module-cache -swift-only -I %t.mod -I %S/Inputs/ClangCake %clang-importer-sdk-nosource -avoid-tool-args -// RUN: diff -u %S/Outputs/cake.json %t.dump.json +// RUN: diff -u $expected_sdk %t.dump.json // RUN: %api-digester -dump-sdk -module cake -o %t.dump.json -module-cache-path %t.module-cache -swift-only -I %t.mod -abi -I %S/Inputs/ClangCake %clang-importer-sdk-nosource -avoid-tool-args -// RUN: diff -u %S/Outputs/cake-abi.json %t.dump.json -// RUN: %api-digester -diagnose-sdk --input-paths %t.dump.json -input-paths %S/Outputs/cake.json +// RUN: diff -u $expected_sdk_abi %t.dump.json + +// RUN: %api-digester -diagnose-sdk --input-paths %t.dump.json -input-paths $expected_sdk // Round-trip testing: -// RUN: %api-digester -deserialize-sdk --input-paths %S/Outputs/cake.json -o %t.dump.json -// RUN: diff -u %S/Outputs/cake.json %t.dump.json -// RUN: %api-digester -deserialize-sdk --input-paths %S/Outputs/cake-abi.json -o %t.dump.json -// RUN: diff -u %S/Outputs/cake-abi.json %t.dump.json +// RUN: %api-digester -deserialize-sdk --input-paths $expected_sdk -o %t.dump.json +// RUN: diff -u $expected_sdk %t.dump.json +// RUN: %api-digester -deserialize-sdk --input-paths $expected_sdk_abi -o %t.dump.json +// RUN: diff -u $expected_sdk_abi %t.dump.json // The input JSON files need to be modified when standard library declarations // are reordered. This is expected behavior and we simply shouldn't run the test