diff --git a/.bazelrc b/.bazelrc index 8d740e94..7b176567 100644 --- a/.bazelrc +++ b/.bazelrc @@ -3,3 +3,4 @@ build --macos_minimum_os=12 build --repo_env=CC=clang test --test_output=errors test --spawn_strategy=standalone +test --macos_minimum_os=13 diff --git a/.github/workflows/xcodebuild.yml b/.github/workflows/xcodebuild.yml index bbbb35ea..1829e2c0 100644 --- a/.github/workflows/xcodebuild.yml +++ b/.github/workflows/xcodebuild.yml @@ -18,4 +18,4 @@ jobs: with: xcode-version: ${{ matrix.xcode_version }} - run: xcodebuild -version - - run: xcodebuild -scheme sourcekitten -parallel-testing-enabled NO test -destination platform=macOS + - run: xcodebuild -scheme SourceKitten-Package -parallel-testing-enabled NO test -destination platform=macOS diff --git a/Source/SourceKittenFramework/SwiftDeclarationAttributeKind.swift b/Source/SourceKittenFramework/SwiftDeclarationAttributeKind.swift index 24385526..0b06623e 100644 --- a/Source/SourceKittenFramework/SwiftDeclarationAttributeKind.swift +++ b/Source/SourceKittenFramework/SwiftDeclarationAttributeKind.swift @@ -201,4 +201,18 @@ public enum SwiftDeclarationAttributeKind: String, CaseIterable { case _rawLayout = "source.decl.attribute._rawLayout" case _section = "source.decl.attribute._section" case _used = "source.decl.attribute._used" + + // Only available in Swift >= 6.0 + case _extern = "source.decl.attribute._extern" + case _resultDependsOnSelf = "source.decl.attribute._resultDependsOnSelf" + case _preInverseGenerics = "source.decl.attribute._preInverseGenerics" + case implementation = "source.decl.attribute.implementation" + case _allowFeatureSuppression = "source.decl.attribute._allowFeatureSuppression" + case _noRuntime = "source.decl.attribute._noRuntime" + case _staticExclusiveOnly = "source.decl.attribute._staticExclusiveOnly" + case extractConstantsFromMembers = "source.decl.attribute.extractConstantsFromMembers" + case _unsafeNonescapableResult = "source.decl.attribute._unsafeNonescapableResult" + case _noExistentials = "source.decl.attribute._noExistentials" + case _noObjCBridging = "source.decl.attribute._noObjCBridging" + case _nonescapable = "source.decl.attribute._nonescapable" } diff --git a/Tests/SourceKittenFrameworkTests/Fixtures/Bicycle@swift-6.0.json b/Tests/SourceKittenFrameworkTests/Fixtures/Bicycle@swift-6.0.json new file mode 100644 index 00000000..8cedaa3c --- /dev/null +++ b/Tests/SourceKittenFrameworkTests/Fixtures/Bicycle@swift-6.0.json @@ -0,0 +1,888 @@ +{ + "Bicycle.swift" : { + "key.diagnostic_stage" : "source.diagnostic.stage.swift.parse", + "key.length" : 2472, + "key.offset" : 0, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "@_nonSendable(_assumed) class NSString : NSObject<\/Type>, NSCopying<\/Type>, NSMutableCopying<\/Type>, NSSecureCoding<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 134 + }, + { + "key.attribute" : "source.decl.attribute.available", + "key.length" : 88, + "key.offset" : 45 + } + ], + "key.bodylength" : 0, + "key.bodyoffset" : 161, + "key.column" : 12, + "key.decl_lang" : "source.lang.objc", + "key.doc.comment" : "Deprecated extension.", + "key.doclength" : 26, + "key.docoffset" : 19, + "key.filepath" : "", + "key.fully_annotated_decl" : "@_nonSendable(_assumed)<\/syntaxtype.attribute.name><\/syntaxtype.attribute.builtin> class<\/syntaxtype.keyword> NSString<\/decl.name> : NSObject<\/ref.class>, NSCopying<\/ref.protocol>, NSMutableCopying<\/ref.protocol>, NSSecureCoding<\/ref.protocol><\/decl.class>", + "key.is_system" : true, + "key.kind" : "source.lang.swift.decl.extension", + "key.length" : 21, + "key.line" : 103, + "key.modulename" : "Foundation.NSString", + "key.name" : "NSString", + "key.namelength" : 8, + "key.nameoffset" : 151, + "key.offset" : 141, + "key.parsed_declaration" : "public extension NSString", + "key.parsed_scope.end" : 5, + "key.parsed_scope.start" : 5, + "key.reusingastcontext" : false, + "key.typename" : "NSString.Type", + "key.typeusr" : "$sSo8NSStringCmD", + "key.usr" : "c:objc(cs)NSString" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public class Bicycle<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 226 + } + ], + "key.bodylength" : 2222, + "key.bodyoffset" : 248, + "key.column" : 14, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "🚲 A two-wheeled, human-powered mode of transportation.", + "key.doc.column" : 14, + "key.doc.comment" : "🚲 A two-wheeled, human-powered mode of transportation.", + "key.doc.declaration" : "public class Bicycle", + "key.doc.file" : "Bicycle.swift", + "key.doc.full_as_xml" : "Bicycle<\/Name>s:7BicycleAAC<\/USR>public class Bicycle<\/Declaration>🚲 A two-wheeled, human-powered mode of transportation.<\/Para><\/Abstract><\/CommentParts><\/Class>", + "key.doc.line" : 8, + "key.doc.name" : "Bicycle", + "key.doc.type" : "Class", + "key.doclength" : 62, + "key.docoffset" : 164, + "key.filepath" : "Bicycle.swift", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> class<\/syntaxtype.keyword> Bicycle<\/decl.name><\/decl.class>", + "key.kind" : "source.lang.swift.decl.class", + "key.length" : 2238, + "key.line" : 8, + "key.modulename" : "Bicycle", + "key.name" : "Bicycle", + "key.namelength" : 7, + "key.nameoffset" : 239, + "key.offset" : 233, + "key.parsed_declaration" : "public class Bicycle", + "key.parsed_scope.end" : 93, + "key.parsed_scope.start" : 8, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public enum Bicycle<\/Type>.Style<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 473 + } + ], + "key.bodylength" : 49, + "key.bodyoffset" : 492, + "key.column" : 17, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Frame and construction style.\n\n- Road: For streets or trails.\n- Touring: For long journeys.\n- Cruiser: For casual trips around town.\n- Hybrid: For general-purpose transportation.\n", + "key.doc.column" : 17, + "key.doc.comment" : "Frame and construction style.\n\n- Road: For streets or trails.\n- Touring: For long journeys.\n- Cruiser: For casual trips around town.\n- Hybrid: For general-purpose transportation.", + "key.doc.declaration" : "public enum Bicycle.Bicycle.Style", + "key.doc.discussion" : [ + { + "List-Bullet" : "" + } + ], + "key.doc.file" : "Bicycle.swift", + "key.doc.full_as_xml" : "Style<\/Name>s:7BicycleAAC5StyleO<\/USR>public enum Bicycle.Bicycle.Style<\/Declaration>Frame and construction style.<\/Para><\/Abstract>Road: For streets or trails.<\/Para><\/Item>Touring: For long journeys.<\/Para><\/Item>Cruiser: For casual trips around town.<\/Para><\/Item>Hybrid: For general-purpose transportation.<\/Para><\/Item><\/List-Bullet><\/Discussion><\/CommentParts><\/Other>", + "key.doc.line" : 17, + "key.doc.name" : "Style", + "key.doc.type" : "Other", + "key.doclength" : 215, + "key.docoffset" : 253, + "key.filepath" : "Bicycle.swift", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> enum<\/syntaxtype.keyword> Bicycle<\/ref.class>.Style<\/decl.name><\/decl.enum>", + "key.is_dynamic" : true, + "key.kind" : "source.lang.swift.decl.enum", + "key.length" : 62, + "key.line" : 17, + "key.modulename" : "Bicycle", + "key.name" : "Style", + "key.namelength" : 5, + "key.nameoffset" : 485, + "key.offset" : 480, + "key.parsed_declaration" : "public enum Style", + "key.parsed_scope.end" : 19, + "key.parsed_scope.start" : 17, + "key.receivers" : [ + { + "key.usr" : "s:7BicycleAAC" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.kind" : "source.lang.swift.decl.enumcase", + "key.length" : 35, + "key.offset" : 501, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "case Road<\/Declaration>", + "key.column" : 14, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "Bicycle.swift", + "key.fully_annotated_decl" : "case<\/syntaxtype.keyword> Road<\/decl.name><\/decl.enumelement>", + "key.kind" : "source.lang.swift.decl.enumelement", + "key.length" : 4, + "key.line" : 18, + "key.modulename" : "Bicycle", + "key.name" : "Road", + "key.namelength" : 4, + "key.nameoffset" : 506, + "key.offset" : 506, + "key.parsed_declaration" : "case Road", + "key.parsed_scope.end" : 18, + "key.parsed_scope.start" : 18, + "key.reusingastcontext" : false, + "key.typename" : "(Bicycle.Style.Type) -> Bicycle.Style", + "key.typeusr" : "$sy7BicycleAAC5StyleOADmcD", + "key.usr" : "s:7BicycleAAC5StyleO4RoadyA2DmF" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "case Touring<\/Declaration>", + "key.column" : 20, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "Bicycle.swift", + "key.fully_annotated_decl" : "case<\/syntaxtype.keyword> Touring<\/decl.name><\/decl.enumelement>", + "key.kind" : "source.lang.swift.decl.enumelement", + "key.length" : 7, + "key.line" : 18, + "key.modulename" : "Bicycle", + "key.name" : "Touring", + "key.namelength" : 7, + "key.nameoffset" : 512, + "key.offset" : 512, + "key.parsed_declaration" : "case Road, Touring", + "key.parsed_scope.end" : 18, + "key.parsed_scope.start" : 18, + "key.reusingastcontext" : false, + "key.typename" : "(Bicycle.Style.Type) -> Bicycle.Style", + "key.typeusr" : "$sy7BicycleAAC5StyleOADmcD", + "key.usr" : "s:7BicycleAAC5StyleO7TouringyA2DmF" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "case Cruiser<\/Declaration>", + "key.column" : 29, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "Bicycle.swift", + "key.fully_annotated_decl" : "case<\/syntaxtype.keyword> Cruiser<\/decl.name><\/decl.enumelement>", + "key.kind" : "source.lang.swift.decl.enumelement", + "key.length" : 7, + "key.line" : 18, + "key.modulename" : "Bicycle", + "key.name" : "Cruiser", + "key.namelength" : 7, + "key.nameoffset" : 521, + "key.offset" : 521, + "key.parsed_declaration" : "case Road, Touring, Cruiser", + "key.parsed_scope.end" : 18, + "key.parsed_scope.start" : 18, + "key.reusingastcontext" : false, + "key.typename" : "(Bicycle.Style.Type) -> Bicycle.Style", + "key.typeusr" : "$sy7BicycleAAC5StyleOADmcD", + "key.usr" : "s:7BicycleAAC5StyleO7CruiseryA2DmF" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "case Hybrid<\/Declaration>", + "key.column" : 38, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "Bicycle.swift", + "key.fully_annotated_decl" : "case<\/syntaxtype.keyword> Hybrid<\/decl.name><\/decl.enumelement>", + "key.kind" : "source.lang.swift.decl.enumelement", + "key.length" : 6, + "key.line" : 18, + "key.modulename" : "Bicycle", + "key.name" : "Hybrid", + "key.namelength" : 6, + "key.nameoffset" : 530, + "key.offset" : 530, + "key.parsed_declaration" : "case Road, Touring, Cruiser, Hybrid", + "key.parsed_scope.end" : 18, + "key.parsed_scope.start" : 18, + "key.reusingastcontext" : false, + "key.typename" : "(Bicycle.Style.Type) -> Bicycle.Style", + "key.typeusr" : "$sy7BicycleAAC5StyleOADmcD", + "key.usr" : "s:7BicycleAAC5StyleO6HybridyA2DmF" + } + ] + } + ], + "key.typename" : "Bicycle.Style.Type", + "key.typeusr" : "$s7BicycleAAC5StyleOmD", + "key.usr" : "s:7BicycleAAC5StyleO" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public enum Bicycle<\/Type>.Gearing<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 712 + } + ], + "key.bodylength" : 60, + "key.bodyoffset" : 733, + "key.column" : 17, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Mechanism for converting pedal power into motion.\n\n- Fixed: A single, fixed gear.\n- Freewheel: A variable-speed, disengageable gear.\n", + "key.doc.column" : 17, + "key.doc.comment" : "Mechanism for converting pedal power into motion.\n\n- Fixed: A single, fixed gear.\n- Freewheel: A variable-speed, disengageable gear.", + "key.doc.declaration" : "public enum Bicycle.Bicycle.Gearing", + "key.doc.discussion" : [ + { + "List-Bullet" : "" + } + ], + "key.doc.file" : "Bicycle.swift", + "key.doc.full_as_xml" : "Gearing<\/Name>s:7BicycleAAC7GearingO<\/USR>public enum Bicycle.Bicycle.Gearing<\/Declaration>Mechanism for converting pedal power into motion.<\/Para><\/Abstract>Fixed: A single, fixed gear.<\/Para><\/Item>Freewheel: A variable-speed, disengageable gear.<\/Para><\/Item><\/List-Bullet><\/Discussion><\/CommentParts><\/Other>", + "key.doc.line" : 27, + "key.doc.name" : "Gearing", + "key.doc.type" : "Other", + "key.doclength" : 159, + "key.docoffset" : 548, + "key.filepath" : "Bicycle.swift", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> enum<\/syntaxtype.keyword> Bicycle<\/ref.class>.Gearing<\/decl.name><\/decl.enum>", + "key.is_dynamic" : true, + "key.kind" : "source.lang.swift.decl.enum", + "key.length" : 75, + "key.line" : 27, + "key.modulename" : "Bicycle", + "key.name" : "Gearing", + "key.namelength" : 7, + "key.nameoffset" : 724, + "key.offset" : 719, + "key.parsed_declaration" : "public enum Gearing", + "key.parsed_scope.end" : 30, + "key.parsed_scope.start" : 27, + "key.receivers" : [ + { + "key.usr" : "s:7BicycleAAC" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.kind" : "source.lang.swift.decl.enumcase", + "key.length" : 10, + "key.offset" : 742, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "case Fixed<\/Declaration>", + "key.column" : 14, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "Bicycle.swift", + "key.fully_annotated_decl" : "case<\/syntaxtype.keyword> Fixed<\/decl.name><\/decl.enumelement>", + "key.kind" : "source.lang.swift.decl.enumelement", + "key.length" : 5, + "key.line" : 28, + "key.modulename" : "Bicycle", + "key.name" : "Fixed", + "key.namelength" : 5, + "key.nameoffset" : 747, + "key.offset" : 747, + "key.parsed_declaration" : "case Fixed", + "key.parsed_scope.end" : 28, + "key.parsed_scope.start" : 28, + "key.reusingastcontext" : false, + "key.typename" : "(Bicycle.Gearing.Type) -> Bicycle.Gearing", + "key.typeusr" : "$sy7BicycleAAC7GearingOADmcD", + "key.usr" : "s:7BicycleAAC7GearingO5FixedyA2DmF" + } + ] + }, + { + "key.kind" : "source.lang.swift.decl.enumcase", + "key.length" : 27, + "key.offset" : 761, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "case Freewheel(speeds: Int<\/Type>)<\/Declaration>", + "key.column" : 14, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "Bicycle.swift", + "key.fully_annotated_decl" : "case<\/syntaxtype.keyword> Freewheel<\/decl.name>(speeds<\/decl.var.parameter.argument_label>: Int<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>)<\/decl.enumelement>", + "key.kind" : "source.lang.swift.decl.enumelement", + "key.length" : 22, + "key.line" : 29, + "key.modulename" : "Bicycle", + "key.name" : "Freewheel(speeds:)", + "key.namelength" : 22, + "key.nameoffset" : 766, + "key.offset" : 766, + "key.parsed_declaration" : "case Freewheel(speeds: Int)", + "key.parsed_scope.end" : 29, + "key.parsed_scope.start" : 29, + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : "(Bicycle.Gearing.Type) -> (Int) -> Bicycle.Gearing", + "key.typeusr" : "$sy7BicycleAAC7GearingOSi_tcADmcD", + "key.usr" : "s:7BicycleAAC7GearingO9FreewheelyADSi_tcADmF" + } + ] + } + ], + "key.typename" : "Bicycle.Gearing.Type", + "key.typeusr" : "$s7BicycleAAC7GearingOmD", + "key.usr" : "s:7BicycleAAC7GearingO" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "enum Bicycle<\/Type>.Handlebar<\/Declaration>", + "key.bodylength" : 47, + "key.bodyoffset" : 1009, + "key.column" : 10, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Hardware used for steering.\n\n- Riser: A casual handlebar.\n- Café: An upright handlebar.\n- Drop: A classic handlebar.\n- Bullhorn: A powerful handlebar.\n", + "key.doc.column" : 10, + "key.doc.comment" : "Hardware used for steering.\n\n- Riser: A casual handlebar.\n- Café: An upright handlebar.\n- Drop: A classic handlebar.\n- Bullhorn: A powerful handlebar.", + "key.doc.declaration" : "enum Bicycle.Bicycle.Handlebar", + "key.doc.discussion" : [ + { + "List-Bullet" : "" + } + ], + "key.doc.file" : "Bicycle.swift", + "key.doc.full_as_xml" : "Handlebar<\/Name>s:7BicycleAAC9HandlebarO<\/USR>enum Bicycle.Bicycle.Handlebar<\/Declaration>Hardware used for steering.<\/Para><\/Abstract>Riser: A casual handlebar.<\/Para><\/Item>Café: An upright handlebar.<\/Para><\/Item>Drop: A classic handlebar.<\/Para><\/Item>Bullhorn: A powerful handlebar.<\/Para><\/Item><\/List-Bullet><\/Discussion><\/CommentParts><\/Other>", + "key.doc.line" : 40, + "key.doc.name" : "Handlebar", + "key.doc.type" : "Other", + "key.doclength" : 188, + "key.docoffset" : 800, + "key.filepath" : "Bicycle.swift", + "key.fully_annotated_decl" : "enum<\/syntaxtype.keyword> Bicycle<\/ref.class>.Handlebar<\/decl.name><\/decl.enum>", + "key.is_dynamic" : true, + "key.kind" : "source.lang.swift.decl.enum", + "key.length" : 64, + "key.line" : 40, + "key.modulename" : "Bicycle", + "key.name" : "Handlebar", + "key.namelength" : 9, + "key.nameoffset" : 998, + "key.offset" : 993, + "key.parsed_declaration" : "enum Handlebar", + "key.parsed_scope.end" : 42, + "key.parsed_scope.start" : 40, + "key.receivers" : [ + { + "key.usr" : "s:7BicycleAAC" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.kind" : "source.lang.swift.decl.enumcase", + "key.length" : 33, + "key.offset" : 1018, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "case Riser<\/Declaration>", + "key.column" : 14, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "Bicycle.swift", + "key.fully_annotated_decl" : "case<\/syntaxtype.keyword> Riser<\/decl.name><\/decl.enumelement>", + "key.kind" : "source.lang.swift.decl.enumelement", + "key.length" : 5, + "key.line" : 41, + "key.modulename" : "Bicycle", + "key.name" : "Riser", + "key.namelength" : 5, + "key.nameoffset" : 1023, + "key.offset" : 1023, + "key.parsed_declaration" : "case Riser", + "key.parsed_scope.end" : 41, + "key.parsed_scope.start" : 41, + "key.reusingastcontext" : false, + "key.typename" : "(Bicycle.Handlebar.Type) -> Bicycle.Handlebar", + "key.typeusr" : "$sy7BicycleAAC9HandlebarOADmcD", + "key.usr" : "s:7BicycleAAC9HandlebarO5RiseryA2DmF" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "case Café<\/Declaration>", + "key.column" : 21, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "Bicycle.swift", + "key.fully_annotated_decl" : "case<\/syntaxtype.keyword> Café<\/decl.name><\/decl.enumelement>", + "key.kind" : "source.lang.swift.decl.enumelement", + "key.length" : 5, + "key.line" : 41, + "key.modulename" : "Bicycle", + "key.name" : "Café", + "key.namelength" : 5, + "key.nameoffset" : 1030, + "key.offset" : 1030, + "key.parsed_declaration" : "case Riser, Café", + "key.parsed_scope.end" : 41, + "key.parsed_scope.start" : 41, + "key.reusingastcontext" : false, + "key.typename" : "(Bicycle.Handlebar.Type) -> Bicycle.Handlebar", + "key.typeusr" : "$sy7BicycleAAC9HandlebarOADmcD", + "key.usr" : "s:7BicycleAAC9HandlebarO007Caf_dmayA2DmF" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "case Drop<\/Declaration>", + "key.column" : 28, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "Bicycle.swift", + "key.fully_annotated_decl" : "case<\/syntaxtype.keyword> Drop<\/decl.name><\/decl.enumelement>", + "key.kind" : "source.lang.swift.decl.enumelement", + "key.length" : 4, + "key.line" : 41, + "key.modulename" : "Bicycle", + "key.name" : "Drop", + "key.namelength" : 4, + "key.nameoffset" : 1037, + "key.offset" : 1037, + "key.parsed_declaration" : "case Riser, Café, Drop", + "key.parsed_scope.end" : 41, + "key.parsed_scope.start" : 41, + "key.reusingastcontext" : false, + "key.typename" : "(Bicycle.Handlebar.Type) -> Bicycle.Handlebar", + "key.typeusr" : "$sy7BicycleAAC9HandlebarOADmcD", + "key.usr" : "s:7BicycleAAC9HandlebarO4DropyA2DmF" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "case Bullhorn<\/Declaration>", + "key.column" : 34, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "Bicycle.swift", + "key.fully_annotated_decl" : "case<\/syntaxtype.keyword> Bullhorn<\/decl.name><\/decl.enumelement>", + "key.kind" : "source.lang.swift.decl.enumelement", + "key.length" : 8, + "key.line" : 41, + "key.modulename" : "Bicycle", + "key.name" : "Bullhorn", + "key.namelength" : 8, + "key.nameoffset" : 1043, + "key.offset" : 1043, + "key.parsed_declaration" : "case Riser, Café, Drop, Bullhorn", + "key.parsed_scope.end" : 41, + "key.parsed_scope.start" : 41, + "key.reusingastcontext" : false, + "key.typename" : "(Bicycle.Handlebar.Type) -> Bicycle.Handlebar", + "key.typeusr" : "$sy7BicycleAAC9HandlebarOADmcD", + "key.usr" : "s:7BicycleAAC9HandlebarO8BullhornyA2DmF" + } + ] + } + ], + "key.typename" : "Bicycle.Handlebar.Type", + "key.typeusr" : "$s7BicycleAAC9HandlebarOmD", + "key.usr" : "s:7BicycleAAC9HandlebarO" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "let style: Style<\/Type><\/Declaration>", + "key.column" : 9, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "The style of the bicycle.", + "key.doc.column" : 9, + "key.doc.comment" : "The style of the bicycle.", + "key.doc.declaration" : "let style: Style", + "key.doc.file" : "Bicycle.swift", + "key.doc.full_as_xml" : "style<\/Name>s:7BicycleAAC5styleAB5StyleOvp<\/USR>let style: Style<\/Declaration>The style of the bicycle.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 45, + "key.doc.name" : "style", + "key.doc.type" : "Other", + "key.doclength" : 30, + "key.docoffset" : 1063, + "key.filepath" : "Bicycle.swift", + "key.fully_annotated_decl" : "let<\/syntaxtype.keyword> style<\/decl.name>: Style<\/ref.enum><\/decl.var.type><\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 16, + "key.line" : 45, + "key.modulename" : "Bicycle", + "key.name" : "style", + "key.namelength" : 5, + "key.nameoffset" : 1101, + "key.offset" : 1097, + "key.parsed_declaration" : "let style: Style", + "key.parsed_scope.end" : 45, + "key.parsed_scope.start" : 45, + "key.reusingastcontext" : false, + "key.typename" : "Bicycle.Style", + "key.typeusr" : "$s7BicycleAAC5StyleOD", + "key.usr" : "s:7BicycleAAC5styleAB5StyleOvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "let gearing: Gearing<\/Type><\/Declaration>", + "key.column" : 9, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "The gearing of the bicycle.", + "key.doc.column" : 9, + "key.doc.comment" : "The gearing of the bicycle.", + "key.doc.declaration" : "let gearing: Gearing", + "key.doc.file" : "Bicycle.swift", + "key.doc.full_as_xml" : "gearing<\/Name>s:7BicycleAAC7gearingAB7GearingOvp<\/USR>let gearing: Gearing<\/Declaration>The gearing of the bicycle.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 48, + "key.doc.name" : "gearing", + "key.doc.type" : "Other", + "key.doclength" : 32, + "key.docoffset" : 1119, + "key.filepath" : "Bicycle.swift", + "key.fully_annotated_decl" : "let<\/syntaxtype.keyword> gearing<\/decl.name>: Gearing<\/ref.enum><\/decl.var.type><\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 20, + "key.line" : 48, + "key.modulename" : "Bicycle", + "key.name" : "gearing", + "key.namelength" : 7, + "key.nameoffset" : 1159, + "key.offset" : 1155, + "key.parsed_declaration" : "let gearing: Gearing", + "key.parsed_scope.end" : 48, + "key.parsed_scope.start" : 48, + "key.reusingastcontext" : false, + "key.typename" : "Bicycle.Gearing", + "key.typeusr" : "$s7BicycleAAC7GearingOD", + "key.usr" : "s:7BicycleAAC7gearingAB7GearingOvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "let handlebar: Handlebar<\/Type><\/Declaration>", + "key.column" : 9, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "The handlebar of the bicycle.", + "key.doc.column" : 9, + "key.doc.comment" : "The handlebar of the bicycle.", + "key.doc.declaration" : "let handlebar: Handlebar", + "key.doc.file" : "Bicycle.swift", + "key.doc.full_as_xml" : "handlebar<\/Name>s:7BicycleAAC9handlebarAB9HandlebarOvp<\/USR>let handlebar: Handlebar<\/Declaration>The handlebar of the bicycle.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 51, + "key.doc.name" : "handlebar", + "key.doc.type" : "Other", + "key.doclength" : 34, + "key.docoffset" : 1181, + "key.filepath" : "Bicycle.swift", + "key.fully_annotated_decl" : "let<\/syntaxtype.keyword> handlebar<\/decl.name>: Handlebar<\/ref.enum><\/decl.var.type><\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 24, + "key.line" : 51, + "key.modulename" : "Bicycle", + "key.name" : "handlebar", + "key.namelength" : 9, + "key.nameoffset" : 1223, + "key.offset" : 1219, + "key.parsed_declaration" : "let handlebar: Handlebar", + "key.parsed_scope.end" : 51, + "key.parsed_scope.start" : 51, + "key.reusingastcontext" : false, + "key.typename" : "Bicycle.Handlebar", + "key.typeusr" : "$s7BicycleAAC9HandlebarOD", + "key.usr" : "s:7BicycleAAC9handlebarAB9HandlebarOvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "let frameSize: Int<\/Type><\/Declaration>", + "key.column" : 9, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "The size of the frame, in centimeters.", + "key.doc.column" : 9, + "key.doc.comment" : "The size of the frame, in centimeters.", + "key.doc.declaration" : "let frameSize: Int", + "key.doc.file" : "Bicycle.swift", + "key.doc.full_as_xml" : "frameSize<\/Name>s:7BicycleAAC9frameSizeSivp<\/USR>let frameSize: Int<\/Declaration>The size of the frame, in centimeters.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 54, + "key.doc.name" : "frameSize", + "key.doc.type" : "Other", + "key.doclength" : 43, + "key.docoffset" : 1249, + "key.filepath" : "Bicycle.swift", + "key.fully_annotated_decl" : "let<\/syntaxtype.keyword> frameSize<\/decl.name>: Int<\/ref.struct><\/decl.var.type><\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 18, + "key.line" : 54, + "key.modulename" : "Bicycle", + "key.name" : "frameSize", + "key.namelength" : 9, + "key.nameoffset" : 1300, + "key.offset" : 1296, + "key.parsed_declaration" : "let frameSize: Int", + "key.parsed_scope.end" : 54, + "key.parsed_scope.start" : 54, + "key.reusingastcontext" : false, + "key.typename" : "Int", + "key.typeusr" : "$sSiD", + "key.usr" : "s:7BicycleAAC9frameSizeSivp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "private(set) var numberOfTrips: Int<\/Type> { get }<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.setter_access.private", + "key.length" : 12, + "key.offset" : 1374 + } + ], + "key.column" : 22, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "The number of trips travelled by the bicycle.", + "key.doc.column" : 22, + "key.doc.comment" : "The number of trips travelled by the bicycle.", + "key.doc.declaration" : "private(set) var numberOfTrips: Int { get }", + "key.doc.file" : "Bicycle.swift", + "key.doc.full_as_xml" : "numberOfTrips<\/Name>s:7BicycleAAC13numberOfTripsSivp<\/USR>private(set) var numberOfTrips: Int { get }<\/Declaration>The number of trips travelled by the bicycle.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 57, + "key.doc.name" : "numberOfTrips", + "key.doc.type" : "Other", + "key.doclength" : 50, + "key.docoffset" : 1320, + "key.filepath" : "Bicycle.swift", + "key.fully_annotated_decl" : "private<\/syntaxtype.keyword>(set) var<\/syntaxtype.keyword> numberOfTrips<\/decl.name>: Int<\/ref.struct><\/decl.var.type> { get }<\/decl.var.instance>", + "key.is_dynamic" : true, + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 22, + "key.line" : 57, + "key.modulename" : "Bicycle", + "key.name" : "numberOfTrips", + "key.namelength" : 13, + "key.nameoffset" : 1391, + "key.offset" : 1387, + "key.parsed_declaration" : "private(set) var numberOfTrips: Int", + "key.parsed_scope.end" : 57, + "key.parsed_scope.start" : 57, + "key.receivers" : [ + { + "key.usr" : "s:7BicycleAAC" + } + ], + "key.reusingastcontext" : false, + "key.setter_accessibility" : "source.lang.swift.accessibility.private", + "key.typename" : "Int", + "key.typeusr" : "$sSiD", + "key.usr" : "s:7BicycleAAC13numberOfTripsSivp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "private(set) var distanceTravelled: Double<\/Type> { get }<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.setter_access.private", + "key.length" : 12, + "key.offset" : 1479 + } + ], + "key.column" : 22, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "The total distance travelled by the bicycle, in meters.", + "key.doc.column" : 22, + "key.doc.comment" : "The total distance travelled by the bicycle, in meters.", + "key.doc.declaration" : "private(set) var distanceTravelled: Double { get }", + "key.doc.file" : "Bicycle.swift", + "key.doc.full_as_xml" : "distanceTravelled<\/Name>s:7BicycleAAC17distanceTravelledSdvp<\/USR>private(set) var distanceTravelled: Double { get }<\/Declaration>The total distance travelled by the bicycle, in meters.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 60, + "key.doc.name" : "distanceTravelled", + "key.doc.type" : "Other", + "key.doclength" : 60, + "key.docoffset" : 1415, + "key.filepath" : "Bicycle.swift", + "key.fully_annotated_decl" : "private<\/syntaxtype.keyword>(set) var<\/syntaxtype.keyword> distanceTravelled<\/decl.name>: Double<\/ref.struct><\/decl.var.type> { get }<\/decl.var.instance>", + "key.is_dynamic" : true, + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 29, + "key.line" : 60, + "key.modulename" : "Bicycle", + "key.name" : "distanceTravelled", + "key.namelength" : 17, + "key.nameoffset" : 1496, + "key.offset" : 1492, + "key.parsed_declaration" : "private(set) var distanceTravelled: Double", + "key.parsed_scope.end" : 60, + "key.parsed_scope.start" : 60, + "key.receivers" : [ + { + "key.usr" : "s:7BicycleAAC" + } + ], + "key.reusingastcontext" : false, + "key.setter_accessibility" : "source.lang.swift.accessibility.private", + "key.typename" : "Double", + "key.typeusr" : "$sSdD", + "key.usr" : "s:7BicycleAAC17distanceTravelledSdvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "init(style: Style<\/Type>, gearing: Gearing<\/Type>, handlebar: Handlebar<\/Type>, frameSize centimeters: Int<\/Type>)<\/Declaration>", + "key.bodylength" : 192, + "key.bodyoffset" : 2010, + "key.column" : 5, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Initializes a new bicycle with the provided parts and specifications.\n\n- parameter style: The style of the bicycle\n- parameter gearing: The gearing of the bicycle\n- parameter handlebar: The handlebar of the bicycle\n- parameter centimeters: The frame size of the bicycle, in centimeters\n\n- returns: A beautiful, brand-new, custom built just for you.\n", + "key.doc.column" : 5, + "key.doc.comment" : "Initializes a new bicycle with the provided parts and specifications.\n\n- parameter style: The style of the bicycle\n- parameter gearing: The gearing of the bicycle\n- parameter handlebar: The handlebar of the bicycle\n- parameter centimeters: The frame size of the bicycle, in centimeters\n\n- returns: A beautiful, brand-new, custom built just for you.", + "key.doc.declaration" : "init(style: Style, gearing: Gearing, handlebar: Handlebar, frameSize centimeters: Int)", + "key.doc.file" : "Bicycle.swift", + "key.doc.full_as_xml" : "init(style:gearing:handlebar:frameSize:)<\/Name>s:7BicycleAAC5style7gearing9handlebar9frameSizeA2B5StyleO_AB7GearingOAB9HandlebarOSitcfc<\/USR>init(style: Style, gearing: Gearing, handlebar: Handlebar, frameSize centimeters: Int)<\/Declaration>Initializes a new bicycle with the provided parts and specifications.<\/Para><\/Abstract>style<\/Name>in<\/Direction>The style of the bicycle<\/Para><\/Discussion><\/Parameter>gearing<\/Name>in<\/Direction>The gearing of the bicycle<\/Para><\/Discussion><\/Parameter>handlebar<\/Name>in<\/Direction>The handlebar of the bicycle<\/Para><\/Discussion><\/Parameter>centimeters<\/Name>in<\/Direction>The frame size of the bicycle, in centimeters<\/Para><\/Discussion><\/Parameter><\/Parameters>A beautiful, brand-new, custom built just for you.<\/Para><\/ResultDiscussion><\/CommentParts><\/Function>", + "key.doc.line" : 72, + "key.doc.name" : "init(style:gearing:handlebar:frameSize:)", + "key.doc.parameters" : [ + { + "discussion" : [ + { + "Para" : "The style of the bicycle" + } + ], + "name" : "style" + }, + { + "discussion" : [ + { + "Para" : "The gearing of the bicycle" + } + ], + "name" : "gearing" + }, + { + "discussion" : [ + { + "Para" : "The handlebar of the bicycle" + } + ], + "name" : "handlebar" + }, + { + "discussion" : [ + { + "Para" : "The frame size of the bicycle, in centimeters" + } + ], + "name" : "centimeters" + } + ], + "key.doc.result_discussion" : [ + { + "Para" : "A beautiful, brand-new, custom built just for you." + } + ], + "key.doc.type" : "Function", + "key.doclength" : 390, + "key.docoffset" : 1527, + "key.filepath" : "Bicycle.swift", + "key.fully_annotated_decl" : "init<\/syntaxtype.keyword>(style<\/decl.var.parameter.argument_label>: Style<\/ref.enum><\/decl.var.parameter.type><\/decl.var.parameter>, gearing<\/decl.var.parameter.argument_label>: Gearing<\/ref.enum><\/decl.var.parameter.type><\/decl.var.parameter>, handlebar<\/decl.var.parameter.argument_label>: Handlebar<\/ref.enum><\/decl.var.parameter.type><\/decl.var.parameter>, frameSize<\/decl.var.parameter.argument_label> centimeters<\/decl.var.parameter.name>: Int<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>)<\/decl.function.constructor>", + "key.is_dynamic" : true, + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 281, + "key.line" : 72, + "key.modulename" : "Bicycle", + "key.name" : "init(style:gearing:handlebar:frameSize:)", + "key.namelength" : 86, + "key.nameoffset" : 1922, + "key.offset" : 1922, + "key.parsed_declaration" : "init(style: Style, gearing: Gearing, handlebar: Handlebar, frameSize centimeters: Int)", + "key.parsed_scope.end" : 80, + "key.parsed_scope.start" : 72, + "key.receivers" : [ + { + "key.usr" : "s:7BicycleAAC" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : "(Bicycle.Type) -> (Bicycle.Style, Bicycle.Gearing, Bicycle.Handlebar, Int) -> Bicycle", + "key.typeusr" : "$s5style7gearing9handlebar9frameSize7BicycleAECAF5StyleO_AF7GearingOAF9HandlebarOSitcD", + "key.usr" : "s:7BicycleAAC5style7gearing9handlebar9frameSizeA2B5StyleO_AB7GearingOAB9HandlebarOSitcfc" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "func travel(distance meters: Double<\/Type>)<\/Declaration>", + "key.bodylength" : 112, + "key.bodyoffset" : 2356, + "key.column" : 10, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Take a bike out for a spin.\n\n- parameter meters: The distance to travel in meters.\n", + "key.doc.column" : 10, + "key.doc.comment" : "Take a bike out for a spin.\n\n- parameter meters: The distance to travel in meters.", + "key.doc.declaration" : "func travel(distance meters: Double)", + "key.doc.file" : "Bicycle.swift", + "key.doc.full_as_xml" : "travel(distance:)<\/Name>s:7BicycleAAC6travel8distanceySd_tF<\/USR>func travel(distance meters: Double)<\/Declaration>Take a bike out for a spin.<\/Para><\/Abstract>meters<\/Name>in<\/Direction>The distance to travel in meters.<\/Para><\/Discussion><\/Parameter><\/Parameters><\/CommentParts><\/Function>", + "key.doc.line" : 87, + "key.doc.name" : "travel(distance:)", + "key.doc.parameters" : [ + { + "discussion" : [ + { + "Para" : "The distance to travel in meters." + } + ], + "name" : "meters" + } + ], + "key.doc.type" : "Function", + "key.doclength" : 104, + "key.docoffset" : 2209, + "key.filepath" : "Bicycle.swift", + "key.fully_annotated_decl" : "func<\/syntaxtype.keyword> travel<\/decl.name>(distance<\/decl.var.parameter.argument_label> meters<\/decl.var.parameter.name>: Double<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>)<\/decl.function.method.instance>", + "key.is_dynamic" : true, + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 151, + "key.line" : 87, + "key.modulename" : "Bicycle", + "key.name" : "travel(distance:)", + "key.namelength" : 31, + "key.nameoffset" : 2323, + "key.offset" : 2318, + "key.parsed_declaration" : "func travel(distance meters: Double)", + "key.parsed_scope.end" : 92, + "key.parsed_scope.start" : 87, + "key.receivers" : [ + { + "key.usr" : "s:7BicycleAAC" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : "(Bicycle) -> (Double) -> ()", + "key.typeusr" : "$s8distanceySd_tcD", + "key.usr" : "s:7BicycleAAC6travel8distanceySd_tF" + } + ], + "key.typename" : "Bicycle.Type", + "key.typeusr" : "$s7BicycleAACmD", + "key.usr" : "s:7BicycleAAC" + } + ] + } +} \ No newline at end of file diff --git a/Tests/SourceKittenFrameworkTests/Fixtures/BicycleIndex@swift-6.0.json b/Tests/SourceKittenFrameworkTests/Fixtures/BicycleIndex@swift-6.0.json new file mode 100644 index 00000000..99d4b594 --- /dev/null +++ b/Tests/SourceKittenFrameworkTests/Fixtures/BicycleIndex@swift-6.0.json @@ -0,0 +1,1181 @@ +{ + "key.dependencies" : [ + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.swift", + "key.name" : "Swift" + }, + { + "key.dependencies" : [ + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.swift", + "key.name" : "Swift" + } + ], + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.swift", + "key.name" : "_StringProcessing" + }, + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.clang", + "key.name" : "_SwiftConcurrencyShims" + }, + { + "key.dependencies" : [ + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.swift", + "key.name" : "Swift" + }, + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.clang", + "key.name" : "SwiftShims" + } + ], + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.swift", + "key.name" : "_Concurrency" + }, + { + "key.dependencies" : [ + { + "key.dependencies" : [ + { + "key.dependencies" : [ + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.clang", + "key.name" : "Darwin" + }, + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.swift", + "key.name" : "Swift" + }, + { + "key.dependencies" : [ + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.swift", + "key.name" : "Swift" + }, + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.clang", + "key.name" : "_Builtin_float" + } + ], + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.swift", + "key.name" : "_Builtin_float" + }, + { + "key.dependencies" : [ + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.swift", + "key.name" : "Swift" + }, + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.clang", + "key.name" : "_errno" + } + ], + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.swift", + "key.name" : "_errno" + }, + { + "key.dependencies" : [ + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.swift", + "key.name" : "Swift" + }, + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.clang", + "key.name" : "_math" + } + ], + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.swift", + "key.name" : "_math" + }, + { + "key.dependencies" : [ + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.swift", + "key.name" : "Swift" + }, + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.clang", + "key.name" : "_signal" + } + ], + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.swift", + "key.name" : "_signal" + }, + { + "key.dependencies" : [ + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.swift", + "key.name" : "Swift" + }, + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.clang", + "key.name" : "_stdio" + } + ], + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.swift", + "key.name" : "_stdio" + }, + { + "key.dependencies" : [ + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.swift", + "key.name" : "Swift" + }, + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.clang", + "key.name" : "_time" + } + ], + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.swift", + "key.name" : "_time" + }, + { + "key.dependencies" : [ + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.swift", + "key.name" : "Swift" + }, + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.clang", + "key.name" : "sys_time" + }, + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.clang", + "key.name" : "timeval" + } + ], + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.swift", + "key.name" : "sys_time" + }, + { + "key.dependencies" : [ + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.swift", + "key.name" : "Swift" + }, + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.clang", + "key.name" : "unistd" + } + ], + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.swift", + "key.name" : "unistd" + } + ], + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.swift", + "key.name" : "Darwin" + }, + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.swift", + "key.name" : "Swift" + }, + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.swift", + "key.name" : "_Concurrency" + }, + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.swift", + "key.name" : "_StringProcessing" + }, + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.clang", + "key.name" : "_SwiftConcurrencyShims" + } + ], + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.swift", + "key.name" : "Combine" + }, + { + "key.dependencies" : [ + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.clang", + "key.name" : "CoreFoundation" + }, + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.swift", + "key.name" : "Swift" + }, + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.swift", + "key.name" : "_Concurrency" + }, + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.swift", + "key.name" : "_StringProcessing" + }, + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.clang", + "key.name" : "_SwiftConcurrencyShims" + } + ], + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.swift", + "key.name" : "CoreFoundation" + }, + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.swift", + "key.name" : "Darwin" + }, + { + "key.dependencies" : [ + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.swift", + "key.name" : "Combine" + }, + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.clang", + "key.name" : "Dispatch" + }, + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.swift", + "key.name" : "Swift" + }, + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.swift", + "key.name" : "_Concurrency" + }, + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.swift", + "key.name" : "_StringProcessing" + }, + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.clang", + "key.name" : "_SwiftConcurrencyShims" + } + ], + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.swift", + "key.name" : "Dispatch" + }, + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.clang", + "key.name" : "Foundation" + }, + { + "key.dependencies" : [ + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.clang", + "key.name" : "ObjectiveC" + }, + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.swift", + "key.name" : "Swift" + }, + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.swift", + "key.name" : "_Concurrency" + }, + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.swift", + "key.name" : "_StringProcessing" + }, + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.clang", + "key.name" : "_SwiftConcurrencyShims" + } + ], + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.swift", + "key.name" : "ObjectiveC" + }, + { + "key.dependencies" : [ + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.swift", + "key.name" : "Swift" + } + ], + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.swift", + "key.name" : "Observation" + }, + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.swift", + "key.name" : "Swift" + }, + { + "key.dependencies" : [ + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.swift", + "key.name" : "Darwin" + }, + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.clang", + "key.name" : "Mach" + }, + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.swift", + "key.name" : "Swift" + }, + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.swift", + "key.name" : "_Concurrency" + }, + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.swift", + "key.name" : "_StringProcessing" + }, + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.clang", + "key.name" : "_SwiftConcurrencyShims" + } + ], + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.swift", + "key.name" : "System" + }, + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.swift", + "key.name" : "_Concurrency" + }, + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.swift", + "key.name" : "_StringProcessing" + }, + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.clang", + "key.name" : "_SwiftConcurrencyShims" + }, + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.clang", + "key.name" : "sysdir" + }, + { + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.clang", + "key.name" : "uuid" + } + ], + "key.filepath" : "", + "key.is_system" : true, + "key.kind" : "source.lang.swift.import.module.swift", + "key.name" : "Foundation" + } + ], + "key.entities" : [ + { + "key.column" : 8, + "key.kind" : "source.lang.swift.ref.module", + "key.line" : 1, + "key.name" : "Foundation", + "key.usr" : "c:@M@Foundation" + }, + { + "key.column" : 18, + "key.kind" : "source.lang.swift.ref.class", + "key.line" : 5, + "key.name" : "NSString", + "key.usr" : "c:objc(cs)NSString" + }, + { + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public" + } + ], + "key.column" : 14, + "key.effective_access" : "source.decl.effective_access.public", + "key.entities" : [ + { + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public" + } + ], + "key.column" : 17, + "key.effective_access" : "source.decl.effective_access.public", + "key.entities" : [ + { + "key.column" : 14, + "key.effective_access" : "source.decl.effective_access.public", + "key.kind" : "source.lang.swift.decl.enumelement", + "key.line" : 18, + "key.name" : "Road", + "key.usr" : "s:7BicycleAAC5StyleO4RoadyA2DmF" + }, + { + "key.column" : 20, + "key.effective_access" : "source.decl.effective_access.public", + "key.kind" : "source.lang.swift.decl.enumelement", + "key.line" : 18, + "key.name" : "Touring", + "key.usr" : "s:7BicycleAAC5StyleO7TouringyA2DmF" + }, + { + "key.column" : 29, + "key.effective_access" : "source.decl.effective_access.public", + "key.kind" : "source.lang.swift.decl.enumelement", + "key.line" : 18, + "key.name" : "Cruiser", + "key.usr" : "s:7BicycleAAC5StyleO7CruiseryA2DmF" + }, + { + "key.column" : 38, + "key.effective_access" : "source.decl.effective_access.public", + "key.kind" : "source.lang.swift.decl.enumelement", + "key.line" : 18, + "key.name" : "Hybrid", + "key.usr" : "s:7BicycleAAC5StyleO6HybridyA2DmF" + } + ], + "key.kind" : "source.lang.swift.decl.enum", + "key.line" : 17, + "key.name" : "Style", + "key.usr" : "s:7BicycleAAC5StyleO" + }, + { + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public" + } + ], + "key.column" : 17, + "key.effective_access" : "source.decl.effective_access.public", + "key.entities" : [ + { + "key.column" : 14, + "key.effective_access" : "source.decl.effective_access.public", + "key.kind" : "source.lang.swift.decl.enumelement", + "key.line" : 28, + "key.name" : "Fixed", + "key.usr" : "s:7BicycleAAC7GearingO5FixedyA2DmF" + }, + { + "key.column" : 14, + "key.effective_access" : "source.decl.effective_access.public", + "key.entities" : [ + { + "key.column" : 32, + "key.kind" : "source.lang.swift.ref.struct", + "key.line" : 29, + "key.name" : "Int", + "key.usr" : "s:Si" + } + ], + "key.kind" : "source.lang.swift.decl.enumelement", + "key.line" : 29, + "key.name" : "Freewheel(speeds:)", + "key.usr" : "s:7BicycleAAC7GearingO9FreewheelyADSi_tcADmF" + } + ], + "key.kind" : "source.lang.swift.decl.enum", + "key.line" : 27, + "key.name" : "Gearing", + "key.usr" : "s:7BicycleAAC7GearingO" + }, + { + "key.column" : 10, + "key.effective_access" : "source.decl.effective_access.internal", + "key.entities" : [ + { + "key.column" : 14, + "key.effective_access" : "source.decl.effective_access.internal", + "key.kind" : "source.lang.swift.decl.enumelement", + "key.line" : 41, + "key.name" : "Riser", + "key.usr" : "s:7BicycleAAC9HandlebarO5RiseryA2DmF" + }, + { + "key.column" : 21, + "key.effective_access" : "source.decl.effective_access.internal", + "key.kind" : "source.lang.swift.decl.enumelement", + "key.line" : 41, + "key.name" : "Café", + "key.usr" : "s:7BicycleAAC9HandlebarO007Caf_dmayA2DmF" + }, + { + "key.column" : 28, + "key.effective_access" : "source.decl.effective_access.internal", + "key.kind" : "source.lang.swift.decl.enumelement", + "key.line" : 41, + "key.name" : "Drop", + "key.usr" : "s:7BicycleAAC9HandlebarO4DropyA2DmF" + }, + { + "key.column" : 34, + "key.effective_access" : "source.decl.effective_access.internal", + "key.kind" : "source.lang.swift.decl.enumelement", + "key.line" : 41, + "key.name" : "Bullhorn", + "key.usr" : "s:7BicycleAAC9HandlebarO8BullhornyA2DmF" + } + ], + "key.kind" : "source.lang.swift.decl.enum", + "key.line" : 40, + "key.name" : "Handlebar", + "key.usr" : "s:7BicycleAAC9HandlebarO" + }, + { + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.final" + } + ], + "key.column" : 9, + "key.effective_access" : "source.decl.effective_access.internal", + "key.entities" : [ + { + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.final" + } + ], + "key.column" : 9, + "key.is_implicit" : true, + "key.kind" : "source.lang.swift.decl.function.accessor.getter", + "key.line" : 45, + "key.usr" : "s:7BicycleAAC5styleAB5StyleOvg" + }, + { + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.final" + } + ], + "key.column" : 9, + "key.is_implicit" : true, + "key.kind" : "source.lang.swift.decl.function.accessor.setter", + "key.line" : 45, + "key.usr" : "s:7BicycleAAC5styleAB5StyleOvs" + } + ], + "key.kind" : "source.lang.swift.decl.var.instance", + "key.line" : 45, + "key.name" : "style", + "key.usr" : "s:7BicycleAAC5styleAB5StyleOvp" + }, + { + "key.column" : 16, + "key.kind" : "source.lang.swift.ref.enum", + "key.line" : 45, + "key.name" : "Style", + "key.usr" : "s:7BicycleAAC5StyleO" + }, + { + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.final" + } + ], + "key.column" : 9, + "key.effective_access" : "source.decl.effective_access.internal", + "key.entities" : [ + { + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.final" + } + ], + "key.column" : 9, + "key.is_implicit" : true, + "key.kind" : "source.lang.swift.decl.function.accessor.getter", + "key.line" : 48, + "key.usr" : "s:7BicycleAAC7gearingAB7GearingOvg" + }, + { + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.final" + } + ], + "key.column" : 9, + "key.is_implicit" : true, + "key.kind" : "source.lang.swift.decl.function.accessor.setter", + "key.line" : 48, + "key.usr" : "s:7BicycleAAC7gearingAB7GearingOvs" + } + ], + "key.kind" : "source.lang.swift.decl.var.instance", + "key.line" : 48, + "key.name" : "gearing", + "key.usr" : "s:7BicycleAAC7gearingAB7GearingOvp" + }, + { + "key.column" : 18, + "key.kind" : "source.lang.swift.ref.enum", + "key.line" : 48, + "key.name" : "Gearing", + "key.usr" : "s:7BicycleAAC7GearingO" + }, + { + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.final" + } + ], + "key.column" : 9, + "key.effective_access" : "source.decl.effective_access.internal", + "key.entities" : [ + { + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.final" + } + ], + "key.column" : 9, + "key.is_implicit" : true, + "key.kind" : "source.lang.swift.decl.function.accessor.getter", + "key.line" : 51, + "key.usr" : "s:7BicycleAAC9handlebarAB9HandlebarOvg" + }, + { + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.final" + } + ], + "key.column" : 9, + "key.is_implicit" : true, + "key.kind" : "source.lang.swift.decl.function.accessor.setter", + "key.line" : 51, + "key.usr" : "s:7BicycleAAC9handlebarAB9HandlebarOvs" + } + ], + "key.kind" : "source.lang.swift.decl.var.instance", + "key.line" : 51, + "key.name" : "handlebar", + "key.usr" : "s:7BicycleAAC9handlebarAB9HandlebarOvp" + }, + { + "key.column" : 20, + "key.kind" : "source.lang.swift.ref.enum", + "key.line" : 51, + "key.name" : "Handlebar", + "key.usr" : "s:7BicycleAAC9HandlebarO" + }, + { + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.final" + } + ], + "key.column" : 9, + "key.effective_access" : "source.decl.effective_access.internal", + "key.entities" : [ + { + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.final" + } + ], + "key.column" : 9, + "key.is_implicit" : true, + "key.kind" : "source.lang.swift.decl.function.accessor.getter", + "key.line" : 54, + "key.usr" : "s:7BicycleAAC9frameSizeSivg" + }, + { + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.final" + } + ], + "key.column" : 9, + "key.is_implicit" : true, + "key.kind" : "source.lang.swift.decl.function.accessor.setter", + "key.line" : 54, + "key.usr" : "s:7BicycleAAC9frameSizeSivs" + } + ], + "key.kind" : "source.lang.swift.decl.var.instance", + "key.line" : 54, + "key.name" : "frameSize", + "key.usr" : "s:7BicycleAAC9frameSizeSivp" + }, + { + "key.column" : 20, + "key.kind" : "source.lang.swift.ref.struct", + "key.line" : 54, + "key.name" : "Int", + "key.usr" : "s:Si" + }, + { + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.setter_access.private" + } + ], + "key.column" : 22, + "key.effective_access" : "source.decl.effective_access.internal", + "key.entities" : [ + { + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.setter_access.private" + } + ], + "key.column" : 22, + "key.is_dynamic" : true, + "key.is_implicit" : true, + "key.kind" : "source.lang.swift.decl.function.accessor.getter", + "key.line" : 57, + "key.usr" : "s:7BicycleAAC13numberOfTripsSivg" + }, + { + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.setter_access.private" + } + ], + "key.column" : 22, + "key.is_dynamic" : true, + "key.is_implicit" : true, + "key.kind" : "source.lang.swift.decl.function.accessor.setter", + "key.line" : 57, + "key.usr" : "s:7BicycleAAC13numberOfTripsSivs" + } + ], + "key.kind" : "source.lang.swift.decl.var.instance", + "key.line" : 57, + "key.name" : "numberOfTrips", + "key.usr" : "s:7BicycleAAC13numberOfTripsSivp" + }, + { + "key.column" : 37, + "key.kind" : "source.lang.swift.ref.struct", + "key.line" : 57, + "key.name" : "Int", + "key.usr" : "s:Si" + }, + { + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.setter_access.private" + } + ], + "key.column" : 22, + "key.effective_access" : "source.decl.effective_access.internal", + "key.entities" : [ + { + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.setter_access.private" + } + ], + "key.column" : 22, + "key.is_dynamic" : true, + "key.is_implicit" : true, + "key.kind" : "source.lang.swift.decl.function.accessor.getter", + "key.line" : 60, + "key.usr" : "s:7BicycleAAC17distanceTravelledSdvg" + }, + { + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.setter_access.private" + } + ], + "key.column" : 22, + "key.is_dynamic" : true, + "key.is_implicit" : true, + "key.kind" : "source.lang.swift.decl.function.accessor.setter", + "key.line" : 60, + "key.usr" : "s:7BicycleAAC17distanceTravelledSdvs" + } + ], + "key.kind" : "source.lang.swift.decl.var.instance", + "key.line" : 60, + "key.name" : "distanceTravelled", + "key.usr" : "s:7BicycleAAC17distanceTravelledSdvp" + }, + { + "key.column" : 41, + "key.kind" : "source.lang.swift.ref.struct", + "key.line" : 60, + "key.name" : "Double", + "key.usr" : "s:Sd" + }, + { + "key.column" : 5, + "key.effective_access" : "source.decl.effective_access.internal", + "key.entities" : [ + { + "key.column" : 17, + "key.kind" : "source.lang.swift.ref.enum", + "key.line" : 72, + "key.name" : "Style", + "key.usr" : "s:7BicycleAAC5StyleO" + }, + { + "key.column" : 33, + "key.kind" : "source.lang.swift.ref.enum", + "key.line" : 72, + "key.name" : "Gearing", + "key.usr" : "s:7BicycleAAC7GearingO" + }, + { + "key.column" : 53, + "key.kind" : "source.lang.swift.ref.enum", + "key.line" : 72, + "key.name" : "Handlebar", + "key.usr" : "s:7BicycleAAC9HandlebarO" + }, + { + "key.column" : 87, + "key.kind" : "source.lang.swift.ref.struct", + "key.line" : 72, + "key.name" : "Int", + "key.usr" : "s:Si" + }, + { + "key.column" : 14, + "key.entities" : [ + { + "key.column" : 14, + "key.is_implicit" : true, + "key.kind" : "source.lang.swift.ref.function.accessor.setter", + "key.line" : 73, + "key.usr" : "s:7BicycleAAC5styleAB5StyleOvs" + } + ], + "key.kind" : "source.lang.swift.ref.var.instance", + "key.line" : 73, + "key.name" : "style", + "key.usr" : "s:7BicycleAAC5styleAB5StyleOvp" + }, + { + "key.column" : 14, + "key.entities" : [ + { + "key.column" : 14, + "key.is_implicit" : true, + "key.kind" : "source.lang.swift.ref.function.accessor.setter", + "key.line" : 74, + "key.usr" : "s:7BicycleAAC7gearingAB7GearingOvs" + } + ], + "key.kind" : "source.lang.swift.ref.var.instance", + "key.line" : 74, + "key.name" : "gearing", + "key.usr" : "s:7BicycleAAC7gearingAB7GearingOvp" + }, + { + "key.column" : 14, + "key.entities" : [ + { + "key.column" : 14, + "key.is_implicit" : true, + "key.kind" : "source.lang.swift.ref.function.accessor.setter", + "key.line" : 75, + "key.usr" : "s:7BicycleAAC9handlebarAB9HandlebarOvs" + } + ], + "key.kind" : "source.lang.swift.ref.var.instance", + "key.line" : 75, + "key.name" : "handlebar", + "key.usr" : "s:7BicycleAAC9handlebarAB9HandlebarOvp" + }, + { + "key.column" : 14, + "key.entities" : [ + { + "key.column" : 14, + "key.is_implicit" : true, + "key.kind" : "source.lang.swift.ref.function.accessor.setter", + "key.line" : 76, + "key.usr" : "s:7BicycleAAC9frameSizeSivs" + } + ], + "key.kind" : "source.lang.swift.ref.var.instance", + "key.line" : 76, + "key.name" : "frameSize", + "key.usr" : "s:7BicycleAAC9frameSizeSivp" + }, + { + "key.column" : 9, + "key.entities" : [ + { + "key.column" : 9, + "key.is_dynamic" : true, + "key.is_implicit" : true, + "key.kind" : "source.lang.swift.ref.function.accessor.setter", + "key.line" : 78, + "key.receiver_usr" : "s:7BicycleAAC", + "key.usr" : "s:7BicycleAAC13numberOfTripsSivs" + } + ], + "key.is_dynamic" : true, + "key.kind" : "source.lang.swift.ref.var.instance", + "key.line" : 78, + "key.name" : "numberOfTrips", + "key.receiver_usr" : "s:7BicycleAAC", + "key.usr" : "s:7BicycleAAC13numberOfTripsSivp" + }, + { + "key.column" : 9, + "key.entities" : [ + { + "key.column" : 9, + "key.is_dynamic" : true, + "key.is_implicit" : true, + "key.kind" : "source.lang.swift.ref.function.accessor.setter", + "key.line" : 79, + "key.receiver_usr" : "s:7BicycleAAC", + "key.usr" : "s:7BicycleAAC17distanceTravelledSdvs" + } + ], + "key.is_dynamic" : true, + "key.kind" : "source.lang.swift.ref.var.instance", + "key.line" : 79, + "key.name" : "distanceTravelled", + "key.receiver_usr" : "s:7BicycleAAC", + "key.usr" : "s:7BicycleAAC17distanceTravelledSdvp" + } + ], + "key.kind" : "source.lang.swift.decl.function.constructor", + "key.line" : 72, + "key.name" : "init(style:gearing:handlebar:frameSize:)", + "key.usr" : "s:7BicycleAAC5style7gearing9handlebar9frameSizeA2B5StyleO_AB7GearingOAB9HandlebarOSitcfc" + }, + { + "key.column" : 10, + "key.effective_access" : "source.decl.effective_access.internal", + "key.entities" : [ + { + "key.column" : 34, + "key.kind" : "source.lang.swift.ref.struct", + "key.line" : 87, + "key.name" : "Double", + "key.usr" : "s:Sd" + }, + { + "key.column" : 19, + "key.kind" : "source.lang.swift.ref.function.operator.infix", + "key.line" : 88, + "key.name" : ">(_:_:)", + "key.usr" : "s:SFsE1goiySbx_xtFZ" + }, + { + "key.column" : 13, + "key.entities" : [ + { + "key.column" : 13, + "key.is_dynamic" : true, + "key.is_implicit" : true, + "key.kind" : "source.lang.swift.ref.function.accessor.getter", + "key.line" : 89, + "key.receiver_usr" : "s:7BicycleAAC", + "key.usr" : "s:7BicycleAAC17distanceTravelledSdvg" + }, + { + "key.column" : 13, + "key.is_dynamic" : true, + "key.is_implicit" : true, + "key.kind" : "source.lang.swift.ref.function.accessor.setter", + "key.line" : 89, + "key.receiver_usr" : "s:7BicycleAAC", + "key.usr" : "s:7BicycleAAC17distanceTravelledSdvs" + } + ], + "key.is_dynamic" : true, + "key.kind" : "source.lang.swift.ref.var.instance", + "key.line" : 89, + "key.name" : "distanceTravelled", + "key.receiver_usr" : "s:7BicycleAAC", + "key.usr" : "s:7BicycleAAC17distanceTravelledSdvp" + }, + { + "key.column" : 31, + "key.kind" : "source.lang.swift.ref.function.operator.infix", + "key.line" : 89, + "key.name" : "+=(_:_:)", + "key.usr" : "s:Sd2peoiyySdz_SdtFZ" + }, + { + "key.column" : 13, + "key.entities" : [ + { + "key.column" : 13, + "key.is_dynamic" : true, + "key.is_implicit" : true, + "key.kind" : "source.lang.swift.ref.function.accessor.getter", + "key.line" : 90, + "key.receiver_usr" : "s:7BicycleAAC", + "key.usr" : "s:7BicycleAAC13numberOfTripsSivg" + }, + { + "key.column" : 13, + "key.is_dynamic" : true, + "key.is_implicit" : true, + "key.kind" : "source.lang.swift.ref.function.accessor.setter", + "key.line" : 90, + "key.receiver_usr" : "s:7BicycleAAC", + "key.usr" : "s:7BicycleAAC13numberOfTripsSivs" + } + ], + "key.is_dynamic" : true, + "key.kind" : "source.lang.swift.ref.var.instance", + "key.line" : 90, + "key.name" : "numberOfTrips", + "key.receiver_usr" : "s:7BicycleAAC", + "key.usr" : "s:7BicycleAAC13numberOfTripsSivp" + }, + { + "key.column" : 27, + "key.kind" : "source.lang.swift.ref.function.operator.infix", + "key.line" : 90, + "key.name" : "+=(_:_:)", + "key.usr" : "s:Si2peoiyySiz_SitFZ" + } + ], + "key.is_dynamic" : true, + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.line" : 87, + "key.name" : "travel(distance:)", + "key.usr" : "s:7BicycleAAC6travel8distanceySd_tF" + } + ], + "key.kind" : "source.lang.swift.decl.class", + "key.line" : 8, + "key.name" : "Bicycle", + "key.usr" : "s:7BicycleAAC" + } + ] +} diff --git a/Tests/SourceKittenFrameworkTests/Fixtures/Commandant@swift-6.0.json b/Tests/SourceKittenFrameworkTests/Fixtures/Commandant@swift-6.0.json new file mode 100644 index 00000000..f2adfdeb --- /dev/null +++ b/Tests/SourceKittenFrameworkTests/Fixtures/Commandant@swift-6.0.json @@ -0,0 +1,9220 @@ +[{ + "\/Sources\/Commandant\/Argument.swift" : { + "key.diagnostic_stage" : "source.diagnostic.stage.swift.parse", + "key.length" : 3858, + "key.offset" : 0, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public struct Argument<T><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 204 + } + ], + "key.bodylength" : 1029, + "key.bodyoffset" : 231, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Describes an argument that can be provided on the command line.", + "key.doc.column" : 15, + "key.doc.comment" : "Describes an argument that can be provided on the command line.", + "key.doc.declaration" : "public struct Argument", + "key.doc.file" : "\/private\/Sources\/Commandant\/Argument.swift", + "key.doc.full_as_xml" : "Argument<\/Name>s:10Commandant8ArgumentV<\/USR>public struct Argument<T><\/Declaration>Describes an argument that can be provided on the command line.<\/Para><\/Abstract><\/CommentParts><\/Class>", + "key.doc.line" : 10, + "key.doc.name" : "Argument", + "key.doc.type" : "Class", + "key.doclength" : 68, + "key.docoffset" : 136, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> struct<\/syntaxtype.keyword> Argument<\/decl.name><T<\/decl.generic_type_param.name><\/decl.generic_type_param>><\/decl.struct>", + "key.kind" : "source.lang.swift.decl.struct", + "key.length" : 1050, + "key.line" : 10, + "key.modulename" : "Commandant", + "key.name" : "Argument", + "key.namelength" : 8, + "key.nameoffset" : 218, + "key.offset" : 211, + "key.parsed_declaration" : "public struct Argument", + "key.parsed_scope.end" : 36, + "key.parsed_scope.start" : 10, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "T<\/Declaration>", + "key.column" : 24, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "T<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 1, + "key.line" : 10, + "key.modulename" : "Commandant", + "key.name" : "T", + "key.namelength" : 1, + "key.nameoffset" : 227, + "key.offset" : 227, + "key.parsed_declaration" : "public struct Argumentpublic let defaultValue: T<\/Type>?<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 443 + } + ], + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "The default value for this argument. This is the value that will be used\nif the argument is never explicitly specified on the command line.\n\nIf this is nil, this argument is always required.", + "key.doc.column" : 13, + "key.doc.comment" : "The default value for this argument. This is the value that will be used\nif the argument is never explicitly specified on the command line.\n\nIf this is nil, this argument is always required.", + "key.doc.declaration" : "public let defaultValue: T?", + "key.doc.discussion" : [ + { + "Para" : "If this is nil, this argument is always required." + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Argument.swift", + "key.doc.full_as_xml" : "defaultValue<\/Name>s:10Commandant8ArgumentV12defaultValuexSgvp<\/USR>public let defaultValue: T?<\/Declaration>The default value for this argument. This is the value that will be used if the argument is never explicitly specified on the command line.<\/Para><\/Abstract>If this is nil, this argument is always required.<\/Para><\/Discussion><\/CommentParts><\/Other>", + "key.doc.line" : 15, + "key.doc.name" : "defaultValue", + "key.doc.type" : "Other", + "key.doclength" : 209, + "key.docoffset" : 233, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> let<\/syntaxtype.keyword> defaultValue<\/decl.name>: T<\/ref.generic_type_param>?<\/decl.var.type><\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 20, + "key.line" : 15, + "key.modulename" : "Commandant", + "key.name" : "defaultValue", + "key.namelength" : 12, + "key.nameoffset" : 454, + "key.offset" : 450, + "key.parsed_declaration" : "public let defaultValue: T?", + "key.parsed_scope.end" : 15, + "key.parsed_scope.start" : 15, + "key.reusingastcontext" : false, + "key.typename" : "T?", + "key.typeusr" : "$sxSgD", + "key.usr" : "s:10Commandant8ArgumentV12defaultValuexSgvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public let usage: String<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 585 + } + ], + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A human-readable string describing the purpose of this argument. This will\nbe shown in help messages.", + "key.doc.column" : 13, + "key.doc.comment" : "A human-readable string describing the purpose of this argument. This will\nbe shown in help messages.", + "key.doc.declaration" : "public let usage: String", + "key.doc.file" : "\/private\/Sources\/Commandant\/Argument.swift", + "key.doc.full_as_xml" : "usage<\/Name>s:10Commandant8ArgumentV5usageSSvp<\/USR>public let usage: String<\/Declaration>A human-readable string describing the purpose of this argument. This will be shown in help messages.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 19, + "key.doc.name" : "usage", + "key.doc.type" : "Other", + "key.doclength" : 111, + "key.docoffset" : 473, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> let<\/syntaxtype.keyword> usage<\/decl.name>: String<\/ref.struct><\/decl.var.type><\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 17, + "key.line" : 19, + "key.modulename" : "Commandant", + "key.name" : "usage", + "key.namelength" : 5, + "key.nameoffset" : 596, + "key.offset" : 592, + "key.parsed_declaration" : "public let usage: String", + "key.parsed_scope.end" : 19, + "key.parsed_scope.start" : 19, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant8ArgumentV5usageSSvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public let usageParameter: String<\/Type>?<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 804 + } + ], + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A human-readable string that describes this argument as a paramater shown\nin the list of possible parameters in help messages (e.g. for \"paths\", the\nuser would see ).", + "key.doc.column" : 13, + "key.doc.comment" : "A human-readable string that describes this argument as a paramater shown\nin the list of possible parameters in help messages (e.g. for \"paths\", the\nuser would see ).", + "key.doc.declaration" : "public let usageParameter: String?", + "key.doc.file" : "\/private\/Sources\/Commandant\/Argument.swift", + "key.doc.full_as_xml" : "usageParameter<\/Name>s:10Commandant8ArgumentV14usageParameterSSSgvp<\/USR>public let usageParameter: String?<\/Declaration>A human-readable string that describes this argument as a paramater shown in the list of possible parameters in help messages (e.g. for “paths”, the user would see <paths…>).<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 24, + "key.doc.name" : "usageParameter", + "key.doc.type" : "Other", + "key.doclength" : 191, + "key.docoffset" : 612, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> let<\/syntaxtype.keyword> usageParameter<\/decl.name>: String<\/ref.struct>?<\/decl.var.type><\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 27, + "key.line" : 24, + "key.modulename" : "Commandant", + "key.name" : "usageParameter", + "key.namelength" : 14, + "key.nameoffset" : 815, + "key.offset" : 811, + "key.parsed_declaration" : "public let usageParameter: String?", + "key.parsed_scope.end" : 24, + "key.parsed_scope.start" : 24, + "key.reusingastcontext" : false, + "key.typename" : "String?", + "key.typeusr" : "$sSSSgD", + "key.usr" : "s:10Commandant8ArgumentV14usageParameterSSSgvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public init(defaultValue: T<\/Type>? = nil, usage: String<\/Type>, usageParameter: String<\/Type>? = nil)<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 841 + } + ], + "key.bodylength" : 97, + "key.bodyoffset" : 924, + "key.column" : 9, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> init<\/syntaxtype.keyword>(defaultValue<\/decl.var.parameter.argument_label>: T<\/ref.generic_type_param>?<\/decl.var.parameter.type> = nil<\/decl.var.parameter>, usage<\/decl.var.parameter.argument_label>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>, usageParameter<\/decl.var.parameter.argument_label>: String<\/ref.struct>?<\/decl.var.parameter.type> = nil<\/decl.var.parameter>)<\/decl.function.constructor>", + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 174, + "key.line" : 26, + "key.modulename" : "Commandant", + "key.name" : "init(defaultValue:usage:usageParameter:)", + "key.namelength" : 74, + "key.nameoffset" : 848, + "key.offset" : 848, + "key.parsed_declaration" : "public init(defaultValue: T? = nil, usage: String, usageParameter: String? = nil)", + "key.parsed_scope.end" : 30, + "key.parsed_scope.start" : 26, + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : " (Argument.Type) -> (T?, String, String?) -> Argument", + "key.typeusr" : "$s12defaultValue5usage0C9Parameter10Commandant8ArgumentVyxGxSg_S2SSgtcD", + "key.usr" : "s:10Commandant8ArgumentV12defaultValue5usage0E9ParameterACyxGxSg_S2SSgtcfc" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.fileprivate", + "key.annotated_decl" : "fileprivate func invalidUsageError<ClientError>(_ value: String<\/Type>) -> CommandantError<\/Type><ClientError<\/Type>><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.fileprivate", + "key.length" : 11, + "key.offset" : 1025 + } + ], + "key.bodylength" : 135, + "key.bodyoffset" : 1123, + "key.column" : 19, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "fileprivate<\/syntaxtype.keyword> func<\/syntaxtype.keyword> invalidUsageError<\/decl.name><ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>>(_<\/decl.var.parameter.argument_label> value<\/decl.var.parameter.name>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>) -> CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>><\/decl.function.returntype><\/decl.function.method.instance>", + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 222, + "key.line" : 32, + "key.modulename" : "Commandant", + "key.name" : "invalidUsageError(_:)", + "key.namelength" : 47, + "key.nameoffset" : 1042, + "key.offset" : 1037, + "key.parsed_declaration" : "fileprivate func invalidUsageError(_ value: String) -> CommandantError", + "key.parsed_scope.end" : 35, + "key.parsed_scope.start" : 32, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "ClientError<\/Declaration>", + "key.column" : 37, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 32, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 1060, + "key.offset" : 1060, + "key.parsed_declaration" : "fileprivate func invalidUsageErrorlet description: String<\/Type><\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "let<\/syntaxtype.keyword> description<\/decl.name>: String<\/ref.struct><\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 83, + "key.line" : 33, + "key.modulename" : "Commandant", + "key.name" : "description", + "key.namelength" : 11, + "key.nameoffset" : 1130, + "key.offset" : 1126, + "key.parsed_declaration" : "let description = \"Invalid value for '\\(self.usageParameterDescription)': \\(value)\"", + "key.parsed_scope.end" : 33, + "key.parsed_scope.start" : 33, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant8ArgumentV17invalidUsageError33_8CAE711C2CD19D07FEBBE5F857AB09FDLLyAA0aE0Oyqd__GSSlF11descriptionL_SSvp" + } + ], + "key.typename" : " (Argument) -> (String) -> CommandantError", + "key.typeusr" : "$sy10Commandant0A5ErrorOyqd__GSScluD", + "key.usr" : "s:10Commandant8ArgumentV17invalidUsageError33_8CAE711C2CD19D07FEBBE5F857AB09FDLLyAA0aE0Oyqd__GSSlF" + } + ], + "key.typename" : "Argument.Type", + "key.typeusr" : "$s10Commandant8ArgumentVyxGmD", + "key.usr" : "s:10Commandant8ArgumentV" + }, + { + "key.annotated_decl" : "public struct Argument<T><\/Declaration>", + "key.bodylength" : 251, + "key.bodyoffset" : 1283, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Describes an argument that can be provided on the command line.", + "key.doc.column" : 15, + "key.doc.declaration" : "public struct Argument", + "key.doc.file" : "\/private\/Sources\/Commandant\/Argument.swift", + "key.doc.full_as_xml" : "Argument<\/Name>s:10Commandant8ArgumentV<\/USR>public struct Argument<T><\/Declaration>Describes an argument that can be provided on the command line.<\/Para><\/Abstract><\/CommentParts><\/Class>", + "key.doc.line" : 10, + "key.doc.name" : "Argument", + "key.doc.type" : "Class", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> struct<\/syntaxtype.keyword> Argument<\/decl.name><T<\/decl.generic_type_param.name><\/decl.generic_type_param>><\/decl.struct>", + "key.kind" : "source.lang.swift.decl.extension", + "key.length" : 272, + "key.line" : 10, + "key.modulename" : "Commandant", + "key.name" : "Argument", + "key.namelength" : 8, + "key.nameoffset" : 1273, + "key.offset" : 1263, + "key.parsed_declaration" : "extension Argument", + "key.parsed_scope.end" : 44, + "key.parsed_scope.start" : 38, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "internal var usageParameterDescription: String<\/Type> { get }<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.internal", + "key.length" : 8, + "key.offset" : 1422 + } + ], + "key.bodylength" : 62, + "key.bodyoffset" : 1470, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A string describing this argument as a parameter in help messages. This falls back\nto `\"\\(self)\"` if `usageParameter` is `nil`", + "key.doc.column" : 15, + "key.doc.comment" : "A string describing this argument as a parameter in help messages. This falls back\nto `\"\\(self)\"` if `usageParameter` is `nil`", + "key.doc.declaration" : "internal var usageParameterDescription: String { get }", + "key.doc.file" : "\/private\/Sources\/Commandant\/Argument.swift", + "key.doc.full_as_xml" : "usageParameterDescription<\/Name>s:10Commandant8ArgumentV25usageParameterDescriptionSSvp<\/USR>internal var usageParameterDescription: String { get }<\/Declaration>A string describing this argument as a parameter in help messages. This falls back to "\\(self)"<\/codeVoice> if usageParameter<\/codeVoice> is nil<\/codeVoice><\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 41, + "key.doc.name" : "usageParameterDescription", + "key.doc.type" : "Other", + "key.doclength" : 136, + "key.docoffset" : 1285, + "key.filepath" : "", + "key.fully_annotated_decl" : "internal<\/syntaxtype.keyword> var<\/syntaxtype.keyword> usageParameterDescription<\/decl.name>: String<\/ref.struct><\/decl.var.type> { get<\/syntaxtype.keyword> }<\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 102, + "key.line" : 41, + "key.modulename" : "Commandant", + "key.name" : "usageParameterDescription", + "key.namelength" : 25, + "key.nameoffset" : 1435, + "key.offset" : 1431, + "key.parsed_declaration" : "internal var usageParameterDescription: String", + "key.parsed_scope.end" : 43, + "key.parsed_scope.start" : 41, + "key.related_decls" : [ + { + "key.annotated_decl" : "usageParameterDescription<\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant8ArgumentV25usageParameterDescriptionSSvp" + } + ], + "key.typename" : "Argument.Type", + "key.typeusr" : "$s10Commandant8ArgumentVyxGmD", + "key.usr" : "s:10Commandant8ArgumentV" + }, + { + "key.annotated_decl" : "public struct Argument<T><\/Declaration>", + "key.bodylength" : 254, + "key.bodyoffset" : 1575, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Describes an argument that can be provided on the command line.", + "key.doc.column" : 15, + "key.doc.declaration" : "public struct Argument", + "key.doc.file" : "\/private\/Sources\/Commandant\/Argument.swift", + "key.doc.full_as_xml" : "Argument<\/Name>s:10Commandant8ArgumentV<\/USR>public struct Argument<T><\/Declaration>Describes an argument that can be provided on the command line.<\/Para><\/Abstract><\/CommentParts><\/Class>", + "key.doc.line" : 10, + "key.doc.name" : "Argument", + "key.doc.type" : "Class", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> struct<\/syntaxtype.keyword> Argument<\/decl.name><T<\/decl.generic_type_param.name><\/decl.generic_type_param>><\/decl.struct>", + "key.kind" : "source.lang.swift.decl.extension", + "key.length" : 293, + "key.line" : 10, + "key.modulename" : "Commandant", + "key.name" : "Argument", + "key.namelength" : 8, + "key.nameoffset" : 1547, + "key.offset" : 1537, + "key.parsed_declaration" : "extension Argument where T: Sequence", + "key.parsed_scope.end" : 52, + "key.parsed_scope.start" : 46, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "internal var usageParameterDescription: String<\/Type> { get }<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.internal", + "key.length" : 8, + "key.offset" : 1714 + } + ], + "key.bodylength" : 65, + "key.bodyoffset" : 1762, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A string describing this argument as a parameter in help messages. This falls back\nto `\"\\(self)\"` if `usageParameter` is `nil`", + "key.doc.column" : 15, + "key.doc.comment" : "A string describing this argument as a parameter in help messages. This falls back\nto `\"\\(self)\"` if `usageParameter` is `nil`", + "key.doc.declaration" : "internal var usageParameterDescription: String { get }", + "key.doc.file" : "\/private\/Sources\/Commandant\/Argument.swift", + "key.doc.full_as_xml" : "usageParameterDescription<\/Name>s:10Commandant8ArgumentVAASTRzlE25usageParameterDescriptionSSvp<\/USR>internal var usageParameterDescription: String { get }<\/Declaration>A string describing this argument as a parameter in help messages. This falls back to "\\(self)"<\/codeVoice> if usageParameter<\/codeVoice> is nil<\/codeVoice><\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 49, + "key.doc.name" : "usageParameterDescription", + "key.doc.type" : "Other", + "key.doclength" : 136, + "key.docoffset" : 1577, + "key.filepath" : "", + "key.fully_annotated_decl" : "internal<\/syntaxtype.keyword> var<\/syntaxtype.keyword> usageParameterDescription<\/decl.name>: String<\/ref.struct><\/decl.var.type> { get<\/syntaxtype.keyword> }<\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 105, + "key.line" : 49, + "key.modulename" : "Commandant", + "key.name" : "usageParameterDescription", + "key.namelength" : 25, + "key.nameoffset" : 1727, + "key.offset" : 1723, + "key.parsed_declaration" : "internal var usageParameterDescription: String", + "key.parsed_scope.end" : 51, + "key.parsed_scope.start" : 49, + "key.related_decls" : [ + { + "key.annotated_decl" : "usageParameterDescription<\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant8ArgumentVAASTRzlE25usageParameterDescriptionSSvp" + } + ], + "key.typename" : "Argument.Type", + "key.typeusr" : "$s10Commandant8ArgumentVyxGmD", + "key.usr" : "s:10Commandant8ArgumentV" + }, + { + "key.kind" : "source.lang.swift.syntaxtype.comment.mark", + "key.length" : 17, + "key.name" : "MARK: - Operators", + "key.offset" : 1835 + }, + { + "key.annotated_decl" : "public enum CommandMode<\/Declaration>", + "key.bodylength" : 1979, + "key.bodyoffset" : 1877, + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Describes the \"mode\" in which a command should run.", + "key.doc.column" : 13, + "key.doc.declaration" : "public enum CommandMode", + "key.doc.file" : "\/private\/Sources\/Commandant\/Command.swift", + "key.doc.full_as_xml" : "CommandMode<\/Name>s:10Commandant11CommandModeO<\/USR>public enum CommandMode<\/Declaration>Describes the “mode” in which a command should run.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 68, + "key.doc.name" : "CommandMode", + "key.doc.type" : "Other", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> enum<\/syntaxtype.keyword> CommandMode<\/decl.name><\/decl.enum>", + "key.kind" : "source.lang.swift.decl.extension", + "key.length" : 2003, + "key.line" : 68, + "key.modulename" : "Commandant", + "key.name" : "CommandMode", + "key.namelength" : 11, + "key.nameoffset" : 1864, + "key.offset" : 1854, + "key.parsed_declaration" : "extension CommandMode", + "key.parsed_scope.end" : 120, + "key.parsed_scope.start" : 56, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public static func <| <T, ClientError>(mode: CommandMode<\/Type>, argument: Argument<\/Type><T<\/Type>>) -> Result<\/Type><T<\/Type>, CommandantError<\/Type><ClientError<\/Type>>> where T<\/Type> : ArgumentProtocol<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 2069 + } + ], + "key.bodylength" : 518, + "key.bodyoffset" : 2212, + "key.column" : 21, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Evaluates the given argument in the given mode.\n\nIf parsing command line arguments, and no value was specified on the command\nline, the argument's `defaultValue` is used.", + "key.doc.column" : 21, + "key.doc.comment" : "Evaluates the given argument in the given mode.\n\nIf parsing command line arguments, and no value was specified on the command\nline, the argument's `defaultValue` is used.", + "key.doc.declaration" : "public static func <| (mode: CommandMode, argument: Argument) -> Result> where T : Commandant.ArgumentProtocol", + "key.doc.discussion" : [ + { + "Para" : "If parsing command line arguments, and no value was specified on the command line, the argument’s `defaultValue` is used." + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Argument.swift", + "key.doc.full_as_xml" : "<|(_:_:)<\/Name>s:10Commandant11CommandModeO2looiys6ResultOyxAA0A5ErrorOyq_GGAC_AA8ArgumentVyxGtAA0G8ProtocolRzr0_lFZ<\/USR>public static func <| <T, ClientError>(mode: CommandMode, argument: Argument<T>) -> Result<T, CommandantError<ClientError>> where T : Commandant.ArgumentProtocol<\/Declaration>Evaluates the given argument in the given mode.<\/Para><\/Abstract>If parsing command line arguments, and no value was specified on the command line, the argument’s defaultValue<\/codeVoice> is used.<\/Para><\/Discussion><\/CommentParts><\/Function>", + "key.doc.line" : 61, + "key.doc.name" : "<|(_:_:)", + "key.doc.type" : "Function", + "key.doclength" : 189, + "key.docoffset" : 1879, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> static<\/syntaxtype.keyword> func<\/syntaxtype.keyword> <| <\/decl.name><T<\/decl.generic_type_param.name><\/decl.generic_type_param>, ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>>(mode<\/decl.var.parameter.name>: CommandMode<\/ref.enum><\/decl.var.parameter.type><\/decl.var.parameter>, argument<\/decl.var.parameter.name>: Argument<\/ref.struct><T<\/ref.generic_type_param>><\/decl.var.parameter.type><\/decl.var.parameter>) -> Result<\/ref.enum><T<\/ref.generic_type_param>, CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>>><\/decl.function.returntype> where<\/syntaxtype.keyword> T<\/ref.generic_type_param> : ArgumentProtocol<\/ref.protocol><\/decl.generic_type_requirement><\/decl.function.operator.infix>", + "key.kind" : "source.lang.swift.decl.function.method.static", + "key.length" : 655, + "key.line" : 61, + "key.modulename" : "Commandant", + "key.name" : "<|(_:_:)", + "key.namelength" : 79, + "key.nameoffset" : 2088, + "key.offset" : 2076, + "key.parsed_declaration" : "public static func <| (mode: CommandMode, argument: Argument) -> Result>", + "key.parsed_scope.end" : 81, + "key.parsed_scope.start" : 61, + "key.related_decls" : [ + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Argument<[T]>) -> Result<[T], CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<T>) -> Result<T, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<T?>) -> Result<T?, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<[T]>) -> Result<[T], CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<[T]?>) -> Result<[T]?, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <ClientError>(_: CommandMode, _: Option<Bool>) -> Result<Bool, CommandantError<ClientError>><\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <ClientError>(_: CommandMode, _: Switch) -> Result<Bool, CommandantError<ClientError>><\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "T : ArgumentProtocol<\/Type><\/Declaration>", + "key.column" : 25, + "key.decl_lang" : "source.lang.swift", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 16, + "key.offset" : 2095 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "T<\/decl.generic_type_param.name> : ArgumentProtocol<\/ref.protocol><\/decl.generic_type_param.constraint><\/decl.generic_type_param>", + "key.inheritedtypes" : [ + { + "key.name" : "ArgumentProtocol" + } + ], + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 19, + "key.line" : 61, + "key.modulename" : "Commandant", + "key.name" : "T", + "key.namelength" : 1, + "key.nameoffset" : 2092, + "key.offset" : 2092, + "key.parsed_declaration" : "public static func <| ClientError<\/Declaration>", + "key.column" : 46, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 61, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 2113, + "key.offset" : 2113, + "key.parsed_declaration" : "public static func <| (CommandMode.Type) -> (CommandMode, Argument) -> Result>", + "key.typeusr" : "$sys6ResultOyx10Commandant0B5ErrorOyq_GGAC11CommandModeO_AC8ArgumentVyxGtcAC0F8ProtocolRzr0_luD", + "key.usr" : "s:10Commandant11CommandModeO2looiys6ResultOyxAA0A5ErrorOyq_GGAC_AA8ArgumentVyxGtAA0G8ProtocolRzr0_lFZ" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public static func <| <T, ClientError>(mode: CommandMode<\/Type>, argument: Argument<\/Type><[T<\/Type>]>) -> Result<\/Type><[T<\/Type>], CommandantError<\/Type><ClientError<\/Type>>> where T<\/Type> : ArgumentProtocol<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 2929 + } + ], + "key.bodylength" : 778, + "key.bodyoffset" : 3076, + "key.column" : 21, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Evaluates the given argument list in the given mode.\n\nIf parsing command line arguments, and no value was specified on the command\nline, the argument's `defaultValue` is used.", + "key.doc.column" : 21, + "key.doc.comment" : "Evaluates the given argument list in the given mode.\n\nIf parsing command line arguments, and no value was specified on the command\nline, the argument's `defaultValue` is used.", + "key.doc.declaration" : "public static func <| (mode: CommandMode, argument: Argument<[T]>) -> Result<[T], CommandantError> where T : Commandant.ArgumentProtocol", + "key.doc.discussion" : [ + { + "Para" : "If parsing command line arguments, and no value was specified on the command line, the argument’s `defaultValue` is used." + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Argument.swift", + "key.doc.full_as_xml" : "<|(_:_:)<\/Name>s:10Commandant11CommandModeO2looiys6ResultOySayxGAA0A5ErrorOyq_GGAC_AA8ArgumentVyAGGtAA0G8ProtocolRzr0_lFZ<\/USR>public static func <| <T, ClientError>(mode: CommandMode, argument: Argument<[T]>) -> Result<[T], CommandantError<ClientError>> where T : Commandant.ArgumentProtocol<\/Declaration>Evaluates the given argument list in the given mode.<\/Para><\/Abstract>If parsing command line arguments, and no value was specified on the command line, the argument’s defaultValue<\/codeVoice> is used.<\/Para><\/Discussion><\/CommentParts><\/Function>", + "key.doc.line" : 87, + "key.doc.name" : "<|(_:_:)", + "key.doc.type" : "Function", + "key.doclength" : 194, + "key.docoffset" : 2734, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> static<\/syntaxtype.keyword> func<\/syntaxtype.keyword> <| <\/decl.name><T<\/decl.generic_type_param.name><\/decl.generic_type_param>, ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>>(mode<\/decl.var.parameter.name>: CommandMode<\/ref.enum><\/decl.var.parameter.type><\/decl.var.parameter>, argument<\/decl.var.parameter.name>: Argument<\/ref.struct><[T<\/ref.generic_type_param>]><\/decl.var.parameter.type><\/decl.var.parameter>) -> Result<\/ref.enum><[T<\/ref.generic_type_param>], CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>>><\/decl.function.returntype> where<\/syntaxtype.keyword> T<\/ref.generic_type_param> : ArgumentProtocol<\/ref.protocol><\/decl.generic_type_requirement><\/decl.function.operator.infix>", + "key.kind" : "source.lang.swift.decl.function.method.static", + "key.length" : 919, + "key.line" : 87, + "key.modulename" : "Commandant", + "key.name" : "<|(_:_:)", + "key.namelength" : 81, + "key.nameoffset" : 2948, + "key.offset" : 2936, + "key.parsed_declaration" : "public static func <| (mode: CommandMode, argument: Argument<[T]>) -> Result<[T], CommandantError>", + "key.parsed_scope.end" : 119, + "key.parsed_scope.start" : 87, + "key.related_decls" : [ + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Argument<T>) -> Result<T, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<T>) -> Result<T, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<T?>) -> Result<T?, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<[T]>) -> Result<[T], CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<[T]?>) -> Result<[T]?, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <ClientError>(_: CommandMode, _: Option<Bool>) -> Result<Bool, CommandantError<ClientError>><\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <ClientError>(_: CommandMode, _: Switch) -> Result<Bool, CommandantError<ClientError>><\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "T : ArgumentProtocol<\/Type><\/Declaration>", + "key.column" : 25, + "key.decl_lang" : "source.lang.swift", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 16, + "key.offset" : 2955 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "T<\/decl.generic_type_param.name> : ArgumentProtocol<\/ref.protocol><\/decl.generic_type_param.constraint><\/decl.generic_type_param>", + "key.inheritedtypes" : [ + { + "key.name" : "ArgumentProtocol" + } + ], + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 19, + "key.line" : 87, + "key.modulename" : "Commandant", + "key.name" : "T", + "key.namelength" : 1, + "key.nameoffset" : 2952, + "key.offset" : 2952, + "key.parsed_declaration" : "public static func <| ClientError<\/Declaration>", + "key.column" : 46, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 87, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 2973, + "key.offset" : 2973, + "key.parsed_declaration" : "public static func <| (CommandMode.Type) -> (CommandMode, Argument<[T]>) -> Result<[T], CommandantError>", + "key.typeusr" : "$sys6ResultOySayxG10Commandant0B5ErrorOyq_GGAD11CommandModeO_AD8ArgumentVyACGtcAD0F8ProtocolRzr0_luD", + "key.usr" : "s:10Commandant11CommandModeO2looiys6ResultOySayxGAA0A5ErrorOyq_GGAC_AA8ArgumentVyAGGtAA0G8ProtocolRzr0_lFZ" + } + ], + "key.typename" : "CommandMode.Type", + "key.typeusr" : "$s10Commandant11CommandModeOmD", + "key.usr" : "s:10Commandant11CommandModeO" + } + ] + } +}, { + "\/Sources\/Commandant\/ArgumentParser.swift" : { + "key.diagnostic_stage" : "source.diagnostic.stage.swift.parse", + "key.length" : 4637, + "key.offset" : 0, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.private", + "key.annotated_decl" : "private enum RawArgument : Equatable<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.private", + "key.length" : 7, + "key.offset" : 229 + } + ], + "key.bodylength" : 296, + "key.bodyoffset" : 266, + "key.column" : 14, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Represents an argument passed on the command line.", + "key.doc.column" : 14, + "key.doc.comment" : "Represents an argument passed on the command line.", + "key.doc.declaration" : "private enum RawArgument : Equatable", + "key.doc.file" : "\/private\/Sources\/Commandant\/ArgumentParser.swift", + "key.doc.full_as_xml" : "RawArgument<\/Name>s:10Commandant11RawArgument33_BA859BFBBE9DF3838A11641CB273713ELLO<\/USR>private enum RawArgument : Equatable<\/Declaration>Represents an argument passed on the command line.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 12, + "key.doc.name" : "RawArgument", + "key.doc.type" : "Other", + "key.doclength" : 55, + "key.docoffset" : 174, + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 9, + "key.offset" : 255 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "private<\/syntaxtype.keyword> enum<\/syntaxtype.keyword> RawArgument<\/decl.name> : Equatable<\/ref.protocol><\/decl.enum>", + "key.inheritedtypes" : [ + { + "key.name" : "Equatable" + } + ], + "key.kind" : "source.lang.swift.decl.enum", + "key.length" : 326, + "key.line" : 12, + "key.modulename" : "Commandant", + "key.name" : "RawArgument", + "key.namelength" : 11, + "key.nameoffset" : 242, + "key.offset" : 237, + "key.parsed_declaration" : "private enum RawArgument: Equatable", + "key.parsed_scope.end" : 22, + "key.parsed_scope.start" : 12, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.kind" : "source.lang.swift.decl.enumcase", + "key.length" : 16, + "key.offset" : 341, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "case key(String<\/Type>)<\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A key corresponding to an option (e.g., `verbose` for `--verbose`).", + "key.doc.column" : 7, + "key.doc.comment" : "A key corresponding to an option (e.g., `verbose` for `--verbose`).", + "key.doc.declaration" : "", + "key.doc.file" : "\/private\/Sources\/Commandant\/ArgumentParser.swift", + "key.doc.full_as_xml" : "key(_:)<\/Name>s:10Commandant11RawArgument33_BA859BFBBE9DF3838A11641CB273713ELLO3keyyADSScADmF<\/USR><\/Declaration>A key corresponding to an option (e.g., verbose<\/codeVoice> for --verbose<\/codeVoice>).<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 14, + "key.doc.name" : "key(_:)", + "key.doc.type" : "Other", + "key.doclength" : 72, + "key.docoffset" : 268, + "key.filepath" : "", + "key.fully_annotated_decl" : "case<\/syntaxtype.keyword> key<\/decl.name>(String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>)<\/decl.enumelement>", + "key.kind" : "source.lang.swift.decl.enumelement", + "key.length" : 11, + "key.line" : 14, + "key.modulename" : "Commandant", + "key.name" : "key(_:)", + "key.namelength" : 11, + "key.nameoffset" : 346, + "key.offset" : 346, + "key.parsed_declaration" : "case key(String)", + "key.parsed_scope.end" : 14, + "key.parsed_scope.start" : 14, + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : "(RawArgument.Type) -> (String) -> RawArgument", + "key.typeusr" : "$sy10Commandant11RawArgument33_BA859BFBBE9DF3838A11641CB273713ELLOSScADmcD", + "key.usr" : "s:10Commandant11RawArgument33_BA859BFBBE9DF3838A11641CB273713ELLO3keyyADSScADmF" + } + ] + }, + { + "key.kind" : "source.lang.swift.decl.enumcase", + "key.length" : 18, + "key.offset" : 448, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "case value(String<\/Type>)<\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A value, either associated with an option or passed as a positional\nargument.", + "key.doc.column" : 7, + "key.doc.comment" : "A value, either associated with an option or passed as a positional\nargument.", + "key.doc.declaration" : "", + "key.doc.file" : "\/private\/Sources\/Commandant\/ArgumentParser.swift", + "key.doc.full_as_xml" : "value(_:)<\/Name>s:10Commandant11RawArgument33_BA859BFBBE9DF3838A11641CB273713ELLO5valueyADSScADmF<\/USR><\/Declaration>A value, either associated with an option or passed as a positional argument.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 18, + "key.doc.name" : "value(_:)", + "key.doc.type" : "Other", + "key.doclength" : 87, + "key.docoffset" : 360, + "key.filepath" : "", + "key.fully_annotated_decl" : "case<\/syntaxtype.keyword> value<\/decl.name>(String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>)<\/decl.enumelement>", + "key.kind" : "source.lang.swift.decl.enumelement", + "key.length" : 13, + "key.line" : 18, + "key.modulename" : "Commandant", + "key.name" : "value(_:)", + "key.namelength" : 13, + "key.nameoffset" : 453, + "key.offset" : 453, + "key.parsed_declaration" : "case value(String)", + "key.parsed_scope.end" : 18, + "key.parsed_scope.start" : 18, + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : "(RawArgument.Type) -> (String) -> RawArgument", + "key.typeusr" : "$sy10Commandant11RawArgument33_BA859BFBBE9DF3838A11641CB273713ELLOSScADmcD", + "key.usr" : "s:10Commandant11RawArgument33_BA859BFBBE9DF3838A11641CB273713ELLO5valueyADSScADmF" + } + ] + }, + { + "key.kind" : "source.lang.swift.decl.enumcase", + "key.length" : 32, + "key.offset" : 529, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "case flag(OrderedSet<\/Type><Character<\/Type>>)<\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "One or more flag arguments (e.g 'r' and 'f' for `-rf`)", + "key.doc.column" : 7, + "key.doc.comment" : "One or more flag arguments (e.g 'r' and 'f' for `-rf`)", + "key.doc.declaration" : "", + "key.doc.file" : "\/private\/Sources\/Commandant\/ArgumentParser.swift", + "key.doc.full_as_xml" : "flag(_:)<\/Name>s:10Commandant11RawArgument33_BA859BFBBE9DF3838A11641CB273713ELLO4flagyAdA10OrderedSetVySJGcADmF<\/USR><\/Declaration>One or more flag arguments (e.g ‘r’ and ‘f’ for -rf<\/codeVoice>)<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 21, + "key.doc.name" : "flag(_:)", + "key.doc.type" : "Other", + "key.doclength" : 59, + "key.docoffset" : 469, + "key.filepath" : "", + "key.fully_annotated_decl" : "case<\/syntaxtype.keyword> flag<\/decl.name>(OrderedSet<\/ref.struct><Character<\/ref.struct>><\/decl.var.parameter.type><\/decl.var.parameter>)<\/decl.enumelement>", + "key.kind" : "source.lang.swift.decl.enumelement", + "key.length" : 27, + "key.line" : 21, + "key.modulename" : "Commandant", + "key.name" : "flag(_:)", + "key.namelength" : 27, + "key.nameoffset" : 534, + "key.offset" : 534, + "key.parsed_declaration" : "case flag(OrderedSet)", + "key.parsed_scope.end" : 21, + "key.parsed_scope.start" : 21, + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : "(RawArgument.Type) -> (OrderedSet) -> RawArgument", + "key.typeusr" : "$sy10Commandant11RawArgument33_BA859BFBBE9DF3838A11641CB273713ELLOAA10OrderedSetVySJGcADmcD", + "key.usr" : "s:10Commandant11RawArgument33_BA859BFBBE9DF3838A11641CB273713ELLO4flagyAdA10OrderedSetVySJGcADmF" + } + ] + } + ], + "key.typename" : "RawArgument.Type", + "key.typeusr" : "$s10Commandant11RawArgument33_BA859BFBBE9DF3838A11641CB273713ELLOmD", + "key.usr" : "s:10Commandant11RawArgument33_BA859BFBBE9DF3838A11641CB273713ELLO" + }, + { + "key.annotated_decl" : "private enum RawArgument : Equatable<\/Type><\/Declaration>", + "key.bodylength" : 214, + "key.bodyoffset" : 613, + "key.column" : 14, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Represents an argument passed on the command line.", + "key.doc.column" : 14, + "key.doc.declaration" : "private enum RawArgument : Equatable", + "key.doc.file" : "\/private\/Sources\/Commandant\/ArgumentParser.swift", + "key.doc.full_as_xml" : "RawArgument<\/Name>s:10Commandant11RawArgument33_BA859BFBBE9DF3838A11641CB273713ELLO<\/USR>private enum RawArgument : Equatable<\/Declaration>Represents an argument passed on the command line.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 12, + "key.doc.name" : "RawArgument", + "key.doc.type" : "Other", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 23, + "key.offset" : 588 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "private<\/syntaxtype.keyword> enum<\/syntaxtype.keyword> RawArgument<\/decl.name> : Equatable<\/ref.protocol><\/decl.enum>", + "key.inheritedtypes" : [ + { + "key.name" : "CustomStringConvertible" + } + ], + "key.kind" : "source.lang.swift.decl.extension", + "key.length" : 263, + "key.line" : 12, + "key.modulename" : "Commandant", + "key.name" : "RawArgument", + "key.namelength" : 11, + "key.nameoffset" : 575, + "key.offset" : 565, + "key.parsed_declaration" : "extension RawArgument: CustomStringConvertible", + "key.parsed_scope.end" : 37, + "key.parsed_scope.start" : 24, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.fileprivate", + "key.annotated_decl" : "fileprivate var description: String<\/Type> { get }<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.fileprivate", + "key.length" : 11, + "key.offset" : 615 + } + ], + "key.bodylength" : 173, + "key.bodyoffset" : 652, + "key.column" : 18, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A textual representation of this instance.\n\nCalling this property directly is discouraged. Instead, convert an\ninstance of any type to a string by using the `String(describing:)`\ninitializer. This initializer works with any type, and uses the custom\n`description` property for types that conform to\n`CustomStringConvertible`:\n\n struct Point: CustomStringConvertible {\n let x: Int, y: Int\n\n var description: String {\n return \"(\\(x), \\(y))\"\n }\n }\n\n let p = Point(x: 21, y: 30)\n let s = String(describing: p)\n print(s)\n \/\/ Prints \"(21, 30)\"\n\nThe conversion of `p` to a string in the assignment to `s` uses the\n`Point` type's `description` property.", + "key.doc.declaration" : "var description: String { get }", + "key.doc.discussion" : [ + { + "Para" : "Calling this property directly is discouraged. Instead, convert an instance of any type to a string by using the `String(describing:)` initializer. This initializer works with any type, and uses the custom `description` property for types that conform to `CustomStringConvertible`:" + }, + { + "CodeListing" : "" + }, + { + "Para" : "The conversion of `p` to a string in the assignment to `s` uses the `Point` type’s `description` property." + }, + { + "Note" : "" + } + ], + "key.doc.full_as_xml" : "description<\/Name>s:s23CustomStringConvertibleP11descriptionSSvp<\/USR>var description: String { get }<\/Declaration>A textual representation of this instance.<\/Para><\/Abstract>Calling this property directly is discouraged. Instead, convert an instance of any type to a string by using the String(describing:)<\/codeVoice> initializer. This initializer works with any type, and uses the custom description<\/codeVoice> property for types that conform to CustomStringConvertible<\/codeVoice>:<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>The conversion of p<\/codeVoice> to a string in the assignment to s<\/codeVoice> uses the Point<\/codeVoice> type’s description<\/codeVoice> property.<\/Para>This documentation comment was inherited from CustomStringConvertible<\/codeVoice>.<\/Para><\/Note><\/Discussion><\/CommentParts><\/Other>", + "key.doc.name" : "description", + "key.doc.type" : "Other", + "key.filepath" : "", + "key.fully_annotated_decl" : "fileprivate<\/syntaxtype.keyword> var<\/syntaxtype.keyword> description<\/decl.name>: String<\/ref.struct><\/decl.var.type> { get<\/syntaxtype.keyword> }<\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 199, + "key.line" : 25, + "key.modulename" : "Commandant", + "key.name" : "description", + "key.namelength" : 11, + "key.nameoffset" : 631, + "key.offset" : 627, + "key.overrides" : [ + { + "key.usr" : "s:s23CustomStringConvertibleP11descriptionSSvp" + } + ], + "key.parsed_declaration" : "fileprivate var description: String", + "key.parsed_scope.end" : 36, + "key.parsed_scope.start" : 25, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:s23CustomStringConvertibleP11descriptionSSvp" + } + ], + "key.typename" : "RawArgument.Type", + "key.typeusr" : "$s10Commandant11RawArgument33_BA859BFBBE9DF3838A11641CB273713ELLOmD", + "key.usr" : "s:10Commandant11RawArgument33_BA859BFBBE9DF3838A11641CB273713ELLO" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public final class ArgumentParser<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.final", + "key.length" : 5, + "key.offset" : 896 + }, + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 889 + } + ], + "key.bodylength" : 3711, + "key.bodyoffset" : 924, + "key.column" : 20, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Destructively parses a list of command-line arguments.", + "key.doc.column" : 20, + "key.doc.comment" : "Destructively parses a list of command-line arguments.", + "key.doc.declaration" : "public final class ArgumentParser", + "key.doc.file" : "\/private\/Sources\/Commandant\/ArgumentParser.swift", + "key.doc.full_as_xml" : "ArgumentParser<\/Name>s:10Commandant14ArgumentParserC<\/USR>public final class ArgumentParser<\/Declaration>Destructively parses a list of command-line arguments.<\/Para><\/Abstract><\/CommentParts><\/Class>", + "key.doc.line" : 40, + "key.doc.name" : "ArgumentParser", + "key.doc.type" : "Class", + "key.doclength" : 59, + "key.docoffset" : 830, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> final<\/syntaxtype.keyword> class<\/syntaxtype.keyword> ArgumentParser<\/decl.name><\/decl.class>", + "key.kind" : "source.lang.swift.decl.class", + "key.length" : 3734, + "key.line" : 40, + "key.modulename" : "Commandant", + "key.name" : "ArgumentParser", + "key.namelength" : 14, + "key.nameoffset" : 908, + "key.offset" : 902, + "key.parsed_declaration" : "public final class ArgumentParser", + "key.parsed_scope.end" : 175, + "key.parsed_scope.start" : 40, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.private", + "key.annotated_decl" : "private var rawArguments: [RawArgument<\/Type>]<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.private", + "key.length" : 7, + "key.offset" : 991 + } + ], + "key.column" : 14, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "The remaining arguments to be extracted, in their raw form.", + "key.doc.column" : 14, + "key.doc.comment" : "The remaining arguments to be extracted, in their raw form.", + "key.doc.declaration" : "private var rawArguments: [RawArgument]", + "key.doc.file" : "\/private\/Sources\/Commandant\/ArgumentParser.swift", + "key.doc.full_as_xml" : "rawArguments<\/Name>s:10Commandant14ArgumentParserC12rawArguments33_BA859BFBBE9DF3838A11641CB273713ELLSayAA03RawB0AELLOGvp<\/USR>private var rawArguments: [RawArgument]<\/Declaration>The remaining arguments to be extracted, in their raw form.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 42, + "key.doc.name" : "rawArguments", + "key.doc.type" : "Other", + "key.doclength" : 64, + "key.docoffset" : 926, + "key.filepath" : "", + "key.fully_annotated_decl" : "private<\/syntaxtype.keyword> var<\/syntaxtype.keyword> rawArguments<\/decl.name>: [RawArgument<\/ref.enum>]<\/decl.var.type><\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 36, + "key.line" : 42, + "key.modulename" : "Commandant", + "key.name" : "rawArguments", + "key.namelength" : 12, + "key.nameoffset" : 1003, + "key.offset" : 999, + "key.parsed_declaration" : "private var rawArguments: [RawArgument] = []", + "key.parsed_scope.end" : 42, + "key.parsed_scope.start" : 42, + "key.reusingastcontext" : false, + "key.setter_accessibility" : "source.lang.swift.accessibility.private", + "key.typename" : "[RawArgument]", + "key.typeusr" : "$sSay10Commandant11RawArgument33_BA859BFBBE9DF3838A11641CB273713ELLOGD", + "key.usr" : "s:10Commandant14ArgumentParserC12rawArguments33_BA859BFBBE9DF3838A11641CB273713ELLSayAA03RawB0AELLOGvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public init(_ arguments: [String<\/Type>])<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 1115 + } + ], + "key.bodylength" : 741, + "key.bodyoffset" : 1151, + "key.column" : 9, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Initializes the generator from a simple list of command-line arguments.", + "key.doc.column" : 9, + "key.doc.comment" : "Initializes the generator from a simple list of command-line arguments.", + "key.doc.declaration" : "public init(_ arguments: [String])", + "key.doc.file" : "\/private\/Sources\/Commandant\/ArgumentParser.swift", + "key.doc.full_as_xml" : "init(_:)<\/Name>s:10Commandant14ArgumentParserCyACSaySSGcfc<\/USR>public init(_ arguments: [String])<\/Declaration>Initializes the generator from a simple list of command-line arguments.<\/Para><\/Abstract><\/CommentParts><\/Function>", + "key.doc.line" : 45, + "key.doc.name" : "init(_:)", + "key.doc.type" : "Function", + "key.doclength" : 76, + "key.docoffset" : 1038, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> init<\/syntaxtype.keyword>(_<\/decl.var.parameter.argument_label> arguments<\/decl.var.parameter.name>: [String<\/ref.struct>]<\/decl.var.parameter.type><\/decl.var.parameter>)<\/decl.function.constructor>", + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 771, + "key.line" : 45, + "key.modulename" : "Commandant", + "key.name" : "init(_:)", + "key.namelength" : 27, + "key.nameoffset" : 1122, + "key.offset" : 1122, + "key.parsed_declaration" : "public init(_ arguments: [String])", + "key.parsed_scope.end" : 70, + "key.parsed_scope.start" : 45, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "let params: [Array<\/Type><String<\/Type>>.SubSequence<\/Type>]<\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "let<\/syntaxtype.keyword> params<\/decl.name>: [Array<\/ref.struct><String<\/ref.struct>>.SubSequence<\/ref.typealias>]<\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 91, + "key.line" : 47, + "key.modulename" : "Commandant", + "key.name" : "params", + "key.namelength" : 6, + "key.nameoffset" : 1218, + "key.offset" : 1214, + "key.parsed_declaration" : "let params = arguments.split(maxSplits: 1, omittingEmptySubsequences: false) { $0 == \"--\" }", + "key.parsed_scope.end" : 47, + "key.parsed_scope.start" : 47, + "key.reusingastcontext" : false, + "key.typename" : "[ArraySlice]", + "key.typeusr" : "$sSays10ArraySliceVySSGGD", + "key.usr" : "s:10Commandant14ArgumentParserCyACSaySSGcfc6paramsL_Says10ArraySliceVySSGGvp" + }, + { + "key.annotated_decl" : "let options: Array<\/Type><String<\/Type>>.SubSequence<\/Type><\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "let<\/syntaxtype.keyword> options<\/decl.name>: Array<\/ref.struct><String<\/ref.struct>>.SubSequence<\/ref.typealias><\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 27, + "key.line" : 50, + "key.modulename" : "Commandant", + "key.name" : "options", + "key.namelength" : 7, + "key.nameoffset" : 1356, + "key.offset" : 1352, + "key.parsed_declaration" : "let options = params.first!", + "key.parsed_scope.end" : 50, + "key.parsed_scope.start" : 50, + "key.reusingastcontext" : false, + "key.typename" : "ArraySlice", + "key.typeusr" : "$ss10ArraySliceVySSGD", + "key.usr" : "s:10Commandant14ArgumentParserCyACSaySSGcfc7optionsL_s10ArraySliceVySSGvp" + } + ], + "key.typename" : "(ArgumentParser.Type) -> ([String]) -> ArgumentParser", + "key.typeusr" : "$sy10Commandant14ArgumentParserCSaySSGcD", + "key.usr" : "s:10Commandant14ArgumentParserCyACSaySSGcfc" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "internal var remainingArguments: [String<\/Type>]? { get }<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.internal", + "key.length" : 8, + "key.offset" : 1934 + } + ], + "key.bodylength" : 76, + "key.bodyoffset" : 1978, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Returns the remaining arguments.", + "key.doc.column" : 15, + "key.doc.comment" : "Returns the remaining arguments.", + "key.doc.declaration" : "internal var remainingArguments: [String]? { get }", + "key.doc.file" : "\/private\/Sources\/Commandant\/ArgumentParser.swift", + "key.doc.full_as_xml" : "remainingArguments<\/Name>s:10Commandant14ArgumentParserC18remainingArgumentsSaySSGSgvp<\/USR>internal var remainingArguments: [String]? { get }<\/Declaration>Returns the remaining arguments.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 73, + "key.doc.name" : "remainingArguments", + "key.doc.type" : "Other", + "key.doclength" : 37, + "key.docoffset" : 1896, + "key.filepath" : "", + "key.fully_annotated_decl" : "internal<\/syntaxtype.keyword> var<\/syntaxtype.keyword> remainingArguments<\/decl.name>: [String<\/ref.struct>]?<\/decl.var.type> { get<\/syntaxtype.keyword> }<\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 112, + "key.line" : 73, + "key.modulename" : "Commandant", + "key.name" : "remainingArguments", + "key.namelength" : 18, + "key.nameoffset" : 1947, + "key.offset" : 1943, + "key.parsed_declaration" : "internal var remainingArguments: [String]?", + "key.parsed_scope.end" : 75, + "key.parsed_scope.start" : 73, + "key.reusingastcontext" : false, + "key.typename" : "[String]?", + "key.typeusr" : "$sSaySSGSgD", + "key.usr" : "s:10Commandant14ArgumentParserC18remainingArgumentsSaySSGSgvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "internal func consumeBoolean(forKey key: String<\/Type>) -> Bool<\/Type>?<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.internal", + "key.length" : 8, + "key.offset" : 2264 + } + ], + "key.bodylength" : 281, + "key.bodyoffset" : 2323, + "key.column" : 16, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Returns whether the given key was enabled or disabled, or nil if it\nwas not given at all.\n\nIf the key is found, it is then removed from the list of arguments\nremaining to be parsed.", + "key.doc.column" : 16, + "key.doc.comment" : "Returns whether the given key was enabled or disabled, or nil if it\nwas not given at all.\n\nIf the key is found, it is then removed from the list of arguments\nremaining to be parsed.", + "key.doc.declaration" : "internal func consumeBoolean(forKey key: String) -> Bool?", + "key.doc.discussion" : [ + { + "Para" : "If the key is found, it is then removed from the list of arguments remaining to be parsed." + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/ArgumentParser.swift", + "key.doc.full_as_xml" : "consumeBoolean(forKey:)<\/Name>s:10Commandant14ArgumentParserC14consumeBoolean6forKeySbSgSS_tF<\/USR>internal func consumeBoolean(forKey key: String) -> Bool?<\/Declaration>Returns whether the given key was enabled or disabled, or nil if it was not given at all.<\/Para><\/Abstract>If the key is found, it is then removed from the list of arguments remaining to be parsed.<\/Para><\/Discussion><\/CommentParts><\/Function>", + "key.doc.line" : 82, + "key.doc.name" : "consumeBoolean(forKey:)", + "key.doc.type" : "Function", + "key.doclength" : 205, + "key.docoffset" : 2058, + "key.filepath" : "", + "key.fully_annotated_decl" : "internal<\/syntaxtype.keyword> func<\/syntaxtype.keyword> consumeBoolean<\/decl.name>(forKey<\/decl.var.parameter.argument_label> key<\/decl.var.parameter.name>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>) -> Bool<\/ref.struct>?<\/decl.function.returntype><\/decl.function.method.instance>", + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 332, + "key.line" : 82, + "key.modulename" : "Commandant", + "key.name" : "consumeBoolean(forKey:)", + "key.namelength" : 34, + "key.nameoffset" : 2278, + "key.offset" : 2273, + "key.parsed_declaration" : "internal func consumeBoolean(forKey key: String) -> Bool?", + "key.parsed_scope.end" : 98, + "key.parsed_scope.start" : 82, + "key.related_decls" : [ + { + "key.annotated_decl" : "consumeBoolean(flag:)<\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "let oldArguments: [RawArgument<\/Type>]<\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "let<\/syntaxtype.keyword> oldArguments<\/decl.name>: [RawArgument<\/ref.enum>]<\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 31, + "key.line" : 83, + "key.modulename" : "Commandant", + "key.name" : "oldArguments", + "key.namelength" : 12, + "key.nameoffset" : 2330, + "key.offset" : 2326, + "key.parsed_declaration" : "let oldArguments = rawArguments", + "key.parsed_scope.end" : 83, + "key.parsed_scope.start" : 83, + "key.reusingastcontext" : false, + "key.typename" : "[RawArgument]", + "key.typeusr" : "$sSay10Commandant11RawArgument33_BA859BFBBE9DF3838A11641CB273713ELLOGD", + "key.usr" : "s:10Commandant14ArgumentParserC14consumeBoolean6forKeySbSgSS_tF12oldArgumentsL_SayAA03RawB033_BA859BFBBE9DF3838A11641CB273713ELLOGvp" + }, + { + "key.annotated_decl" : "var result: Bool<\/Type>?<\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "var<\/syntaxtype.keyword> result<\/decl.name>: Bool<\/ref.struct>?<\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 17, + "key.line" : 86, + "key.modulename" : "Commandant", + "key.name" : "result", + "key.namelength" : 6, + "key.nameoffset" : 2392, + "key.offset" : 2388, + "key.parsed_declaration" : "var result: Bool?", + "key.parsed_scope.end" : 86, + "key.parsed_scope.start" : 86, + "key.reusingastcontext" : false, + "key.typename" : "Bool?", + "key.typeusr" : "$sSbSgD", + "key.usr" : "s:10Commandant14ArgumentParserC14consumeBoolean6forKeySbSgSS_tF6resultL_AFvp" + } + ], + "key.typename" : "(ArgumentParser) -> (String) -> Bool?", + "key.typeusr" : "$s6forKeySbSgSS_tcD", + "key.usr" : "s:10Commandant14ArgumentParserC14consumeBoolean6forKeySbSgSS_tF" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "internal func consumeValue(forKey key: String<\/Type>) -> Result<\/Type><String<\/Type>?, CommandantError<\/Type><Never<\/Type>>><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.internal", + "key.length" : 8, + "key.offset" : 2908 + } + ], + "key.bodylength" : 503, + "key.bodyoffset" : 2999, + "key.column" : 16, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Returns the value associated with the given flag, or nil if the flag was\nnot specified. If the key is presented, but no value was given, an error\nis returned.\n\nIf a value is found, the key and the value are both removed from the\nlist of arguments remaining to be parsed.", + "key.doc.column" : 16, + "key.doc.comment" : "Returns the value associated with the given flag, or nil if the flag was\nnot specified. If the key is presented, but no value was given, an error\nis returned.\n\nIf a value is found, the key and the value are both removed from the\nlist of arguments remaining to be parsed.", + "key.doc.declaration" : "internal func consumeValue(forKey key: String) -> Result>", + "key.doc.discussion" : [ + { + "Para" : "If a value is found, the key and the value are both removed from the list of arguments remaining to be parsed." + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/ArgumentParser.swift", + "key.doc.full_as_xml" : "consumeValue(forKey:)<\/Name>s:10Commandant14ArgumentParserC12consumeValue6forKeys6ResultOySSSgAA0A5ErrorOys5NeverOGGSS_tF<\/USR>internal func consumeValue(forKey key: String) -> Result<String?, CommandantError<Never>><\/Declaration>Returns the value associated with the given flag, or nil if the flag was not specified. If the key is presented, but no value was given, an error is returned.<\/Para><\/Abstract>If a value is found, the key and the value are both removed from the list of arguments remaining to be parsed.<\/Para><\/Discussion><\/CommentParts><\/Function>", + "key.doc.line" : 106, + "key.doc.name" : "consumeValue(forKey:)", + "key.doc.type" : "Function", + "key.doclength" : 299, + "key.docoffset" : 2608, + "key.filepath" : "", + "key.fully_annotated_decl" : "internal<\/syntaxtype.keyword> func<\/syntaxtype.keyword> consumeValue<\/decl.name>(forKey<\/decl.var.parameter.argument_label> key<\/decl.var.parameter.name>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>) -> Result<\/ref.enum><String<\/ref.struct>?, CommandantError<\/ref.enum><Never<\/ref.enum>>><\/decl.function.returntype><\/decl.function.method.instance>", + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 586, + "key.line" : 106, + "key.modulename" : "Commandant", + "key.name" : "consumeValue(forKey:)", + "key.namelength" : 32, + "key.nameoffset" : 2922, + "key.offset" : 2917, + "key.parsed_declaration" : "internal func consumeValue(forKey key: String) -> Result>", + "key.parsed_scope.end" : 131, + "key.parsed_scope.start" : 106, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "let oldArguments: [RawArgument<\/Type>]<\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "let<\/syntaxtype.keyword> oldArguments<\/decl.name>: [RawArgument<\/ref.enum>]<\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 31, + "key.line" : 107, + "key.modulename" : "Commandant", + "key.name" : "oldArguments", + "key.namelength" : 12, + "key.nameoffset" : 3006, + "key.offset" : 3002, + "key.parsed_declaration" : "let oldArguments = rawArguments", + "key.parsed_scope.end" : 107, + "key.parsed_scope.start" : 107, + "key.reusingastcontext" : false, + "key.typename" : "[RawArgument]", + "key.typeusr" : "$sSay10Commandant11RawArgument33_BA859BFBBE9DF3838A11641CB273713ELLOGD", + "key.usr" : "s:10Commandant14ArgumentParserC12consumeValue6forKeys6ResultOySSSgAA0A5ErrorOys5NeverOGGSS_tF12oldArgumentsL_SayAA03RawB033_BA859BFBBE9DF3838A11641CB273713ELLOGvp" + }, + { + "key.annotated_decl" : "var foundValue: String<\/Type>?<\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "var<\/syntaxtype.keyword> foundValue<\/decl.name>: String<\/ref.struct>?<\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 23, + "key.line" : 110, + "key.modulename" : "Commandant", + "key.name" : "foundValue", + "key.namelength" : 10, + "key.nameoffset" : 3068, + "key.offset" : 3064, + "key.parsed_declaration" : "var foundValue: String?", + "key.parsed_scope.end" : 110, + "key.parsed_scope.start" : 110, + "key.reusingastcontext" : false, + "key.typename" : "String?", + "key.typeusr" : "$sSSSgD", + "key.usr" : "s:10Commandant14ArgumentParserC12consumeValue6forKeys6ResultOySSSgAA0A5ErrorOys5NeverOGGSS_tF05foundE0L_AHvp" + }, + { + "key.annotated_decl" : "var index: Int<\/Type><\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "var<\/syntaxtype.keyword> index<\/decl.name>: Int<\/ref.struct><\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 13, + "key.line" : 111, + "key.modulename" : "Commandant", + "key.name" : "index", + "key.namelength" : 5, + "key.nameoffset" : 3094, + "key.offset" : 3090, + "key.parsed_declaration" : "var index = 0", + "key.parsed_scope.end" : 111, + "key.parsed_scope.start" : 111, + "key.related_decls" : [ + { + "key.annotated_decl" : "index(_:_:)<\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.typename" : "Int", + "key.typeusr" : "$sSiD", + "key.usr" : "s:10Commandant14ArgumentParserC12consumeValue6forKeys6ResultOySSSgAA0A5ErrorOys5NeverOGGSS_tF5indexL_Sivp" + } + ], + "key.typename" : "(ArgumentParser) -> (String) -> Result>", + "key.typeusr" : "$s6forKeys6ResultOySSSg10Commandant0D5ErrorOys5NeverOGGSS_tcD", + "key.usr" : "s:10Commandant14ArgumentParserC12consumeValue6forKeys6ResultOySSSgAA0A5ErrorOys5NeverOGGSS_tF" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "internal func consumePositionalArgument() -> String<\/Type>?<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.internal", + "key.length" : 8, + "key.offset" : 3634 + } + ], + "key.bodylength" : 164, + "key.bodyoffset" : 3688, + "key.column" : 16, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Returns the next positional argument that hasn't yet been returned, or\nnil if there are no more positional arguments.", + "key.doc.column" : 16, + "key.doc.comment" : "Returns the next positional argument that hasn't yet been returned, or\nnil if there are no more positional arguments.", + "key.doc.declaration" : "internal func consumePositionalArgument() -> String?", + "key.doc.file" : "\/private\/Sources\/Commandant\/ArgumentParser.swift", + "key.doc.full_as_xml" : "consumePositionalArgument()<\/Name>s:10Commandant14ArgumentParserC017consumePositionalB0SSSgyF<\/USR>internal func consumePositionalArgument() -> String?<\/Declaration>Returns the next positional argument that hasn’t yet been returned, or nil if there are no more positional arguments.<\/Para><\/Abstract><\/CommentParts><\/Function>", + "key.doc.line" : 135, + "key.doc.name" : "consumePositionalArgument()", + "key.doc.type" : "Function", + "key.doclength" : 127, + "key.docoffset" : 3506, + "key.filepath" : "", + "key.fully_annotated_decl" : "internal<\/syntaxtype.keyword> func<\/syntaxtype.keyword> consumePositionalArgument<\/decl.name>() -> String<\/ref.struct>?<\/decl.function.returntype><\/decl.function.method.instance>", + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 210, + "key.line" : 135, + "key.modulename" : "Commandant", + "key.name" : "consumePositionalArgument()", + "key.namelength" : 27, + "key.nameoffset" : 3648, + "key.offset" : 3643, + "key.parsed_declaration" : "internal func consumePositionalArgument() -> String?", + "key.parsed_scope.end" : 144, + "key.parsed_scope.start" : 135, + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : "(ArgumentParser) -> () -> String?", + "key.typeusr" : "$sSSSgycD", + "key.usr" : "s:10Commandant14ArgumentParserC017consumePositionalB0SSSgyF" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "internal func consume(key: String<\/Type>) -> Bool<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.internal", + "key.length" : 8, + "key.offset" : 3963 + } + ], + "key.bodylength" : 143, + "key.bodyoffset" : 4007, + "key.column" : 16, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Returns whether the given key was specified and removes it from the\nlist of arguments remaining.", + "key.doc.column" : 16, + "key.doc.comment" : "Returns whether the given key was specified and removes it from the\nlist of arguments remaining.", + "key.doc.declaration" : "internal func consume(key: String) -> Bool", + "key.doc.file" : "\/private\/Sources\/Commandant\/ArgumentParser.swift", + "key.doc.full_as_xml" : "consume(key:)<\/Name>s:10Commandant14ArgumentParserC7consume3keySbSS_tF<\/USR>internal func consume(key: String) -> Bool<\/Declaration>Returns whether the given key was specified and removes it from the list of arguments remaining.<\/Para><\/Abstract><\/CommentParts><\/Function>", + "key.doc.line" : 148, + "key.doc.name" : "consume(key:)", + "key.doc.type" : "Function", + "key.doclength" : 106, + "key.docoffset" : 3856, + "key.filepath" : "", + "key.fully_annotated_decl" : "internal<\/syntaxtype.keyword> func<\/syntaxtype.keyword> consume<\/decl.name>(key<\/decl.var.parameter.argument_label>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>) -> Bool<\/ref.struct><\/decl.function.returntype><\/decl.function.method.instance>", + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 179, + "key.line" : 148, + "key.modulename" : "Commandant", + "key.name" : "consume(key:)", + "key.namelength" : 20, + "key.nameoffset" : 3977, + "key.offset" : 3972, + "key.parsed_declaration" : "internal func consume(key: String) -> Bool", + "key.parsed_scope.end" : 153, + "key.parsed_scope.start" : 148, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "let oldArguments: [RawArgument<\/Type>]<\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "let<\/syntaxtype.keyword> oldArguments<\/decl.name>: [RawArgument<\/ref.enum>]<\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 31, + "key.line" : 149, + "key.modulename" : "Commandant", + "key.name" : "oldArguments", + "key.namelength" : 12, + "key.nameoffset" : 4014, + "key.offset" : 4010, + "key.parsed_declaration" : "let oldArguments = rawArguments", + "key.parsed_scope.end" : 149, + "key.parsed_scope.start" : 149, + "key.reusingastcontext" : false, + "key.typename" : "[RawArgument]", + "key.typeusr" : "$sSay10Commandant11RawArgument33_BA859BFBBE9DF3838A11641CB273713ELLOGD", + "key.usr" : "s:10Commandant14ArgumentParserC7consume3keySbSS_tF12oldArgumentsL_SayAA03RawB033_BA859BFBBE9DF3838A11641CB273713ELLOGvp" + } + ], + "key.typename" : "(ArgumentParser) -> (String) -> Bool", + "key.typeusr" : "$s3keySbSS_tcD", + "key.usr" : "s:10Commandant14ArgumentParserC7consume3keySbSS_tF" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "internal func consumeBoolean(flag: Character<\/Type>) -> Bool<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.internal", + "key.length" : 8, + "key.offset" : 4262 + } + ], + "key.bodylength" : 316, + "key.bodyoffset" : 4317, + "key.column" : 16, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Returns whether the given flag was specified and removes it from the\nlist of arguments remaining.", + "key.doc.column" : 16, + "key.doc.comment" : "Returns whether the given flag was specified and removes it from the\nlist of arguments remaining.", + "key.doc.declaration" : "internal func consumeBoolean(flag: Character) -> Bool", + "key.doc.file" : "\/private\/Sources\/Commandant\/ArgumentParser.swift", + "key.doc.full_as_xml" : "consumeBoolean(flag:)<\/Name>s:10Commandant14ArgumentParserC14consumeBoolean4flagSbSJ_tF<\/USR>internal func consumeBoolean(flag: Character) -> Bool<\/Declaration>Returns whether the given flag was specified and removes it from the list of arguments remaining.<\/Para><\/Abstract><\/CommentParts><\/Function>", + "key.doc.line" : 157, + "key.doc.name" : "consumeBoolean(flag:)", + "key.doc.type" : "Function", + "key.doclength" : 107, + "key.docoffset" : 4154, + "key.filepath" : "", + "key.fully_annotated_decl" : "internal<\/syntaxtype.keyword> func<\/syntaxtype.keyword> consumeBoolean<\/decl.name>(flag<\/decl.var.parameter.argument_label>: Character<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>) -> Bool<\/ref.struct><\/decl.function.returntype><\/decl.function.method.instance>", + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 363, + "key.line" : 157, + "key.modulename" : "Commandant", + "key.name" : "consumeBoolean(flag:)", + "key.namelength" : 31, + "key.nameoffset" : 4276, + "key.offset" : 4271, + "key.parsed_declaration" : "internal func consumeBoolean(flag: Character) -> Bool", + "key.parsed_scope.end" : 174, + "key.parsed_scope.start" : 157, + "key.related_decls" : [ + { + "key.annotated_decl" : "consumeBoolean(forKey:)<\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : "(ArgumentParser) -> (Character) -> Bool", + "key.typeusr" : "$s4flagSbSJ_tcD", + "key.usr" : "s:10Commandant14ArgumentParserC14consumeBoolean4flagSbSJ_tF" + } + ], + "key.typename" : "ArgumentParser.Type", + "key.typeusr" : "$s10Commandant14ArgumentParserCmD", + "key.usr" : "s:10Commandant14ArgumentParserC" + } + ] + } +}, { + "\/Sources\/Commandant\/ArgumentProtocol.swift" : { + "key.diagnostic_stage" : "source.diagnostic.stage.swift.parse", + "key.length" : 1141, + "key.offset" : 0, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public protocol ArgumentProtocol<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 219 + } + ], + "key.bodylength" : 189, + "key.bodyoffset" : 253, + "key.column" : 17, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Represents a value that can be converted from a command-line argument.", + "key.doc.column" : 17, + "key.doc.comment" : "Represents a value that can be converted from a command-line argument.", + "key.doc.declaration" : "public protocol ArgumentProtocol", + "key.doc.file" : "\/private\/Sources\/Commandant\/ArgumentProtocol.swift", + "key.doc.full_as_xml" : "ArgumentProtocol<\/Name>s:10Commandant16ArgumentProtocolP<\/USR>public protocol ArgumentProtocol<\/Declaration>Represents a value that can be converted from a command-line argument.<\/Para><\/Abstract><\/CommentParts><\/Class>", + "key.doc.line" : 10, + "key.doc.name" : "ArgumentProtocol", + "key.doc.type" : "Class", + "key.doclength" : 75, + "key.docoffset" : 144, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> protocol<\/syntaxtype.keyword> ArgumentProtocol<\/decl.name><\/decl.protocol>", + "key.kind" : "source.lang.swift.decl.protocol", + "key.length" : 217, + "key.line" : 10, + "key.modulename" : "Commandant", + "key.name" : "ArgumentProtocol", + "key.namelength" : 16, + "key.nameoffset" : 235, + "key.offset" : 226, + "key.parsed_declaration" : "public protocol ArgumentProtocol", + "key.parsed_scope.end" : 16, + "key.parsed_scope.start" : 10, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "static var name: String<\/Type> { get }<\/Declaration>", + "key.bodylength" : 5, + "key.bodyoffset" : 322, + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A human-readable name for this type.", + "key.doc.column" : 13, + "key.doc.comment" : "A human-readable name for this type.", + "key.doc.declaration" : "static var name: String { get }", + "key.doc.file" : "\/private\/Sources\/Commandant\/ArgumentProtocol.swift", + "key.doc.full_as_xml" : "name<\/Name>s:10Commandant16ArgumentProtocolP4nameSSvpZ<\/USR>static var name: String { get }<\/Declaration>A human-readable name for this type.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 12, + "key.doc.name" : "name", + "key.doc.type" : "Other", + "key.doclength" : 41, + "key.docoffset" : 255, + "key.filepath" : "", + "key.fully_annotated_decl" : "static<\/syntaxtype.keyword> var<\/syntaxtype.keyword> name<\/decl.name>: String<\/ref.struct><\/decl.var.type> { get<\/syntaxtype.keyword> }<\/decl.var.static>", + "key.is_dynamic" : true, + "key.kind" : "source.lang.swift.decl.var.static", + "key.length" : 31, + "key.line" : 12, + "key.modulename" : "Commandant", + "key.name" : "name", + "key.namelength" : 4, + "key.nameoffset" : 308, + "key.offset" : 297, + "key.parsed_declaration" : "static var name: String", + "key.parsed_scope.end" : 12, + "key.parsed_scope.start" : 12, + "key.receivers" : [ + { + "key.usr" : "s:10Commandant16ArgumentProtocolP" + } + ], + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant16ArgumentProtocolP4nameSSvpZ" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "static func from(string: String<\/Type>) -> Self<\/Type>?<\/Declaration>", + "key.column" : 14, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Attempts to parse a value from the given command-line argument.", + "key.doc.column" : 14, + "key.doc.comment" : "Attempts to parse a value from the given command-line argument.", + "key.doc.declaration" : "static func from(string: String) -> Self?", + "key.doc.file" : "\/private\/Sources\/Commandant\/ArgumentProtocol.swift", + "key.doc.full_as_xml" : "from(string:)<\/Name>s:10Commandant16ArgumentProtocolP4from6stringxSgSS_tFZ<\/USR>static func from(string: String) -> Self?<\/Declaration>Attempts to parse a value from the given command-line argument.<\/Para><\/Abstract><\/CommentParts><\/Function>", + "key.doc.line" : 15, + "key.doc.name" : "from(string:)", + "key.doc.type" : "Function", + "key.doclength" : 68, + "key.docoffset" : 331, + "key.filepath" : "", + "key.fully_annotated_decl" : "static<\/syntaxtype.keyword> func<\/syntaxtype.keyword> from<\/decl.name>(string<\/decl.var.parameter.argument_label>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>) -> Self<\/ref.generic_type_param>?<\/decl.function.returntype><\/decl.function.method.static>", + "key.is_dynamic" : true, + "key.kind" : "source.lang.swift.decl.function.method.static", + "key.length" : 41, + "key.line" : 15, + "key.modulename" : "Commandant", + "key.name" : "from(string:)", + "key.namelength" : 20, + "key.nameoffset" : 412, + "key.offset" : 400, + "key.parsed_declaration" : "static func from(string: String) -> Self?", + "key.parsed_scope.end" : 15, + "key.parsed_scope.start" : 15, + "key.receivers" : [ + { + "key.usr" : "s:10Commandant16ArgumentProtocolP" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : " (Self.Type) -> (String) -> Self?", + "key.typeusr" : "$s6stringxSgSS_tcD", + "key.usr" : "s:10Commandant16ArgumentProtocolP4from6stringxSgSS_tFZ" + } + ], + "key.typename" : "ArgumentProtocol.Type", + "key.typeusr" : "$s10Commandant16ArgumentProtocol_pmD", + "key.usr" : "s:10Commandant16ArgumentProtocolP" + }, + { + "key.annotated_decl" : "@frozen struct Int : FixedWidthInteger<\/Type>, SignedInteger<\/Type>, _ExpressibleByBuiltinIntegerLiteral<\/Type><\/Declaration>", + "key.bodylength" : 113, + "key.bodyoffset" : 478, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A signed integer value type.\n\nOn 32-bit platforms, `Int` is the same size as `Int32`, and\non 64-bit platforms, `Int` is the same size as `Int64`.", + "key.doc.declaration" : "@frozen struct Int : FixedWidthInteger, SignedInteger, _ExpressibleByBuiltinIntegerLiteral", + "key.doc.discussion" : [ + { + "Para" : "On 32-bit platforms, `Int` is the same size as `Int32`, and on 64-bit platforms, `Int` is the same size as `Int64`." + } + ], + "key.doc.full_as_xml" : "Int<\/Name>s:Si<\/USR>@frozen struct Int : FixedWidthInteger, SignedInteger, _ExpressibleByBuiltinIntegerLiteral<\/Declaration>A signed integer value type.<\/Para><\/Abstract>On 32-bit platforms, Int<\/codeVoice> is the same size as Int32<\/codeVoice>, and on 64-bit platforms, Int<\/codeVoice> is the same size as Int64<\/codeVoice>.<\/Para><\/Discussion><\/CommentParts><\/Class>", + "key.doc.name" : "Int", + "key.doc.type" : "Class", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 16, + "key.offset" : 460 + } + ], + "key.fully_annotated_decl" : "@frozen<\/syntaxtype.attribute.name><\/syntaxtype.attribute.builtin> struct<\/syntaxtype.keyword> Int<\/decl.name> : FixedWidthInteger<\/ref.protocol>, SignedInteger<\/ref.protocol>, _ExpressibleByBuiltinIntegerLiteral<\/ref.protocol><\/decl.struct>", + "key.groupname" : "Math\/Integers", + "key.inheritedtypes" : [ + { + "key.name" : "ArgumentProtocol" + } + ], + "key.is_system" : true, + "key.kind" : "source.lang.swift.decl.extension", + "key.length" : 147, + "key.modulename" : "Swift", + "key.name" : "Int", + "key.namelength" : 3, + "key.nameoffset" : 455, + "key.offset" : 445, + "key.parsed_declaration" : "extension Int: ArgumentProtocol", + "key.parsed_scope.end" : 24, + "key.parsed_scope.start" : 18, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public static let name: String<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 480 + } + ], + "key.column" : 20, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A human-readable name for this type.", + "key.doc.column" : 13, + "key.doc.declaration" : "static var name: String { get }", + "key.doc.discussion" : [ + { + "Note" : "" + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/ArgumentProtocol.swift", + "key.doc.full_as_xml" : "name<\/Name>s:10Commandant16ArgumentProtocolP4nameSSvpZ<\/USR>static var name: String { get }<\/Declaration>A human-readable name for this type.<\/Para><\/Abstract>This documentation comment was inherited from ArgumentProtocol<\/codeVoice>.<\/Para><\/Note><\/Discussion><\/CommentParts><\/Other>", + "key.doc.line" : 12, + "key.doc.name" : "name", + "key.doc.type" : "Other", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> static<\/syntaxtype.keyword> let<\/syntaxtype.keyword> name<\/decl.name>: String<\/ref.struct><\/decl.var.type><\/decl.var.static>", + "key.kind" : "source.lang.swift.decl.var.static", + "key.length" : 27, + "key.line" : 19, + "key.modulename" : "Commandant", + "key.name" : "name", + "key.namelength" : 4, + "key.nameoffset" : 498, + "key.offset" : 487, + "key.overrides" : [ + { + "key.usr" : "s:10Commandant16ArgumentProtocolP4nameSSvpZ" + } + ], + "key.parsed_declaration" : "public static let name = \"integer\"", + "key.parsed_scope.end" : 19, + "key.parsed_scope.start" : 19, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant16ArgumentProtocolP4nameSSvpZ" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public static func from(string: String<\/Type>) -> Int<\/Type>?<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 517 + } + ], + "key.bodylength" : 23, + "key.bodyoffset" : 566, + "key.column" : 21, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Attempts to parse a value from the given command-line argument.", + "key.doc.column" : 14, + "key.doc.declaration" : "static func from(string: String) -> Self?", + "key.doc.discussion" : [ + { + "Note" : "" + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/ArgumentProtocol.swift", + "key.doc.full_as_xml" : "from(string:)<\/Name>s:10Commandant16ArgumentProtocolP4from6stringxSgSS_tFZ<\/USR>static func from(string: String) -> Self?<\/Declaration>Attempts to parse a value from the given command-line argument.<\/Para><\/Abstract>This documentation comment was inherited from ArgumentProtocol<\/codeVoice>.<\/Para><\/Note><\/Discussion><\/CommentParts><\/Function>", + "key.doc.line" : 15, + "key.doc.name" : "from(string:)", + "key.doc.type" : "Function", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> static<\/syntaxtype.keyword> func<\/syntaxtype.keyword> from<\/decl.name>(string<\/decl.var.parameter.argument_label>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>) -> Int<\/ref.struct>?<\/decl.function.returntype><\/decl.function.method.static>", + "key.kind" : "source.lang.swift.decl.function.method.static", + "key.length" : 66, + "key.line" : 21, + "key.modulename" : "Commandant", + "key.name" : "from(string:)", + "key.namelength" : 20, + "key.nameoffset" : 536, + "key.offset" : 524, + "key.overrides" : [ + { + "key.usr" : "s:10Commandant16ArgumentProtocolP4from6stringxSgSS_tFZ" + } + ], + "key.parsed_declaration" : "public static func from(string: String) -> Int?", + "key.parsed_scope.end" : 23, + "key.parsed_scope.start" : 21, + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : "(Int.Type) -> (String) -> Int?", + "key.typeusr" : "$s6stringSiSgSS_tcD", + "key.usr" : "s:10Commandant16ArgumentProtocolP4from6stringxSgSS_tFZ" + } + ], + "key.typename" : "Int.Type", + "key.typeusr" : "$sSimD", + "key.usr" : "s:Si" + }, + { + "key.annotated_decl" : "@frozen @_eagerMove struct String<\/Declaration>", + "key.bodylength" : 110, + "key.bodyoffset" : 630, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A Unicode string value that is a collection of characters.\n\nA string is a series of characters, such as `\"Swift\"`, that forms a\ncollection. Strings in Swift are Unicode correct and locale insensitive,\nand are designed to be efficient. The `String` type bridges with the\nObjective-C class `NSString` and offers interoperability with C functions\nthat works with strings.\n\nYou can create new strings using string literals or string interpolations.\nA *string literal* is a series of characters enclosed in quotes.\n\n let greeting = \"Welcome!\"\n\n*String interpolations* are string literals that evaluate any included\nexpressions and convert the results to string form. String interpolations\ngive you an easy way to build a string from multiple pieces. Wrap each\nexpression in a string interpolation in parentheses, prefixed by a\nbackslash.\n\n let name = \"Rosa\"\n let personalizedGreeting = \"Welcome, \\(name)!\"\n \/\/ personalizedGreeting == \"Welcome, Rosa!\"\n\n let price = 2\n let number = 3\n let cookiePrice = \"\\(number) cookies: $\\(price * number).\"\n \/\/ cookiePrice == \"3 cookies: $6.\"\n\nCombine strings using the concatenation operator (`+`).\n\n let longerGreeting = greeting + \" We're glad you're here!\"\n \/\/ longerGreeting == \"Welcome! We're glad you're here!\"\n\nMultiline string literals are enclosed in three double quotation marks\n(`\"\"\"`), with each delimiter on its own line. Indentation is stripped from\neach line of a multiline string literal to match the indentation of the\nclosing delimiter.\n\n let banner = \"\"\"\n __,\n ( o \/) _\/_\n `. , , , , \/\/ \/\n (___)(_(_\/_(_ \/\/_ (__\n \/)\n (\/\n \"\"\"\n\nModifying and Comparing Strings\n===============================\n\nStrings always have value semantics. Modifying a copy of a string leaves\nthe original unaffected.\n\n var otherGreeting = greeting\n otherGreeting += \" Have a nice time!\"\n \/\/ otherGreeting == \"Welcome! Have a nice time!\"\n\n print(greeting)\n \/\/ Prints \"Welcome!\"\n\nComparing strings for equality using the equal-to operator (`==`) or a\nrelational operator (like `<` or `>=`) is always performed using Unicode\ncanonical representation. As a result, different representations of a\nstring compare as being equal.\n\n let cafe1 = \"Cafe\\u{301}\"\n let cafe2 = \"Café\"\n print(cafe1 == cafe2)\n \/\/ Prints \"true\"\n\nThe Unicode scalar value `\"\\u{301}\"` modifies the preceding character to\ninclude an accent, so `\"e\\u{301}\"` has the same canonical representation\nas the single Unicode scalar value `\"é\"`.\n\nBasic string operations are not sensitive to locale settings, ensuring that\nstring comparisons and other operations always have a single, stable\nresult, allowing strings to be used as keys in `Dictionary` instances and\nfor other purposes.\n\nAccessing String Elements\n=========================\n\nA string is a collection of *extended grapheme clusters*, which approximate\nhuman-readable characters. Many individual characters, such as \"é\", \"김\",\nand \"🇮🇳\", can be made up of multiple Unicode scalar values. These scalar\nvalues are combined by Unicode's boundary algorithms into extended\ngrapheme clusters, represented by the Swift `Character` type. Each element\nof a string is represented by a `Character` instance.\n\nFor example, to retrieve the first word of a longer string, you can search\nfor a space and then create a substring from a prefix of the string up to\nthat point:\n\n let name = \"Marie Curie\"\n let firstSpace = name.firstIndex(of: \" \") ?? name.endIndex\n let firstName = name[..=`) is always performed using Unicode canonical representation. As a result, different representations of a string compare as being equal." + }, + { + "CodeListing" : "" + }, + { + "Para" : "The Unicode scalar value `\"\\u{301}\"` modifies the preceding character to include an accent, so `\"e\\u{301}\"` has the same canonical representation as the single Unicode scalar value `\"é\"`." + }, + { + "Para" : "Basic string operations are not sensitive to locale settings, ensuring that string comparisons and other operations always have a single, stable result, allowing strings to be used as keys in `Dictionary` instances and for other purposes." + }, + { + "Para" : "A string is a collection of , which approximate human-readable characters. Many individual characters, such as “é”, “김”, and “🇮🇳”, can be made up of multiple Unicode scalar values. These scalar values are combined by Unicode’s boundary algorithms into extended grapheme clusters, represented by the Swift `Character` type. Each element of a string is represented by a `Character` instance." + }, + { + "Para" : "For example, to retrieve the first word of a longer string, you can search for a space and then create a substring from a prefix of the string up to that point:" + }, + { + "CodeListing" : "" + }, + { + "Para" : "The `firstName` constant is an instance of the `Substring` type—a type that represents substrings of a string while sharing the original string’s storage. Substrings present the same interface as strings." + }, + { + "CodeListing" : "" + }, + { + "Para" : "If you need to access the contents of a string as encoded in different Unicode encodings, use one of the string’s `unicodeScalars`, `utf16`, or `utf8` properties. Each property provides access to a view of the string as a series of code units, each encoded in a different Unicode encoding." + }, + { + "Para" : "To demonstrate the different views available for every string, the following examples use this `String` instance:" + }, + { + "CodeListing" : "" + }, + { + "Para" : "The `cafe` string is a collection of the nine characters that are visible when the string is displayed." + }, + { + "CodeListing" : "" + }, + { + "Para" : "A string’s `unicodeScalars` property is a collection of Unicode scalar values, the 21-bit codes that are the basic unit of Unicode. Each scalar value is represented by a `Unicode.Scalar` instance and is equivalent to a UTF-32 code unit." + }, + { + "CodeListing" : "" + }, + { + "Para" : "The `unicodeScalars` view’s elements comprise each Unicode scalar value in the `cafe` string. In particular, because `cafe` was declared using the decomposed form of the `\"é\"` character, `unicodeScalars` contains the scalar values for both the letter `\"e\"` (101) and the accent character `\"´\"` (769)." + }, + { + "Para" : "A string’s `utf16` property is a collection of UTF-16 code units, the 16-bit encoding form of the string’s Unicode scalar values. Each code unit is stored as a `UInt16` instance." + }, + { + "CodeListing" : "" + }, + { + "Para" : "The elements of the `utf16` view are the code units for the string when encoded in UTF-16. These elements match those accessed through indexed `NSString` APIs." + }, + { + "CodeListing" : "" + }, + { + "Para" : "A string’s `utf8` property is a collection of UTF-8 code units, the 8-bit encoding form of the string’s Unicode scalar values. Each code unit is stored as a `UInt8` instance." + }, + { + "CodeListing" : "" + }, + { + "Para" : "The elements of the `utf8` view are the code units for the string when encoded in UTF-8. This representation matches the one used when `String` instances are passed to C APIs." + }, + { + "CodeListing" : "" + }, + { + "Para" : "When you need to know the length of a string, you must first consider what you’ll use the length for. Are you measuring the number of characters that will be displayed on the screen, or are you measuring the amount of storage needed for the string in a particular encoding? A single string can have greatly differing lengths when measured by its different views." + }, + { + "Para" : "For example, an ASCII character like the capital letter is represented by a single element in each of its four views. The Unicode scalar value of is `65`, which is small enough to fit in a single code unit in both UTF-16 and UTF-8." + }, + { + "CodeListing" : "" + }, + { + "Para" : "On the other hand, an emoji flag character is constructed from a pair of Unicode scalar values, like `\"\\u{1F1F5}\"` and `\"\\u{1F1F7}\"`. Each of these scalar values, in turn, is too large to fit into a single UTF-16 or UTF-8 code unit. As a result, each view of the string `\"🇵🇷\"` reports a different length." + }, + { + "CodeListing" : "" + }, + { + "Para" : "To check whether a string is empty, use its `isEmpty` property instead of comparing the length of one of the views to `0`. Unlike with `isEmpty`, calculating a view’s `count` property requires iterating through the elements of the string." + }, + { + "Para" : "To find individual elements of a string, use the appropriate view for your task. For example, to retrieve the first word of a longer string, you can search the string for a space and then create a new string from a prefix of the string up to that point." + }, + { + "CodeListing" : "" + }, + { + "Para" : "Strings and their views share indices, so you can access the UTF-8 view of the `name` string using the same `firstSpace` index." + }, + { + "CodeListing" : "" + }, + { + "Para" : "Note that an index into one view may not have an exact corresponding position in another view. For example, the `flag` string declared above comprises a single character, but is composed of eight code units when encoded as UTF-8. The following code creates constants for the first and second positions in the `flag.utf8` view. Accessing the `utf8` view with these indices yields the first and second code UTF-8 units." + }, + { + "CodeListing" : "" + }, + { + "Para" : "When used to access the elements of the `flag` string itself, however, the `secondCodeUnit` index does not correspond to the position of a specific character. Instead of only accessing the specific UTF-8 code unit, that index is treated as the position of the character at the index’s encoded offset. In the case of `secondCodeUnit`, that character is still the flag itself." + }, + { + "CodeListing" : "" + }, + { + "Para" : "If you need to validate that an index from one string’s view corresponds with an exact position in another view, use the index’s `samePosition(in:)` method or the `init(_:within:)` initializer." + }, + { + "CodeListing" : "" + }, + { + "Para" : "Although strings in Swift have value semantics, strings use a copy-on-write strategy to store their data in a buffer. This buffer can then be shared by different copies of a string. A string’s data is only copied lazily, upon mutation, when more than one string instance is using the same buffer. Therefore, the first in any sequence of mutating operations may cost O() time and space." + }, + { + "Para" : "When a string’s contiguous storage fills up, a new buffer must be allocated and data must be moved to the new storage. String buffers use an exponential growth strategy that makes appending to a string a constant time operation when averaged over many append operations." + }, + { + "Para" : "Any `String` instance can be bridged to `NSString` using the type-cast operator (`as`), and any `String` instance that originates in Objective-C may use an `NSString` instance as its storage. Because any arbitrary subclass of `NSString` can become a `String` instance, there are no guarantees about representation or efficiency when a `String` instance is backed by `NSString` storage. Because `NSString` is immutable, it is just as though the storage was shared by a copy. The first in any sequence of mutating operations causes elements to be copied into unique, contiguous storage which may cost O() time and space, where is the length of the string’s encoded representation (or more, if the underlying `NSString` has unusual performance characteristics)." + }, + { + "Para" : "For more information about the Unicode terms used in this discussion, see the . In particular, this discussion mentions , , and ." + } + ], + "key.doc.full_as_xml" : "String<\/Name>s:SS<\/USR>@frozen struct String<\/Declaration>A Unicode string value that is a collection of characters.<\/Para><\/Abstract>A string is a series of characters, such as "Swift"<\/codeVoice>, that forms a collection. Strings in Swift are Unicode correct and locale insensitive, and are designed to be efficient. The String<\/codeVoice> type bridges with the Objective-C class NSString<\/codeVoice> and offers interoperability with C functions that works with strings.<\/Para>You can create new strings using string literals or string interpolations. A string literal<\/emphasis> is a series of characters enclosed in quotes.<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>String interpolations<\/emphasis> are string literals that evaluate any included expressions and convert the results to string form. String interpolations give you an easy way to build a string from multiple pieces. Wrap each expression in a string interpolation in parentheses, prefixed by a backslash.<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>Combine strings using the concatenation operator (+<\/codeVoice>).<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>Multiline string literals are enclosed in three double quotation marks ("""<\/codeVoice>), with each delimiter on its own line. Indentation is stripped from each line of a multiline string literal to match the indentation of the closing delimiter.<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>]]><\/rawHTML>Modifying and Comparing Strings]]><\/rawHTML>Strings always have value semantics. Modifying a copy of a string leaves the original unaffected.<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>Comparing strings for equality using the equal-to operator (==<\/codeVoice>) or a relational operator (like <<\/codeVoice> or >=<\/codeVoice>) is always performed using Unicode canonical representation. As a result, different representations of a string compare as being equal.<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>The Unicode scalar value "\\u{301}"<\/codeVoice> modifies the preceding character to include an accent, so "e\\u{301}"<\/codeVoice> has the same canonical representation as the single Unicode scalar value "é"<\/codeVoice>.<\/Para>Basic string operations are not sensitive to locale settings, ensuring that string comparisons and other operations always have a single, stable result, allowing strings to be used as keys in Dictionary<\/codeVoice> instances and for other purposes.<\/Para>]]><\/rawHTML>Accessing String Elements]]><\/rawHTML>A string is a collection of extended grapheme clusters<\/emphasis>, which approximate human-readable characters. Many individual characters, such as “é”, “김”, and “🇮🇳”, can be made up of multiple Unicode scalar values. These scalar values are combined by Unicode’s boundary algorithms into extended grapheme clusters, represented by the Swift Character<\/codeVoice> type. Each element of a string is represented by a Character<\/codeVoice> instance.<\/Para>For example, to retrieve the first word of a longer string, you can search for a space and then create a substring from a prefix of the string up to that point:<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>The firstName<\/codeVoice> constant is an instance of the Substring<\/codeVoice> type—a type that represents substrings of a string while sharing the original string’s storage. Substrings present the same interface as strings.<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>]]><\/rawHTML>Accessing a String’s Unicode Representation]]><\/rawHTML>If you need to access the contents of a string as encoded in different Unicode encodings, use one of the string’s unicodeScalars<\/codeVoice>, utf16<\/codeVoice>, or utf8<\/codeVoice> properties. Each property provides access to a view of the string as a series of code units, each encoded in a different Unicode encoding.<\/Para>To demonstrate the different views available for every string, the following examples use this String<\/codeVoice> instance:<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>The cafe<\/codeVoice> string is a collection of the nine characters that are visible when the string is displayed.<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>]]><\/rawHTML>Unicode Scalar View]]><\/rawHTML>A string’s unicodeScalars<\/codeVoice> property is a collection of Unicode scalar values, the 21-bit codes that are the basic unit of Unicode. Each scalar value is represented by a Unicode.Scalar<\/codeVoice> instance and is equivalent to a UTF-32 code unit.<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>The unicodeScalars<\/codeVoice> view’s elements comprise each Unicode scalar value in the cafe<\/codeVoice> string. In particular, because cafe<\/codeVoice> was declared using the decomposed form of the "é"<\/codeVoice> character, unicodeScalars<\/codeVoice> contains the scalar values for both the letter "e"<\/codeVoice> (101) and the accent character "´"<\/codeVoice> (769).<\/Para>]]><\/rawHTML>UTF-16 View]]><\/rawHTML>A string’s utf16<\/codeVoice> property is a collection of UTF-16 code units, the 16-bit encoding form of the string’s Unicode scalar values. Each code unit is stored as a UInt16<\/codeVoice> instance.<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>The elements of the utf16<\/codeVoice> view are the code units for the string when encoded in UTF-16. These elements match those accessed through indexed NSString<\/codeVoice> APIs.<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>]]><\/rawHTML>UTF-8 View]]><\/rawHTML>A string’s utf8<\/codeVoice> property is a collection of UTF-8 code units, the 8-bit encoding form of the string’s Unicode scalar values. Each code unit is stored as a UInt8<\/codeVoice> instance.<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>The elements of the utf8<\/codeVoice> view are the code units for the string when encoded in UTF-8. This representation matches the one used when String<\/codeVoice> instances are passed to C APIs.<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>]]><\/rawHTML>Measuring the Length of a String]]><\/rawHTML>When you need to know the length of a string, you must first consider what you’ll use the length for. Are you measuring the number of characters that will be displayed on the screen, or are you measuring the amount of storage needed for the string in a particular encoding? A single string can have greatly differing lengths when measured by its different views.<\/Para>For example, an ASCII character like the capital letter A<\/emphasis> is represented by a single element in each of its four views. The Unicode scalar value of A<\/emphasis> is 65<\/codeVoice>, which is small enough to fit in a single code unit in both UTF-16 and UTF-8.<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>On the other hand, an emoji flag character is constructed from a pair of Unicode scalar values, like "\\u{1F1F5}"<\/codeVoice> and "\\u{1F1F7}"<\/codeVoice>. Each of these scalar values, in turn, is too large to fit into a single UTF-16 or UTF-8 code unit. As a result, each view of the string "🇵🇷"<\/codeVoice> reports a different length.<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>To check whether a string is empty, use its isEmpty<\/codeVoice> property instead of comparing the length of one of the views to 0<\/codeVoice>. Unlike with isEmpty<\/codeVoice>, calculating a view’s count<\/codeVoice> property requires iterating through the elements of the string.<\/Para>]]><\/rawHTML>Accessing String View Elements]]><\/rawHTML>To find individual elements of a string, use the appropriate view for your task. For example, to retrieve the first word of a longer string, you can search the string for a space and then create a new string from a prefix of the string up to that point.<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>Strings and their views share indices, so you can access the UTF-8 view of the name<\/codeVoice> string using the same firstSpace<\/codeVoice> index.<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>Note that an index into one view may not have an exact corresponding position in another view. For example, the flag<\/codeVoice> string declared above comprises a single character, but is composed of eight code units when encoded as UTF-8. The following code creates constants for the first and second positions in the flag.utf8<\/codeVoice> view. Accessing the utf8<\/codeVoice> view with these indices yields the first and second code UTF-8 units.<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>When used to access the elements of the flag<\/codeVoice> string itself, however, the secondCodeUnit<\/codeVoice> index does not correspond to the position of a specific character. Instead of only accessing the specific UTF-8 code unit, that index is treated as the position of the character at the index’s encoded offset. In the case of secondCodeUnit<\/codeVoice>, that character is still the flag itself.<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>If you need to validate that an index from one string’s view corresponds with an exact position in another view, use the index’s samePosition(in:)<\/codeVoice> method or the init(_:within:)<\/codeVoice> initializer.<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>]]><\/rawHTML>Performance Optimizations]]><\/rawHTML>Although strings in Swift have value semantics, strings use a copy-on-write strategy to store their data in a buffer. This buffer can then be shared by different copies of a string. A string’s data is only copied lazily, upon mutation, when more than one string instance is using the same buffer. Therefore, the first in any sequence of mutating operations may cost O(n<\/emphasis>) time and space.<\/Para>When a string’s contiguous storage fills up, a new buffer must be allocated and data must be moved to the new storage. String buffers use an exponential growth strategy that makes appending to a string a constant time operation when averaged over many append operations.<\/Para>]]><\/rawHTML>Bridging Between String and NSString]]><\/rawHTML>Any String<\/codeVoice> instance can be bridged to NSString<\/codeVoice> using the type-cast operator (as<\/codeVoice>), and any String<\/codeVoice> instance that originates in Objective-C may use an NSString<\/codeVoice> instance as its storage. Because any arbitrary subclass of NSString<\/codeVoice> can become a String<\/codeVoice> instance, there are no guarantees about representation or efficiency when a String<\/codeVoice> instance is backed by NSString<\/codeVoice> storage. Because NSString<\/codeVoice> is immutable, it is just as though the storage was shared by a copy. The first in any sequence of mutating operations causes elements to be copied into unique, contiguous storage which may cost O(n<\/emphasis>) time and space, where n<\/emphasis> is the length of the string’s encoded representation (or more, if the underlying NSString<\/codeVoice> has unusual performance characteristics).<\/Para>For more information about the Unicode terms used in this discussion, see the Unicode.org glossary<\/Link>. In particular, this discussion mentions extended grapheme clusters<\/Link>, Unicode scalar values<\/Link>, and canonical equivalence<\/Link>.<\/Para><\/Discussion><\/CommentParts><\/Class>", + "key.doc.name" : "String", + "key.doc.type" : "Class", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 16, + "key.offset" : 612 + } + ], + "key.fully_annotated_decl" : "@frozen<\/syntaxtype.attribute.name><\/syntaxtype.attribute.builtin> @_eagerMove<\/syntaxtype.attribute.name><\/syntaxtype.attribute.builtin> struct<\/syntaxtype.keyword> String<\/decl.name><\/decl.struct>", + "key.groupname" : "String", + "key.inheritedtypes" : [ + { + "key.name" : "ArgumentProtocol" + } + ], + "key.is_system" : true, + "key.kind" : "source.lang.swift.decl.extension", + "key.length" : 147, + "key.modulename" : "Swift", + "key.name" : "String", + "key.namelength" : 6, + "key.nameoffset" : 604, + "key.offset" : 594, + "key.parsed_declaration" : "extension String: ArgumentProtocol", + "key.parsed_scope.end" : 32, + "key.parsed_scope.start" : 26, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public static let name: String<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 632 + } + ], + "key.column" : 20, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A human-readable name for this type.", + "key.doc.column" : 13, + "key.doc.declaration" : "static var name: String { get }", + "key.doc.discussion" : [ + { + "Note" : "" + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/ArgumentProtocol.swift", + "key.doc.full_as_xml" : "name<\/Name>s:10Commandant16ArgumentProtocolP4nameSSvpZ<\/USR>static var name: String { get }<\/Declaration>A human-readable name for this type.<\/Para><\/Abstract>This documentation comment was inherited from ArgumentProtocol<\/codeVoice>.<\/Para><\/Note><\/Discussion><\/CommentParts><\/Other>", + "key.doc.line" : 12, + "key.doc.name" : "name", + "key.doc.type" : "Other", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> static<\/syntaxtype.keyword> let<\/syntaxtype.keyword> name<\/decl.name>: String<\/ref.struct><\/decl.var.type><\/decl.var.static>", + "key.kind" : "source.lang.swift.decl.var.static", + "key.length" : 26, + "key.line" : 27, + "key.modulename" : "Commandant", + "key.name" : "name", + "key.namelength" : 4, + "key.nameoffset" : 650, + "key.offset" : 639, + "key.overrides" : [ + { + "key.usr" : "s:10Commandant16ArgumentProtocolP4nameSSvpZ" + } + ], + "key.parsed_declaration" : "public static let name = \"string\"", + "key.parsed_scope.end" : 27, + "key.parsed_scope.start" : 27, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant16ArgumentProtocolP4nameSSvpZ" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public static func from(string: String<\/Type>) -> String<\/Type>?<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 668 + } + ], + "key.bodylength" : 18, + "key.bodyoffset" : 720, + "key.column" : 21, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Attempts to parse a value from the given command-line argument.", + "key.doc.column" : 14, + "key.doc.declaration" : "static func from(string: String) -> Self?", + "key.doc.discussion" : [ + { + "Note" : "" + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/ArgumentProtocol.swift", + "key.doc.full_as_xml" : "from(string:)<\/Name>s:10Commandant16ArgumentProtocolP4from6stringxSgSS_tFZ<\/USR>static func from(string: String) -> Self?<\/Declaration>Attempts to parse a value from the given command-line argument.<\/Para><\/Abstract>This documentation comment was inherited from ArgumentProtocol<\/codeVoice>.<\/Para><\/Note><\/Discussion><\/CommentParts><\/Function>", + "key.doc.line" : 15, + "key.doc.name" : "from(string:)", + "key.doc.type" : "Function", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> static<\/syntaxtype.keyword> func<\/syntaxtype.keyword> from<\/decl.name>(string<\/decl.var.parameter.argument_label>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>) -> String<\/ref.struct>?<\/decl.function.returntype><\/decl.function.method.static>", + "key.kind" : "source.lang.swift.decl.function.method.static", + "key.length" : 64, + "key.line" : 29, + "key.modulename" : "Commandant", + "key.name" : "from(string:)", + "key.namelength" : 20, + "key.nameoffset" : 687, + "key.offset" : 675, + "key.overrides" : [ + { + "key.usr" : "s:10Commandant16ArgumentProtocolP4from6stringxSgSS_tFZ" + } + ], + "key.parsed_declaration" : "public static func from(string: String) -> String?", + "key.parsed_scope.end" : 31, + "key.parsed_scope.start" : 29, + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : "(String.Type) -> (String) -> String?", + "key.typeusr" : "$s6stringSSSgSS_tcD", + "key.usr" : "s:10Commandant16ArgumentProtocolP4from6stringxSgSS_tFZ" + } + ], + "key.typename" : "String.Type", + "key.typeusr" : "$sSSmD", + "key.usr" : "s:SS" + }, + { + "key.annotated_decl" : "protocol RawRepresentable<RawValue<\/Type>><\/Declaration>", + "key.bodylength" : 112, + "key.bodyoffset" : 826, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A type that can be converted to and from an associated raw value.\n\nWith a `RawRepresentable` type, you can switch back and forth between a\ncustom type and an associated `RawValue` type without losing the value of\nthe original `RawRepresentable` type. Using the raw value of a conforming\ntype streamlines interoperation with Objective-C and legacy APIs and\nsimplifies conformance to other protocols, such as `Equatable`,\n`Comparable`, and `Hashable`.\n\nThe `RawRepresentable` protocol is seen mainly in two categories of types:\nenumerations with raw value types and option sets.\n\nEnumerations with Raw Values\n============================\n\nFor any enumeration with a string, integer, or floating-point raw type, the\nSwift compiler automatically adds `RawRepresentable` conformance. When\ndefining your own custom enumeration, you give it a raw type by specifying\nthe raw type as the first item in the enumeration's type inheritance list.\nYou can also use literals to specify values for one or more cases.\n\nFor example, the `Counter` enumeration defined here has an `Int` raw value\ntype and gives the first case a raw value of `1`:\n\n enum Counter: Int {\n case one = 1, two, three, four, five\n }\n\nYou can create a `Counter` instance from an integer value between 1 and 5\nby using the `init?(rawValue:)` initializer declared in the\n`RawRepresentable` protocol. This initializer is failable because although\nevery case of the `Counter` type has a corresponding `Int` value, there\nare many `Int` values that *don't* correspond to a case of `Counter`.\n\n for i in 3...6 {\n print(Counter(rawValue: i))\n }\n \/\/ Prints \"Optional(Counter.three)\"\n \/\/ Prints \"Optional(Counter.four)\"\n \/\/ Prints \"Optional(Counter.five)\"\n \/\/ Prints \"nil\"\n\nOption Sets\n===========\n\nOption sets all conform to `RawRepresentable` by inheritance using the\n`OptionSet` protocol. Whether using an option set or creating your own,\nyou use the raw value of an option set instance to store the instance's\nbitfield. The raw value must therefore be of a type that conforms to the\n`FixedWidthInteger` protocol, such as `UInt8` or `Int`. For example, the\n`Direction` type defines an option set for the four directions you can\nmove in a game.\n\n struct Directions: OptionSet {\n let rawValue: UInt8\n\n static let up = Directions(rawValue: 1 << 0)\n static let down = Directions(rawValue: 1 << 1)\n static let left = Directions(rawValue: 1 << 2)\n static let right = Directions(rawValue: 1 << 3)\n }\n\nUnlike enumerations, option sets provide a nonfailable `init(rawValue:)`\ninitializer to convert from a raw value, because option sets don't have an\nenumerated list of all possible cases. Option set values have\na one-to-one correspondence with their associated raw values.\n\nIn the case of the `Directions` option set, an instance can contain zero,\none, or more of the four defined directions. This example declares a\nconstant with three currently allowed moves. The raw value of the\n`allowedMoves` instance is the result of the bitwise OR of its three\nmembers' raw values:\n\n let allowedMoves: Directions = [.up, .down, .left]\n print(allowedMoves.rawValue)\n \/\/ Prints \"7\"\n\nOption sets use bitwise operations on their associated raw values to\nimplement their mathematical set operations. For example, the `contains()`\nmethod on `allowedMoves` performs a bitwise AND operation to check whether\nthe option set contains an element.\n\n print(allowedMoves.contains(.right))\n \/\/ Prints \"false\"\n print(allowedMoves.rawValue & Directions.right.rawValue)\n \/\/ Prints \"0\"", + "key.doc.declaration" : "protocol RawRepresentable", + "key.doc.discussion" : [ + { + "Para" : "With a `RawRepresentable` type, you can switch back and forth between a custom type and an associated `RawValue` type without losing the value of the original `RawRepresentable` type. Using the raw value of a conforming type streamlines interoperation with Objective-C and legacy APIs and simplifies conformance to other protocols, such as `Equatable`, `Comparable`, and `Hashable`." + }, + { + "Para" : "The `RawRepresentable` protocol is seen mainly in two categories of types: enumerations with raw value types and option sets." + }, + { + "Para" : "For any enumeration with a string, integer, or floating-point raw type, the Swift compiler automatically adds `RawRepresentable` conformance. When defining your own custom enumeration, you give it a raw type by specifying the raw type as the first item in the enumeration’s type inheritance list. You can also use literals to specify values for one or more cases." + }, + { + "Para" : "For example, the `Counter` enumeration defined here has an `Int` raw value type and gives the first case a raw value of `1`:" + }, + { + "CodeListing" : "" + }, + { + "Para" : "You can create a `Counter` instance from an integer value between 1 and 5 by using the `init?(rawValue:)` initializer declared in the `RawRepresentable` protocol. This initializer is failable because although every case of the `Counter` type has a corresponding `Int` value, there are many `Int` values that correspond to a case of `Counter`." + }, + { + "CodeListing" : "" + }, + { + "Para" : "Option sets all conform to `RawRepresentable` by inheritance using the `OptionSet` protocol. Whether using an option set or creating your own, you use the raw value of an option set instance to store the instance’s bitfield. The raw value must therefore be of a type that conforms to the `FixedWidthInteger` protocol, such as `UInt8` or `Int`. For example, the `Direction` type defines an option set for the four directions you can move in a game." + }, + { + "CodeListing" : "" + }, + { + "Para" : "Unlike enumerations, option sets provide a nonfailable `init(rawValue:)` initializer to convert from a raw value, because option sets don’t have an enumerated list of all possible cases. Option set values have a one-to-one correspondence with their associated raw values." + }, + { + "Para" : "In the case of the `Directions` option set, an instance can contain zero, one, or more of the four defined directions. This example declares a constant with three currently allowed moves. The raw value of the `allowedMoves` instance is the result of the bitwise OR of its three members’ raw values:" + }, + { + "CodeListing" : "" + }, + { + "Para" : "Option sets use bitwise operations on their associated raw values to implement their mathematical set operations. For example, the `contains()` method on `allowedMoves` performs a bitwise AND operation to check whether the option set contains an element." + }, + { + "CodeListing" : "" + } + ], + "key.doc.full_as_xml" : "RawRepresentable<\/Name>s:SY<\/USR>protocol RawRepresentable<RawValue><\/Declaration>A type that can be converted to and from an associated raw value.<\/Para><\/Abstract>With a RawRepresentable<\/codeVoice> type, you can switch back and forth between a custom type and an associated RawValue<\/codeVoice> type without losing the value of the original RawRepresentable<\/codeVoice> type. Using the raw value of a conforming type streamlines interoperation with Objective-C and legacy APIs and simplifies conformance to other protocols, such as Equatable<\/codeVoice>, Comparable<\/codeVoice>, and Hashable<\/codeVoice>.<\/Para>The RawRepresentable<\/codeVoice> protocol is seen mainly in two categories of types: enumerations with raw value types and option sets.<\/Para>]]><\/rawHTML>Enumerations with Raw Values]]><\/rawHTML>For any enumeration with a string, integer, or floating-point raw type, the Swift compiler automatically adds RawRepresentable<\/codeVoice> conformance. When defining your own custom enumeration, you give it a raw type by specifying the raw type as the first item in the enumeration’s type inheritance list. You can also use literals to specify values for one or more cases.<\/Para>For example, the Counter<\/codeVoice> enumeration defined here has an Int<\/codeVoice> raw value type and gives the first case a raw value of 1<\/codeVoice>:<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>You can create a Counter<\/codeVoice> instance from an integer value between 1 and 5 by using the init?(rawValue:)<\/codeVoice> initializer declared in the RawRepresentable<\/codeVoice> protocol. This initializer is failable because although every case of the Counter<\/codeVoice> type has a corresponding Int<\/codeVoice> value, there are many Int<\/codeVoice> values that don’t<\/emphasis> correspond to a case of Counter<\/codeVoice>.<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>]]><\/rawHTML>Option Sets]]><\/rawHTML>Option sets all conform to RawRepresentable<\/codeVoice> by inheritance using the OptionSet<\/codeVoice> protocol. Whether using an option set or creating your own, you use the raw value of an option set instance to store the instance’s bitfield. The raw value must therefore be of a type that conforms to the FixedWidthInteger<\/codeVoice> protocol, such as UInt8<\/codeVoice> or Int<\/codeVoice>. For example, the Direction<\/codeVoice> type defines an option set for the four directions you can move in a game.<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>Unlike enumerations, option sets provide a nonfailable init(rawValue:)<\/codeVoice> initializer to convert from a raw value, because option sets don’t have an enumerated list of all possible cases. Option set values have a one-to-one correspondence with their associated raw values.<\/Para>In the case of the Directions<\/codeVoice> option set, an instance can contain zero, one, or more of the four defined directions. This example declares a constant with three currently allowed moves. The raw value of the allowedMoves<\/codeVoice> instance is the result of the bitwise OR of its three members’ raw values:<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>Option sets use bitwise operations on their associated raw values to implement their mathematical set operations. For example, the contains()<\/codeVoice> method on allowedMoves<\/codeVoice> performs a bitwise AND operation to check whether the option set contains an element.<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing><\/Discussion><\/CommentParts><\/Class>", + "key.doc.name" : "RawRepresentable", + "key.doc.type" : "Class", + "key.fully_annotated_decl" : "protocol<\/syntaxtype.keyword> RawRepresentable<\/decl.name><RawValue<\/ref.associatedtype><\/decl.generic_type_param>><\/decl.protocol>", + "key.groupname" : "Protocols", + "key.is_system" : true, + "key.kind" : "source.lang.swift.decl.extension", + "key.length" : 196, + "key.modulename" : "Swift", + "key.name" : "RawRepresentable", + "key.namelength" : 16, + "key.nameoffset" : 753, + "key.offset" : 743, + "key.parsed_declaration" : "extension RawRepresentable where RawValue: StringProtocol, Self: ArgumentProtocol", + "key.parsed_scope.end" : 38, + "key.parsed_scope.start" : 34, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public static func from(string: String<\/Type>) -> Self<\/Type>?<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 828 + } + ], + "key.bodylength" : 58, + "key.bodyoffset" : 878, + "key.column" : 21, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> static<\/syntaxtype.keyword> func<\/syntaxtype.keyword> from<\/decl.name>(string<\/decl.var.parameter.argument_label>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>) -> Self<\/ref.generic_type_param>?<\/decl.function.returntype><\/decl.function.method.static>", + "key.is_dynamic" : true, + "key.kind" : "source.lang.swift.decl.function.method.static", + "key.length" : 102, + "key.line" : 35, + "key.modulename" : "Commandant", + "key.name" : "from(string:)", + "key.namelength" : 20, + "key.nameoffset" : 847, + "key.offset" : 835, + "key.parsed_declaration" : "public static func from(string: String) -> Self?", + "key.parsed_scope.end" : 37, + "key.parsed_scope.start" : 35, + "key.receivers" : [ + { + "key.usr" : "s:SY" + } + ], + "key.related_decls" : [ + { + "key.annotated_decl" : "from(string: String) -> Self?<\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : " (Self.Type) -> (String) -> Self?", + "key.typeusr" : "$s6stringxSgSS_tcD", + "key.usr" : "s:SY10CommandantAA16ArgumentProtocolRzSy8RawValueSYRpzrlE4from6stringxSgSS_tFZ" + } + ], + "key.typename" : "RawRepresentable.Type", + "key.typeusr" : "$sSY_pmD", + "key.usr" : "s:SY" + }, + { + "key.annotated_decl" : "protocol RawRepresentable<RawValue<\/Type>><\/Declaration>", + "key.bodylength" : 112, + "key.bodyoffset" : 1027, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A type that can be converted to and from an associated raw value.\n\nWith a `RawRepresentable` type, you can switch back and forth between a\ncustom type and an associated `RawValue` type without losing the value of\nthe original `RawRepresentable` type. Using the raw value of a conforming\ntype streamlines interoperation with Objective-C and legacy APIs and\nsimplifies conformance to other protocols, such as `Equatable`,\n`Comparable`, and `Hashable`.\n\nThe `RawRepresentable` protocol is seen mainly in two categories of types:\nenumerations with raw value types and option sets.\n\nEnumerations with Raw Values\n============================\n\nFor any enumeration with a string, integer, or floating-point raw type, the\nSwift compiler automatically adds `RawRepresentable` conformance. When\ndefining your own custom enumeration, you give it a raw type by specifying\nthe raw type as the first item in the enumeration's type inheritance list.\nYou can also use literals to specify values for one or more cases.\n\nFor example, the `Counter` enumeration defined here has an `Int` raw value\ntype and gives the first case a raw value of `1`:\n\n enum Counter: Int {\n case one = 1, two, three, four, five\n }\n\nYou can create a `Counter` instance from an integer value between 1 and 5\nby using the `init?(rawValue:)` initializer declared in the\n`RawRepresentable` protocol. This initializer is failable because although\nevery case of the `Counter` type has a corresponding `Int` value, there\nare many `Int` values that *don't* correspond to a case of `Counter`.\n\n for i in 3...6 {\n print(Counter(rawValue: i))\n }\n \/\/ Prints \"Optional(Counter.three)\"\n \/\/ Prints \"Optional(Counter.four)\"\n \/\/ Prints \"Optional(Counter.five)\"\n \/\/ Prints \"nil\"\n\nOption Sets\n===========\n\nOption sets all conform to `RawRepresentable` by inheritance using the\n`OptionSet` protocol. Whether using an option set or creating your own,\nyou use the raw value of an option set instance to store the instance's\nbitfield. The raw value must therefore be of a type that conforms to the\n`FixedWidthInteger` protocol, such as `UInt8` or `Int`. For example, the\n`Direction` type defines an option set for the four directions you can\nmove in a game.\n\n struct Directions: OptionSet {\n let rawValue: UInt8\n\n static let up = Directions(rawValue: 1 << 0)\n static let down = Directions(rawValue: 1 << 1)\n static let left = Directions(rawValue: 1 << 2)\n static let right = Directions(rawValue: 1 << 3)\n }\n\nUnlike enumerations, option sets provide a nonfailable `init(rawValue:)`\ninitializer to convert from a raw value, because option sets don't have an\nenumerated list of all possible cases. Option set values have\na one-to-one correspondence with their associated raw values.\n\nIn the case of the `Directions` option set, an instance can contain zero,\none, or more of the four defined directions. This example declares a\nconstant with three currently allowed moves. The raw value of the\n`allowedMoves` instance is the result of the bitwise OR of its three\nmembers' raw values:\n\n let allowedMoves: Directions = [.up, .down, .left]\n print(allowedMoves.rawValue)\n \/\/ Prints \"7\"\n\nOption sets use bitwise operations on their associated raw values to\nimplement their mathematical set operations. For example, the `contains()`\nmethod on `allowedMoves` performs a bitwise AND operation to check whether\nthe option set contains an element.\n\n print(allowedMoves.contains(.right))\n \/\/ Prints \"false\"\n print(allowedMoves.rawValue & Directions.right.rawValue)\n \/\/ Prints \"0\"", + "key.doc.declaration" : "protocol RawRepresentable", + "key.doc.discussion" : [ + { + "Para" : "With a `RawRepresentable` type, you can switch back and forth between a custom type and an associated `RawValue` type without losing the value of the original `RawRepresentable` type. Using the raw value of a conforming type streamlines interoperation with Objective-C and legacy APIs and simplifies conformance to other protocols, such as `Equatable`, `Comparable`, and `Hashable`." + }, + { + "Para" : "The `RawRepresentable` protocol is seen mainly in two categories of types: enumerations with raw value types and option sets." + }, + { + "Para" : "For any enumeration with a string, integer, or floating-point raw type, the Swift compiler automatically adds `RawRepresentable` conformance. When defining your own custom enumeration, you give it a raw type by specifying the raw type as the first item in the enumeration’s type inheritance list. You can also use literals to specify values for one or more cases." + }, + { + "Para" : "For example, the `Counter` enumeration defined here has an `Int` raw value type and gives the first case a raw value of `1`:" + }, + { + "CodeListing" : "" + }, + { + "Para" : "You can create a `Counter` instance from an integer value between 1 and 5 by using the `init?(rawValue:)` initializer declared in the `RawRepresentable` protocol. This initializer is failable because although every case of the `Counter` type has a corresponding `Int` value, there are many `Int` values that correspond to a case of `Counter`." + }, + { + "CodeListing" : "" + }, + { + "Para" : "Option sets all conform to `RawRepresentable` by inheritance using the `OptionSet` protocol. Whether using an option set or creating your own, you use the raw value of an option set instance to store the instance’s bitfield. The raw value must therefore be of a type that conforms to the `FixedWidthInteger` protocol, such as `UInt8` or `Int`. For example, the `Direction` type defines an option set for the four directions you can move in a game." + }, + { + "CodeListing" : "" + }, + { + "Para" : "Unlike enumerations, option sets provide a nonfailable `init(rawValue:)` initializer to convert from a raw value, because option sets don’t have an enumerated list of all possible cases. Option set values have a one-to-one correspondence with their associated raw values." + }, + { + "Para" : "In the case of the `Directions` option set, an instance can contain zero, one, or more of the four defined directions. This example declares a constant with three currently allowed moves. The raw value of the `allowedMoves` instance is the result of the bitwise OR of its three members’ raw values:" + }, + { + "CodeListing" : "" + }, + { + "Para" : "Option sets use bitwise operations on their associated raw values to implement their mathematical set operations. For example, the `contains()` method on `allowedMoves` performs a bitwise AND operation to check whether the option set contains an element." + }, + { + "CodeListing" : "" + } + ], + "key.doc.full_as_xml" : "RawRepresentable<\/Name>s:SY<\/USR>protocol RawRepresentable<RawValue><\/Declaration>A type that can be converted to and from an associated raw value.<\/Para><\/Abstract>With a RawRepresentable<\/codeVoice> type, you can switch back and forth between a custom type and an associated RawValue<\/codeVoice> type without losing the value of the original RawRepresentable<\/codeVoice> type. Using the raw value of a conforming type streamlines interoperation with Objective-C and legacy APIs and simplifies conformance to other protocols, such as Equatable<\/codeVoice>, Comparable<\/codeVoice>, and Hashable<\/codeVoice>.<\/Para>The RawRepresentable<\/codeVoice> protocol is seen mainly in two categories of types: enumerations with raw value types and option sets.<\/Para>]]><\/rawHTML>Enumerations with Raw Values]]><\/rawHTML>For any enumeration with a string, integer, or floating-point raw type, the Swift compiler automatically adds RawRepresentable<\/codeVoice> conformance. When defining your own custom enumeration, you give it a raw type by specifying the raw type as the first item in the enumeration’s type inheritance list. You can also use literals to specify values for one or more cases.<\/Para>For example, the Counter<\/codeVoice> enumeration defined here has an Int<\/codeVoice> raw value type and gives the first case a raw value of 1<\/codeVoice>:<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>You can create a Counter<\/codeVoice> instance from an integer value between 1 and 5 by using the init?(rawValue:)<\/codeVoice> initializer declared in the RawRepresentable<\/codeVoice> protocol. This initializer is failable because although every case of the Counter<\/codeVoice> type has a corresponding Int<\/codeVoice> value, there are many Int<\/codeVoice> values that don’t<\/emphasis> correspond to a case of Counter<\/codeVoice>.<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>]]><\/rawHTML>Option Sets]]><\/rawHTML>Option sets all conform to RawRepresentable<\/codeVoice> by inheritance using the OptionSet<\/codeVoice> protocol. Whether using an option set or creating your own, you use the raw value of an option set instance to store the instance’s bitfield. The raw value must therefore be of a type that conforms to the FixedWidthInteger<\/codeVoice> protocol, such as UInt8<\/codeVoice> or Int<\/codeVoice>. For example, the Direction<\/codeVoice> type defines an option set for the four directions you can move in a game.<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>Unlike enumerations, option sets provide a nonfailable init(rawValue:)<\/codeVoice> initializer to convert from a raw value, because option sets don’t have an enumerated list of all possible cases. Option set values have a one-to-one correspondence with their associated raw values.<\/Para>In the case of the Directions<\/codeVoice> option set, an instance can contain zero, one, or more of the four defined directions. This example declares a constant with three currently allowed moves. The raw value of the allowedMoves<\/codeVoice> instance is the result of the bitwise OR of its three members’ raw values:<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>Option sets use bitwise operations on their associated raw values to implement their mathematical set operations. For example, the contains()<\/codeVoice> method on allowedMoves<\/codeVoice> performs a bitwise AND operation to check whether the option set contains an element.<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing><\/Discussion><\/CommentParts><\/Class>", + "key.doc.name" : "RawRepresentable", + "key.doc.type" : "Class", + "key.fully_annotated_decl" : "protocol<\/syntaxtype.keyword> RawRepresentable<\/decl.name><RawValue<\/ref.associatedtype><\/decl.generic_type_param>><\/decl.protocol>", + "key.groupname" : "Protocols", + "key.is_system" : true, + "key.kind" : "source.lang.swift.decl.extension", + "key.length" : 199, + "key.modulename" : "Swift", + "key.name" : "RawRepresentable", + "key.namelength" : 16, + "key.nameoffset" : 951, + "key.offset" : 941, + "key.parsed_declaration" : "extension RawRepresentable where RawValue: FixedWidthInteger, Self: ArgumentProtocol", + "key.parsed_scope.end" : 44, + "key.parsed_scope.start" : 40, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public static func from(string: String<\/Type>) -> Self<\/Type>?<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 1029 + } + ], + "key.bodylength" : 58, + "key.bodyoffset" : 1079, + "key.column" : 21, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> static<\/syntaxtype.keyword> func<\/syntaxtype.keyword> from<\/decl.name>(string<\/decl.var.parameter.argument_label>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>) -> Self<\/ref.generic_type_param>?<\/decl.function.returntype><\/decl.function.method.static>", + "key.is_dynamic" : true, + "key.kind" : "source.lang.swift.decl.function.method.static", + "key.length" : 102, + "key.line" : 41, + "key.modulename" : "Commandant", + "key.name" : "from(string:)", + "key.namelength" : 20, + "key.nameoffset" : 1048, + "key.offset" : 1036, + "key.parsed_declaration" : "public static func from(string: String) -> Self?", + "key.parsed_scope.end" : 43, + "key.parsed_scope.start" : 41, + "key.receivers" : [ + { + "key.usr" : "s:SY" + } + ], + "key.related_decls" : [ + { + "key.annotated_decl" : "from(string: String) -> Self?<\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : " (Self.Type) -> (String) -> Self?", + "key.typeusr" : "$s6stringxSgSS_tcD", + "key.usr" : "s:SY10CommandantAA16ArgumentProtocolRzs17FixedWidthInteger8RawValueSYRpzrlE4from6stringxSgSS_tFZ" + } + ], + "key.typename" : "RawRepresentable.Type", + "key.typeusr" : "$sSY_pmD", + "key.usr" : "s:SY" + } + ] + } +}, { + "\/Sources\/Commandant\/Command.swift" : { + "key.diagnostic_stage" : "source.diagnostic.stage.swift.parse", + "key.length" : 7522, + "key.offset" : 0, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public protocol CommandProtocol<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 247 + } + ], + "key.bodylength" : 483, + "key.bodyoffset" : 280, + "key.column" : 17, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Represents a subcommand that can be executed with its own set of arguments.", + "key.doc.column" : 17, + "key.doc.comment" : "Represents a subcommand that can be executed with its own set of arguments.", + "key.doc.declaration" : "public protocol CommandProtocol", + "key.doc.file" : "\/private\/Sources\/Commandant\/Command.swift", + "key.doc.full_as_xml" : "CommandProtocol<\/Name>s:10Commandant15CommandProtocolP<\/USR>public protocol CommandProtocol<\/Declaration>Represents a subcommand that can be executed with its own set of arguments.<\/Para><\/Abstract><\/CommentParts><\/Class>", + "key.doc.line" : 12, + "key.doc.name" : "CommandProtocol", + "key.doc.type" : "Class", + "key.doclength" : 80, + "key.docoffset" : 167, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> protocol<\/syntaxtype.keyword> CommandProtocol<\/decl.name><\/decl.protocol>", + "key.kind" : "source.lang.swift.decl.protocol", + "key.length" : 510, + "key.line" : 12, + "key.modulename" : "Commandant", + "key.name" : "CommandProtocol", + "key.namelength" : 15, + "key.nameoffset" : 263, + "key.offset" : 254, + "key.parsed_declaration" : "public protocol CommandProtocol", + "key.parsed_scope.end" : 29, + "key.parsed_scope.start" : 12, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "associatedtype Options : OptionsProtocol<\/Type><\/Declaration>", + "key.column" : 17, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "The command's options type.", + "key.doc.column" : 17, + "key.doc.comment" : "The command's options type.", + "key.doc.declaration" : "associatedtype Options : Commandant.OptionsProtocol", + "key.doc.file" : "\/private\/Sources\/Commandant\/Command.swift", + "key.doc.full_as_xml" : "Options<\/Name>s:10Commandant15CommandProtocolP7OptionsQa<\/USR>associatedtype Options : Commandant.OptionsProtocol<\/Declaration>The command’s options type.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 15, + "key.doc.name" : "Options", + "key.doc.type" : "Other", + "key.doclength" : 32, + "key.docoffset" : 283, + "key.filepath" : "", + "key.fully_annotated_decl" : "associatedtype<\/syntaxtype.keyword> Options<\/decl.name> : OptionsProtocol<\/ref.protocol><\/decl.associatedtype>", + "key.is_dynamic" : true, + "key.kind" : "source.lang.swift.decl.associatedtype", + "key.length" : 39, + "key.line" : 15, + "key.modulename" : "Commandant", + "key.name" : "Options", + "key.namelength" : 7, + "key.nameoffset" : 331, + "key.offset" : 316, + "key.parsed_declaration" : "associatedtype Options: OptionsProtocol", + "key.parsed_scope.end" : 15, + "key.parsed_scope.start" : 15, + "key.receivers" : [ + { + "key.usr" : "s:10Commandant15CommandProtocolP" + } + ], + "key.reusingastcontext" : false, + "key.typename" : "Self.Options.Type", + "key.typeusr" : "$s7OptionsQzmD", + "key.usr" : "s:10Commandant15CommandProtocolP7OptionsQa" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "associatedtype ClientError where Self<\/Type>.ClientError<\/Type> == Self<\/Type>.Options<\/Type>.ClientError<\/Type><\/Declaration>", + "key.column" : 17, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "associatedtype<\/syntaxtype.keyword> ClientError<\/decl.name> where<\/syntaxtype.keyword> Self<\/ref.generic_type_param>.ClientError<\/ref.associatedtype> == Self<\/ref.generic_type_param>.Options<\/ref.associatedtype>.ClientError<\/ref.associatedtype><\/decl.generic_type_requirement><\/decl.associatedtype>", + "key.is_dynamic" : true, + "key.kind" : "source.lang.swift.decl.associatedtype", + "key.length" : 67, + "key.line" : 17, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 373, + "key.offset" : 358, + "key.parsed_declaration" : "associatedtype ClientError where ClientError == Options.ClientError", + "key.parsed_scope.end" : 17, + "key.parsed_scope.start" : 17, + "key.receivers" : [ + { + "key.usr" : "s:10Commandant15CommandProtocolP" + } + ], + "key.reusingastcontext" : false, + "key.typename" : "Self.ClientError.Type", + "key.typeusr" : "$s11ClientErrorQzmD", + "key.usr" : "s:10Commandant15CommandProtocolP11ClientErrorQa" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "var verb: String<\/Type> { get }<\/Declaration>", + "key.bodylength" : 5, + "key.bodyoffset" : 532, + "key.column" : 6, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "The action that users should specify to use this subcommand (e.g.,\n`help`).", + "key.doc.column" : 6, + "key.doc.comment" : "The action that users should specify to use this subcommand (e.g.,\n`help`).", + "key.doc.declaration" : "var verb: String { get }", + "key.doc.file" : "\/private\/Sources\/Commandant\/Command.swift", + "key.doc.full_as_xml" : "verb<\/Name>s:10Commandant15CommandProtocolP4verbSSvp<\/USR>var verb: String { get }<\/Declaration>The action that users should specify to use this subcommand (e.g., help<\/codeVoice>).<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 21, + "key.doc.name" : "verb", + "key.doc.type" : "Other", + "key.doclength" : 85, + "key.docoffset" : 428, + "key.filepath" : "", + "key.fully_annotated_decl" : "var<\/syntaxtype.keyword> verb<\/decl.name>: String<\/ref.struct><\/decl.var.type> { get<\/syntaxtype.keyword> }<\/decl.var.instance>", + "key.is_dynamic" : true, + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 24, + "key.line" : 21, + "key.modulename" : "Commandant", + "key.name" : "verb", + "key.namelength" : 4, + "key.nameoffset" : 518, + "key.offset" : 514, + "key.parsed_declaration" : "var verb: String", + "key.parsed_scope.end" : 21, + "key.parsed_scope.start" : 21, + "key.receivers" : [ + { + "key.usr" : "s:10Commandant15CommandProtocolP" + } + ], + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant15CommandProtocolP4verbSSvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "var function: String<\/Type> { get }<\/Declaration>", + "key.bodylength" : 5, + "key.bodyoffset" : 648, + "key.column" : 6, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A human-readable, high-level description of what this command is used\nfor.", + "key.doc.column" : 6, + "key.doc.comment" : "A human-readable, high-level description of what this command is used\nfor.", + "key.doc.declaration" : "var function: String { get }", + "key.doc.file" : "\/private\/Sources\/Commandant\/Command.swift", + "key.doc.full_as_xml" : "function<\/Name>s:10Commandant15CommandProtocolP8functionSSvp<\/USR>var function: String { get }<\/Declaration>A human-readable, high-level description of what this command is used for.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 25, + "key.doc.name" : "function", + "key.doc.type" : "Other", + "key.doclength" : 84, + "key.docoffset" : 541, + "key.filepath" : "", + "key.fully_annotated_decl" : "var<\/syntaxtype.keyword> function<\/decl.name>: String<\/ref.struct><\/decl.var.type> { get<\/syntaxtype.keyword> }<\/decl.var.instance>", + "key.is_dynamic" : true, + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 28, + "key.line" : 25, + "key.modulename" : "Commandant", + "key.name" : "function", + "key.namelength" : 8, + "key.nameoffset" : 630, + "key.offset" : 626, + "key.parsed_declaration" : "var function: String", + "key.parsed_scope.end" : 25, + "key.parsed_scope.start" : 25, + "key.receivers" : [ + { + "key.usr" : "s:10Commandant15CommandProtocolP" + } + ], + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant15CommandProtocolP8functionSSvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "func run(_ options: Options<\/Type>) -> Result<\/Type><(), ClientError<\/Type>><\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Runs this subcommand with the given options.", + "key.doc.column" : 7, + "key.doc.comment" : "Runs this subcommand with the given options.", + "key.doc.declaration" : "func run(_ options: Options) -> Result<(), ClientError>", + "key.doc.file" : "\/private\/Sources\/Commandant\/Command.swift", + "key.doc.full_as_xml" : "run(_:)<\/Name>s:10Commandant15CommandProtocolP3runys6ResultOyyt11ClientErrorQzG7OptionsQzF<\/USR>func run(_ options: Options) -> Result<(), ClientError><\/Declaration>Runs this subcommand with the given options.<\/Para><\/Abstract><\/CommentParts><\/Function>", + "key.doc.line" : 28, + "key.doc.name" : "run(_:)", + "key.doc.type" : "Function", + "key.doclength" : 49, + "key.docoffset" : 657, + "key.filepath" : "", + "key.fully_annotated_decl" : "func<\/syntaxtype.keyword> run<\/decl.name>(_<\/decl.var.parameter.argument_label> options<\/decl.var.parameter.name>: Options<\/ref.associatedtype><\/decl.var.parameter.type><\/decl.var.parameter>) -> Result<\/ref.enum><()<\/tuple>, ClientError<\/ref.associatedtype>><\/decl.function.returntype><\/decl.function.method.instance>", + "key.is_dynamic" : true, + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 55, + "key.line" : 28, + "key.modulename" : "Commandant", + "key.name" : "run(_:)", + "key.namelength" : 23, + "key.nameoffset" : 712, + "key.offset" : 707, + "key.parsed_declaration" : "func run(_ options: Options) -> Result<(), ClientError>", + "key.parsed_scope.end" : 28, + "key.parsed_scope.start" : 28, + "key.receivers" : [ + { + "key.usr" : "s:10Commandant15CommandProtocolP" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : " (Self) -> (Self.Options) -> Result<(), Self.ClientError>", + "key.typeusr" : "$sys6ResultOyyt11ClientErrorQzG7OptionsQzcD", + "key.usr" : "s:10Commandant15CommandProtocolP3runys6ResultOyyt11ClientErrorQzG7OptionsQzF" + } + ], + "key.typename" : "CommandProtocol.Type", + "key.typeusr" : "$s10Commandant15CommandProtocol_pmD", + "key.usr" : "s:10Commandant15CommandProtocolP" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public struct CommandWrapper<ClientError> where ClientError<\/Type> : Error<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 793 + } + ], + "key.bodylength" : 957, + "key.bodyoffset" : 843, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A type-erased command.", + "key.doc.column" : 15, + "key.doc.comment" : "A type-erased command.", + "key.doc.declaration" : "public struct CommandWrapper where ClientError : Error", + "key.doc.file" : "\/private\/Sources\/Commandant\/Command.swift", + "key.doc.full_as_xml" : "CommandWrapper<\/Name>s:10Commandant14CommandWrapperV<\/USR>public struct CommandWrapper<ClientError> where ClientError : Error<\/Declaration>A type-erased command.<\/Para><\/Abstract><\/CommentParts><\/Class>", + "key.doc.line" : 32, + "key.doc.name" : "CommandWrapper", + "key.doc.type" : "Class", + "key.doclength" : 27, + "key.docoffset" : 766, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> struct<\/syntaxtype.keyword> CommandWrapper<\/decl.name><ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>> where<\/syntaxtype.keyword> ClientError<\/ref.generic_type_param> : Error<\/ref.protocol><\/decl.generic_type_requirement><\/decl.struct>", + "key.kind" : "source.lang.swift.decl.struct", + "key.length" : 1001, + "key.line" : 32, + "key.modulename" : "Commandant", + "key.name" : "CommandWrapper", + "key.namelength" : 14, + "key.nameoffset" : 807, + "key.offset" : 800, + "key.parsed_declaration" : "public struct CommandWrapper", + "key.parsed_scope.end" : 65, + "key.parsed_scope.start" : 32, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "ClientError : Error<\/Type><\/Declaration>", + "key.column" : 30, + "key.decl_lang" : "source.lang.swift", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 5, + "key.offset" : 835 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name> : Error<\/ref.protocol><\/decl.generic_type_param.constraint><\/decl.generic_type_param>", + "key.inheritedtypes" : [ + { + "key.name" : "Error" + } + ], + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 18, + "key.line" : 32, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 822, + "key.offset" : 822, + "key.parsed_declaration" : "public struct CommandWrapperpublic let verb: String<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 845 + } + ], + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> let<\/syntaxtype.keyword> verb<\/decl.name>: String<\/ref.struct><\/decl.var.type><\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 16, + "key.line" : 33, + "key.modulename" : "Commandant", + "key.name" : "verb", + "key.namelength" : 4, + "key.nameoffset" : 856, + "key.offset" : 852, + "key.parsed_declaration" : "public let verb: String", + "key.parsed_scope.end" : 33, + "key.parsed_scope.start" : 33, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant14CommandWrapperV4verbSSvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public let function: String<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 870 + } + ], + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> let<\/syntaxtype.keyword> function<\/decl.name>: String<\/ref.struct><\/decl.var.type><\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 20, + "key.line" : 34, + "key.modulename" : "Commandant", + "key.name" : "function", + "key.namelength" : 8, + "key.nameoffset" : 881, + "key.offset" : 877, + "key.parsed_declaration" : "public let function: String", + "key.parsed_scope.end" : 34, + "key.parsed_scope.start" : 34, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant14CommandWrapperV8functionSSvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public let run: (ArgumentParser<\/Type>) -> Result<\/Type><(), CommandantError<\/Type><ClientError<\/Type>>><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 900 + } + ], + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> let<\/syntaxtype.keyword> run<\/decl.name>: (ArgumentParser<\/ref.class><\/decl.var.parameter.type><\/decl.var.parameter>) -> Result<\/ref.enum><()<\/tuple>, CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>>><\/decl.function.returntype><\/decl.var.type><\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 69, + "key.line" : 36, + "key.modulename" : "Commandant", + "key.name" : "run", + "key.namelength" : 3, + "key.nameoffset" : 911, + "key.offset" : 907, + "key.parsed_declaration" : "public let run: (ArgumentParser) -> Result<(), CommandantError>", + "key.parsed_scope.end" : 36, + "key.parsed_scope.start" : 36, + "key.reusingastcontext" : false, + "key.typename" : "(ArgumentParser) -> Result<(), CommandantError>", + "key.typeusr" : "$sys6ResultOyyt10Commandant0B5ErrorOyxGGAC14ArgumentParserCcD", + "key.usr" : "s:10Commandant14CommandWrapperV3runys6ResultOyytAA0A5ErrorOyxGGAA14ArgumentParserCcvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public let usage: () -> CommandantError<\/Type><ClientError<\/Type>>?<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 979 + } + ], + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> let<\/syntaxtype.keyword> usage<\/decl.name>: () -> CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>>?<\/decl.function.returntype><\/decl.var.type><\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 46, + "key.line" : 38, + "key.modulename" : "Commandant", + "key.name" : "usage", + "key.namelength" : 5, + "key.nameoffset" : 990, + "key.offset" : 986, + "key.parsed_declaration" : "public let usage: () -> CommandantError?", + "key.parsed_scope.end" : 38, + "key.parsed_scope.start" : 38, + "key.reusingastcontext" : false, + "key.typename" : "() -> CommandantError?", + "key.typeusr" : "$s10Commandant0A5ErrorOyxGSgycD", + "key.usr" : "s:10Commandant14CommandWrapperV5usageAA0A5ErrorOyxGSgycvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.fileprivate", + "key.annotated_decl" : "fileprivate init<C>(_ command: C<\/Type>) where ClientError<\/Type> == C<\/Type>.ClientError<\/Type>, C<\/Type> : CommandProtocol<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.fileprivate", + "key.length" : 11, + "key.offset" : 1078 + } + ], + "key.bodylength" : 633, + "key.bodyoffset" : 1165, + "key.column" : 14, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Creates a command that wraps another.", + "key.doc.column" : 14, + "key.doc.comment" : "Creates a command that wraps another.", + "key.doc.declaration" : "fileprivate init(_ command: C) where ClientError == C.ClientError, C : Commandant.CommandProtocol", + "key.doc.file" : "\/private\/Sources\/Commandant\/Command.swift", + "key.doc.full_as_xml" : "init(_:)<\/Name>s:10Commandant14CommandWrapperVyACyxGqd__c11ClientErrorQyd__RszAA0B8ProtocolRd__lu33_1DD6990CD6DFDE28F713A55F8EE2B70ELlfc<\/USR>fileprivate init<C>(_ command: C) where ClientError == C.ClientError, C : Commandant.CommandProtocol<\/Declaration>Creates a command that wraps another.<\/Para><\/Abstract><\/CommentParts><\/Function>", + "key.doc.line" : 41, + "key.doc.name" : "init(_:)", + "key.doc.type" : "Function", + "key.doclength" : 42, + "key.docoffset" : 1035, + "key.filepath" : "", + "key.fully_annotated_decl" : "fileprivate<\/syntaxtype.keyword> init<\/syntaxtype.keyword><C<\/decl.generic_type_param.name><\/decl.generic_type_param>>(_<\/decl.var.parameter.argument_label> command<\/decl.var.parameter.name>: C<\/ref.generic_type_param><\/decl.var.parameter.type><\/decl.var.parameter>) where<\/syntaxtype.keyword> ClientError<\/ref.generic_type_param> == C<\/ref.generic_type_param>.ClientError<\/ref.associatedtype><\/decl.generic_type_requirement>, C<\/ref.generic_type_param> : CommandProtocol<\/ref.protocol><\/decl.generic_type_requirement><\/decl.function.constructor>", + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 709, + "key.line" : 41, + "key.modulename" : "Commandant", + "key.name" : "init(_:)", + "key.namelength" : 38, + "key.nameoffset" : 1090, + "key.offset" : 1090, + "key.parsed_declaration" : "fileprivate init(_ command: C) where C.ClientError == ClientError", + "key.parsed_scope.end" : 64, + "key.parsed_scope.start" : 41, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "C : CommandProtocol<\/Type><\/Declaration>", + "key.column" : 19, + "key.decl_lang" : "source.lang.swift", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 15, + "key.offset" : 1098 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "C<\/decl.generic_type_param.name> : CommandProtocol<\/ref.protocol><\/decl.generic_type_param.constraint><\/decl.generic_type_param>", + "key.inheritedtypes" : [ + { + "key.name" : "CommandProtocol" + } + ], + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 18, + "key.line" : 41, + "key.modulename" : "Commandant", + "key.name" : "C", + "key.namelength" : 1, + "key.nameoffset" : 1095, + "key.offset" : 1095, + "key.parsed_declaration" : "fileprivate init (CommandWrapper.Type) -> (C) -> CommandWrapper", + "key.typeusr" : "$sy10Commandant14CommandWrapperVyxGqd__c11ClientErrorQyd__RszAA0B8ProtocolRd__luD", + "key.usr" : "s:10Commandant14CommandWrapperVyACyxGqd__c11ClientErrorQyd__RszAA0B8ProtocolRd__lu33_1DD6990CD6DFDE28F713A55F8EE2B70ELlfc" + } + ], + "key.typename" : "CommandWrapper.Type", + "key.typeusr" : "$s10Commandant14CommandWrapperVyxGmD", + "key.usr" : "s:10Commandant14CommandWrapperV" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public enum CommandMode<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 1859 + } + ], + "key.bodylength" : 216, + "key.bodyoffset" : 1884, + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Describes the \"mode\" in which a command should run.", + "key.doc.column" : 13, + "key.doc.comment" : "Describes the \"mode\" in which a command should run.", + "key.doc.declaration" : "public enum CommandMode", + "key.doc.file" : "\/private\/Sources\/Commandant\/Command.swift", + "key.doc.full_as_xml" : "CommandMode<\/Name>s:10Commandant11CommandModeO<\/USR>public enum CommandMode<\/Declaration>Describes the “mode” in which a command should run.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 68, + "key.doc.name" : "CommandMode", + "key.doc.type" : "Other", + "key.doclength" : 56, + "key.docoffset" : 1803, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> enum<\/syntaxtype.keyword> CommandMode<\/decl.name><\/decl.enum>", + "key.kind" : "source.lang.swift.decl.enum", + "key.length" : 235, + "key.line" : 68, + "key.modulename" : "Commandant", + "key.name" : "CommandMode", + "key.namelength" : 11, + "key.nameoffset" : 1871, + "key.offset" : 1866, + "key.parsed_declaration" : "public enum CommandMode", + "key.parsed_scope.end" : 75, + "key.parsed_scope.start" : 68, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.kind" : "source.lang.swift.decl.enumcase", + "key.length" : 30, + "key.offset" : 1955, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "case arguments(ArgumentParser<\/Type>)<\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Options should be parsed from the given command-line arguments.", + "key.doc.column" : 7, + "key.doc.comment" : "Options should be parsed from the given command-line arguments.", + "key.doc.declaration" : "", + "key.doc.file" : "\/private\/Sources\/Commandant\/Command.swift", + "key.doc.full_as_xml" : "arguments(_:)<\/Name>s:10Commandant11CommandModeO9argumentsyAcA14ArgumentParserCcACmF<\/USR><\/Declaration>Options should be parsed from the given command-line arguments.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 70, + "key.doc.name" : "arguments(_:)", + "key.doc.type" : "Other", + "key.doclength" : 68, + "key.docoffset" : 1886, + "key.filepath" : "", + "key.fully_annotated_decl" : "case<\/syntaxtype.keyword> arguments<\/decl.name>(ArgumentParser<\/ref.class><\/decl.var.parameter.type><\/decl.var.parameter>)<\/decl.enumelement>", + "key.kind" : "source.lang.swift.decl.enumelement", + "key.length" : 25, + "key.line" : 70, + "key.modulename" : "Commandant", + "key.name" : "arguments(_:)", + "key.namelength" : 25, + "key.nameoffset" : 1960, + "key.offset" : 1960, + "key.parsed_declaration" : "case arguments(ArgumentParser)", + "key.parsed_scope.end" : 70, + "key.parsed_scope.start" : 70, + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : "(CommandMode.Type) -> (ArgumentParser) -> CommandMode", + "key.typeusr" : "$sy10Commandant11CommandModeOAA14ArgumentParserCcACmcD", + "key.usr" : "s:10Commandant11CommandModeO9argumentsyAcA14ArgumentParserCcACmF" + } + ] + }, + { + "key.kind" : "source.lang.swift.decl.enumcase", + "key.length" : 10, + "key.offset" : 2089, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "case usage<\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Each option should record its usage information in an error, for\npresentation to the user.", + "key.doc.column" : 7, + "key.doc.comment" : "Each option should record its usage information in an error, for\npresentation to the user.", + "key.doc.declaration" : "", + "key.doc.file" : "\/private\/Sources\/Commandant\/Command.swift", + "key.doc.full_as_xml" : "usage<\/Name>s:10Commandant11CommandModeO5usageyA2CmF<\/USR><\/Declaration>Each option should record its usage information in an error, for presentation to the user.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 74, + "key.doc.name" : "usage", + "key.doc.type" : "Other", + "key.doclength" : 100, + "key.docoffset" : 1988, + "key.filepath" : "", + "key.fully_annotated_decl" : "case<\/syntaxtype.keyword> usage<\/decl.name><\/decl.enumelement>", + "key.kind" : "source.lang.swift.decl.enumelement", + "key.length" : 5, + "key.line" : 74, + "key.modulename" : "Commandant", + "key.name" : "usage", + "key.namelength" : 5, + "key.nameoffset" : 2094, + "key.offset" : 2094, + "key.parsed_declaration" : "case usage", + "key.parsed_scope.end" : 74, + "key.parsed_scope.start" : 74, + "key.reusingastcontext" : false, + "key.typename" : "(CommandMode.Type) -> CommandMode", + "key.typeusr" : "$sy10Commandant11CommandModeOACmcD", + "key.usr" : "s:10Commandant11CommandModeO5usageyA2CmF" + } + ] + } + ], + "key.typename" : "CommandMode.Type", + "key.typeusr" : "$s10Commandant11CommandModeOmD", + "key.usr" : "s:10Commandant11CommandModeO" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public final class CommandRegistry<ClientError> where ClientError<\/Type> : Error<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.final", + "key.length" : 5, + "key.offset" : 2163 + }, + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 2156 + } + ], + "key.bodylength" : 1204, + "key.bodyoffset" : 2212, + "key.column" : 20, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Maintains the list of commands available to run.", + "key.doc.column" : 20, + "key.doc.comment" : "Maintains the list of commands available to run.", + "key.doc.declaration" : "public final class CommandRegistry where ClientError : Error", + "key.doc.file" : "\/private\/Sources\/Commandant\/Command.swift", + "key.doc.full_as_xml" : "CommandRegistry<\/Name>s:10Commandant15CommandRegistryC<\/USR>public final class CommandRegistry<ClientError> where ClientError : Error<\/Declaration>Maintains the list of commands available to run.<\/Para><\/Abstract><\/CommentParts><\/Class>", + "key.doc.line" : 78, + "key.doc.name" : "CommandRegistry", + "key.doc.type" : "Class", + "key.doclength" : 53, + "key.docoffset" : 2103, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> final<\/syntaxtype.keyword> class<\/syntaxtype.keyword> CommandRegistry<\/decl.name><ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>> where<\/syntaxtype.keyword> ClientError<\/ref.generic_type_param> : Error<\/ref.protocol><\/decl.generic_type_requirement><\/decl.class>", + "key.kind" : "source.lang.swift.decl.class", + "key.length" : 1248, + "key.line" : 78, + "key.modulename" : "Commandant", + "key.name" : "CommandRegistry", + "key.namelength" : 15, + "key.nameoffset" : 2175, + "key.offset" : 2169, + "key.parsed_declaration" : "public final class CommandRegistry", + "key.parsed_scope.end" : 116, + "key.parsed_scope.start" : 78, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "ClientError : Error<\/Type><\/Declaration>", + "key.column" : 36, + "key.decl_lang" : "source.lang.swift", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 5, + "key.offset" : 2204 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name> : Error<\/ref.protocol><\/decl.generic_type_param.constraint><\/decl.generic_type_param>", + "key.inheritedtypes" : [ + { + "key.name" : "Error" + } + ], + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 18, + "key.line" : 78, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 2191, + "key.offset" : 2191, + "key.parsed_declaration" : "public final class CommandRegistryprivate var commandsByVerb: [String<\/Type> : CommandWrapper<\/Type><ClientError<\/Type>>]<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.private", + "key.length" : 7, + "key.offset" : 2214 + } + ], + "key.column" : 14, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "private<\/syntaxtype.keyword> var<\/syntaxtype.keyword> commandsByVerb<\/decl.name>: [String<\/ref.struct> : CommandWrapper<\/ref.struct><ClientError<\/ref.generic_type_param>>]<\/decl.var.type><\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 63, + "key.line" : 79, + "key.modulename" : "Commandant", + "key.name" : "commandsByVerb", + "key.namelength" : 14, + "key.nameoffset" : 2226, + "key.offset" : 2222, + "key.parsed_declaration" : "private var commandsByVerb: [String: CommandWrapper] = [:]", + "key.parsed_scope.end" : 79, + "key.parsed_scope.start" : 79, + "key.reusingastcontext" : false, + "key.setter_accessibility" : "source.lang.swift.accessibility.private", + "key.typename" : "[String : CommandWrapper]", + "key.typeusr" : "$sSDySS10Commandant14CommandWrapperVyxGGD", + "key.usr" : "s:10Commandant15CommandRegistryC14commandsByVerb33_1DD6990CD6DFDE28F713A55F8EE2B70ELLSDySSAA0B7WrapperVyxGGvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public var commands: [CommandWrapper<\/Type><ClientError<\/Type>>] { get }<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 2317 + } + ], + "key.bodylength" : 69, + "key.bodyoffset" : 2369, + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "All available commands.", + "key.doc.column" : 13, + "key.doc.comment" : "All available commands.", + "key.doc.declaration" : "public var commands: [CommandWrapper] { get }", + "key.doc.file" : "\/private\/Sources\/Commandant\/Command.swift", + "key.doc.full_as_xml" : "commands<\/Name>s:10Commandant15CommandRegistryC8commandsSayAA0B7WrapperVyxGGvp<\/USR>public var commands: [CommandWrapper<ClientError>] { get }<\/Declaration>All available commands.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 82, + "key.doc.name" : "commands", + "key.doc.type" : "Other", + "key.doclength" : 28, + "key.docoffset" : 2288, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> var<\/syntaxtype.keyword> commands<\/decl.name>: [CommandWrapper<\/ref.struct><ClientError<\/ref.generic_type_param>>]<\/decl.var.type> { get<\/syntaxtype.keyword> }<\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 115, + "key.line" : 82, + "key.modulename" : "Commandant", + "key.name" : "commands", + "key.namelength" : 8, + "key.nameoffset" : 2328, + "key.offset" : 2324, + "key.parsed_declaration" : "public var commands: [CommandWrapper]", + "key.parsed_scope.end" : 84, + "key.parsed_scope.start" : 82, + "key.reusingastcontext" : false, + "key.typename" : "[CommandWrapper]", + "key.typeusr" : "$sSay10Commandant14CommandWrapperVyxGGD", + "key.usr" : "s:10Commandant15CommandRegistryC8commandsSayAA0B7WrapperVyxGGvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public init()<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 2442 + } + ], + "key.bodylength" : 0, + "key.bodyoffset" : 2457, + "key.column" : 9, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> init<\/syntaxtype.keyword>()<\/decl.function.constructor>", + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 9, + "key.line" : 86, + "key.modulename" : "Commandant", + "key.name" : "init()", + "key.namelength" : 6, + "key.nameoffset" : 2449, + "key.offset" : 2449, + "key.parsed_declaration" : "public init()", + "key.parsed_scope.end" : 86, + "key.parsed_scope.start" : 86, + "key.reusingastcontext" : false, + "key.typename" : " (CommandRegistry.Type) -> () -> CommandRegistry", + "key.typeusr" : "$s10Commandant15CommandRegistryCyxGycD", + "key.usr" : "s:10Commandant15CommandRegistryCACyxGycfc" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "@discardableResult public func register<C>(_ commands: C<\/Type>...) -> CommandRegistry<\/Type> where ClientError<\/Type> == C<\/Type>.ClientError<\/Type>, C<\/Type> : CommandProtocol<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 2656 + }, + { + "key.attribute" : "source.decl.attribute.discardableResult", + "key.length" : 18, + "key.offset" : 2636 + } + ], + "key.bodylength" : 106, + "key.bodyoffset" : 2775, + "key.column" : 14, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Registers the given commands, making those available to run.\n\nIf another commands were already registered with the same `verb`s, those\nwill be overwritten.", + "key.doc.column" : 14, + "key.doc.comment" : "Registers the given commands, making those available to run.\n\nIf another commands were already registered with the same `verb`s, those\nwill be overwritten.", + "key.doc.declaration" : "@discardableResult\npublic func register(_ commands: C...) -> CommandRegistry where ClientError == C.ClientError, C : Commandant.CommandProtocol", + "key.doc.discussion" : [ + { + "Para" : "If another commands were already registered with the same `verb`s, those will be overwritten." + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Command.swift", + "key.doc.full_as_xml" : "register(_:)<\/Name>s:10Commandant15CommandRegistryC8registeryACyxGqd__d_t11ClientErrorQyd__RszAA0B8ProtocolRd__lF<\/USR>@discardableResult\npublic func register<C>(_ commands: C...) -> CommandRegistry where ClientError == C.ClientError, C : Commandant.CommandProtocol<\/Declaration>Registers the given commands, making those available to run.<\/Para><\/Abstract>If another commands were already registered with the same verb<\/codeVoice>s, those will be overwritten.<\/Para><\/Discussion><\/CommentParts><\/Function>", + "key.doc.line" : 93, + "key.doc.name" : "register(_:)", + "key.doc.type" : "Function", + "key.doclength" : 174, + "key.docoffset" : 2461, + "key.filepath" : "", + "key.fully_annotated_decl" : "@discardableResult<\/syntaxtype.attribute.name><\/syntaxtype.attribute.builtin> public<\/syntaxtype.keyword> func<\/syntaxtype.keyword> register<\/decl.name><C<\/decl.generic_type_param.name><\/decl.generic_type_param>>(_<\/decl.var.parameter.argument_label> commands<\/decl.var.parameter.name>: C<\/ref.generic_type_param>...<\/decl.var.parameter.type><\/decl.var.parameter>) -> CommandRegistry<\/ref.class><\/decl.function.returntype> where<\/syntaxtype.keyword> ClientError<\/ref.generic_type_param> == C<\/ref.generic_type_param>.ClientError<\/ref.associatedtype><\/decl.generic_type_requirement>, C<\/ref.generic_type_param> : CommandProtocol<\/ref.protocol><\/decl.generic_type_requirement><\/decl.function.method.instance>", + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 219, + "key.line" : 93, + "key.modulename" : "Commandant", + "key.name" : "register(_:)", + "key.namelength" : 46, + "key.nameoffset" : 2668, + "key.offset" : 2663, + "key.parsed_declaration" : "public func register(_ commands: C...)\n\t-> CommandRegistry\n\twhere C.ClientError == ClientError", + "key.parsed_scope.end" : 101, + "key.parsed_scope.start" : 93, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "C : CommandProtocol<\/Type><\/Declaration>", + "key.column" : 23, + "key.decl_lang" : "source.lang.swift", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 15, + "key.offset" : 2680 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "C<\/decl.generic_type_param.name> : CommandProtocol<\/ref.protocol><\/decl.generic_type_param.constraint><\/decl.generic_type_param>", + "key.inheritedtypes" : [ + { + "key.name" : "CommandProtocol" + } + ], + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 18, + "key.line" : 93, + "key.modulename" : "Commandant", + "key.name" : "C", + "key.namelength" : 1, + "key.nameoffset" : 2677, + "key.offset" : 2677, + "key.parsed_declaration" : "public func register (CommandRegistry) -> (C...) -> CommandRegistry", + "key.typeusr" : "$sy10Commandant15CommandRegistryCyxGqd__d_tc11ClientErrorQyd__RszAA0B8ProtocolRd__luD", + "key.usr" : "s:10Commandant15CommandRegistryC8registeryACyxGqd__d_t11ClientErrorQyd__RszAA0B8ProtocolRd__lF" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public func run(command verb: String<\/Type>, arguments: [String<\/Type>]) -> Result<\/Type><(), CommandantError<\/Type><ClientError<\/Type>>>?<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 3059 + } + ], + "key.bodylength" : 54, + "key.bodyoffset" : 3164, + "key.column" : 14, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Runs the command corresponding to the given verb, passing it the given\narguments.\n\nReturns the results of the execution, or nil if no such command exists.", + "key.doc.column" : 14, + "key.doc.comment" : "Runs the command corresponding to the given verb, passing it the given\narguments.\n\nReturns the results of the execution, or nil if no such command exists.", + "key.doc.declaration" : "public func run(command verb: String, arguments: [String]) -> Result<(), CommandantError>?", + "key.doc.discussion" : [ + { + "Para" : "Returns the results of the execution, or nil if no such command exists." + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Command.swift", + "key.doc.full_as_xml" : "run(command:arguments:)<\/Name>s:10Commandant15CommandRegistryC3run7command9argumentss6ResultOyytAA0A5ErrorOyxGGSgSS_SaySSGtF<\/USR>public func run(command verb: String, arguments: [String]) -> Result<(), CommandantError<ClientError>>?<\/Declaration>Runs the command corresponding to the given verb, passing it the given arguments.<\/Para><\/Abstract>Returns the results of the execution, or nil if no such command exists.<\/Para><\/Discussion><\/CommentParts><\/Function>", + "key.doc.line" : 107, + "key.doc.name" : "run(command:arguments:)", + "key.doc.type" : "Function", + "key.doclength" : 173, + "key.docoffset" : 2885, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> func<\/syntaxtype.keyword> run<\/decl.name>(command<\/decl.var.parameter.argument_label> verb<\/decl.var.parameter.name>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>, arguments<\/decl.var.parameter.argument_label>: [String<\/ref.struct>]<\/decl.var.parameter.type><\/decl.var.parameter>) -> Result<\/ref.enum><()<\/tuple>, CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>>>?<\/decl.function.returntype><\/decl.function.method.instance>", + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 153, + "key.line" : 107, + "key.modulename" : "Commandant", + "key.name" : "run(command:arguments:)", + "key.namelength" : 46, + "key.nameoffset" : 3071, + "key.offset" : 3066, + "key.parsed_declaration" : "public func run(command verb: String, arguments: [String]) -> Result<(), CommandantError>?", + "key.parsed_scope.end" : 109, + "key.parsed_scope.start" : 107, + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : " (CommandRegistry) -> (String, [String]) -> Result<(), CommandantError>?", + "key.typeusr" : "$s7command9argumentss6ResultOyyt10Commandant0D5ErrorOyxGGSgSS_SaySSGtcD", + "key.usr" : "s:10Commandant15CommandRegistryC3run7command9argumentss6ResultOyytAA0A5ErrorOyxGGSgSS_SaySSGtF" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public subscript(verb: String<\/Type>) -> CommandWrapper<\/Type><ClientError<\/Type>>? { get }<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 3318 + } + ], + "key.bodylength" : 32, + "key.bodyoffset" : 3382, + "key.column" : 9, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Returns the command matching the given verb, or nil if no such command\nis registered.", + "key.doc.column" : 9, + "key.doc.comment" : "Returns the command matching the given verb, or nil if no such command\nis registered.", + "key.doc.declaration" : "public subscript(verb: String) -> CommandWrapper? { get }", + "key.doc.file" : "\/private\/Sources\/Commandant\/Command.swift", + "key.doc.full_as_xml" : "subscript(_:)<\/Name>s:10Commandant15CommandRegistryCyAA0B7WrapperVyxGSgSScip<\/USR>public subscript(verb: String) -> CommandWrapper<ClientError>? { get }<\/Declaration>Returns the command matching the given verb, or nil if no such command is registered.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 113, + "key.doc.name" : "subscript(_:)", + "key.doc.type" : "Other", + "key.doclength" : 95, + "key.docoffset" : 3222, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> subscript<\/syntaxtype.keyword>(verb<\/decl.var.parameter.name>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>) -> CommandWrapper<\/ref.struct><ClientError<\/ref.generic_type_param>>?<\/decl.function.returntype> { get<\/syntaxtype.keyword> }<\/decl.function.subscript>", + "key.kind" : "source.lang.swift.decl.function.subscript", + "key.length" : 90, + "key.line" : 113, + "key.modulename" : "Commandant", + "key.name" : "subscript(_:)", + "key.namelength" : 23, + "key.nameoffset" : 3325, + "key.offset" : 3325, + "key.parsed_declaration" : "public subscript(verb: String) -> CommandWrapper?", + "key.parsed_scope.end" : 115, + "key.parsed_scope.start" : 113, + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : " (String) -> CommandWrapper?", + "key.typeusr" : "$sy10Commandant14CommandWrapperVyxGSgSScD", + "key.usr" : "s:10Commandant15CommandRegistryCyAA0B7WrapperVyxGSgSScip" + } + ], + "key.typename" : "CommandRegistry.Type", + "key.typeusr" : "$s10Commandant15CommandRegistryCyxGmD", + "key.usr" : "s:10Commandant15CommandRegistryC" + }, + { + "key.annotated_decl" : "public final class CommandRegistry<ClientError> where ClientError<\/Type> : Error<\/Type><\/Declaration>", + "key.bodylength" : 4074, + "key.bodyoffset" : 3446, + "key.column" : 20, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Maintains the list of commands available to run.", + "key.doc.column" : 20, + "key.doc.declaration" : "public final class CommandRegistry where ClientError : Error", + "key.doc.file" : "\/private\/Sources\/Commandant\/Command.swift", + "key.doc.full_as_xml" : "CommandRegistry<\/Name>s:10Commandant15CommandRegistryC<\/USR>public final class CommandRegistry<ClientError> where ClientError : Error<\/Declaration>Maintains the list of commands available to run.<\/Para><\/Abstract><\/CommentParts><\/Class>", + "key.doc.line" : 78, + "key.doc.name" : "CommandRegistry", + "key.doc.type" : "Class", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> final<\/syntaxtype.keyword> class<\/syntaxtype.keyword> CommandRegistry<\/decl.name><ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>> where<\/syntaxtype.keyword> ClientError<\/ref.generic_type_param> : Error<\/ref.protocol><\/decl.generic_type_requirement><\/decl.class>", + "key.kind" : "source.lang.swift.decl.extension", + "key.length" : 4102, + "key.line" : 78, + "key.modulename" : "Commandant", + "key.name" : "CommandRegistry", + "key.namelength" : 15, + "key.nameoffset" : 3429, + "key.offset" : 3419, + "key.parsed_declaration" : "extension CommandRegistry", + "key.parsed_scope.end" : 241, + "key.parsed_scope.start" : 118, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public func main(defaultVerb: String<\/Type>, errorHandler: (ClientError<\/Type>) -> Void<\/Type>) -> Never<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 4246 + } + ], + "key.bodylength" : 97, + "key.bodyoffset" : 4332, + "key.column" : 14, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Hands off execution to the CommandRegistry, by parsing CommandLine.arguments\nand then running whichever command has been identified in the argument\nlist.\n\nIf the chosen command executes successfully, the process will exit with\na successful exit code.\n\nIf the chosen command fails, the provided error handler will be invoked,\nthen the process will exit with a failure exit code.\n\nIf a matching command could not be found but there is any `executable-verb`\nstyle subcommand executable in the caller's `$PATH`, the subcommand will\nbe executed.\n\nIf a matching command could not be found or a usage error occurred,\na helpful error message will be written to `stderr`, then the process\nwill exit with a failure error code.", + "key.doc.column" : 14, + "key.doc.comment" : "Hands off execution to the CommandRegistry, by parsing CommandLine.arguments\nand then running whichever command has been identified in the argument\nlist.\n\nIf the chosen command executes successfully, the process will exit with\na successful exit code.\n\nIf the chosen command fails, the provided error handler will be invoked,\nthen the process will exit with a failure exit code.\n\nIf a matching command could not be found but there is any `executable-verb`\nstyle subcommand executable in the caller's `$PATH`, the subcommand will\nbe executed.\n\nIf a matching command could not be found or a usage error occurred,\na helpful error message will be written to `stderr`, then the process\nwill exit with a failure error code.", + "key.doc.declaration" : "public func main(defaultVerb: String, errorHandler: (ClientError) -> Void) -> Never", + "key.doc.discussion" : [ + { + "Para" : "If the chosen command executes successfully, the process will exit with a successful exit code." + }, + { + "Para" : "If the chosen command fails, the provided error handler will be invoked, then the process will exit with a failure exit code." + }, + { + "Para" : "If a matching command could not be found but there is any `executable-verb` style subcommand executable in the caller’s `$PATH`, the subcommand will be executed." + }, + { + "Para" : "If a matching command could not be found or a usage error occurred, a helpful error message will be written to `stderr`, then the process will exit with a failure error code." + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Command.swift", + "key.doc.full_as_xml" : "main(defaultVerb:errorHandler:)<\/Name>s:10Commandant15CommandRegistryC4main11defaultVerb12errorHandlers5NeverOSS_yxXEtF<\/USR>public func main(defaultVerb: String, errorHandler: (ClientError) -> Void) -> Never<\/Declaration>Hands off execution to the CommandRegistry, by parsing CommandLine.arguments and then running whichever command has been identified in the argument list.<\/Para><\/Abstract>If the chosen command executes successfully, the process will exit with a successful exit code.<\/Para>If the chosen command fails, the provided error handler will be invoked, then the process will exit with a failure exit code.<\/Para>If a matching command could not be found but there is any executable-verb<\/codeVoice> style subcommand executable in the caller’s $PATH<\/codeVoice>, the subcommand will be executed.<\/Para>If a matching command could not be found or a usage error occurred, a helpful error message will be written to stderr<\/codeVoice>, then the process will exit with a failure error code.<\/Para><\/Discussion><\/CommentParts><\/Function>", + "key.doc.line" : 136, + "key.doc.name" : "main(defaultVerb:errorHandler:)", + "key.doc.type" : "Function", + "key.doclength" : 797, + "key.docoffset" : 3448, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> func<\/syntaxtype.keyword> main<\/decl.name>(defaultVerb<\/decl.var.parameter.argument_label>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>, errorHandler<\/decl.var.parameter.argument_label>: (ClientError<\/ref.generic_type_param><\/decl.var.parameter.type><\/decl.var.parameter>) -> Void<\/ref.typealias><\/decl.function.returntype><\/decl.var.parameter.type><\/decl.var.parameter>) -> Never<\/ref.enum><\/decl.function.returntype><\/decl.function.method.instance>", + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 177, + "key.line" : 136, + "key.modulename" : "Commandant", + "key.name" : "main(defaultVerb:errorHandler:)", + "key.namelength" : 62, + "key.nameoffset" : 4258, + "key.offset" : 4253, + "key.parsed_declaration" : "public func main(defaultVerb: String, errorHandler: (ClientError) -> Void) -> Never", + "key.parsed_scope.end" : 138, + "key.parsed_scope.start" : 136, + "key.related_decls" : [ + { + "key.annotated_decl" : "main(arguments:defaultVerb:errorHandler:)<\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : " (CommandRegistry) -> (String, (ClientError) -> ()) -> Never", + "key.typeusr" : "$s11defaultVerb12errorHandlers5NeverOSS_yxXEtcD", + "key.usr" : "s:10Commandant15CommandRegistryC4main11defaultVerb12errorHandlers5NeverOSS_yxXEtF" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public func main(arguments: [String<\/Type>], defaultVerb: String<\/Type>, errorHandler: (ClientError<\/Type>) -> Void<\/Type>) -> Never<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 5221 + } + ], + "key.bodylength" : 945, + "key.bodyoffset" : 5328, + "key.column" : 14, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Hands off execution to the CommandRegistry, by parsing `arguments`\nand then running whichever command has been identified in the argument\nlist.\n\nIf the chosen command executes successfully, the process will exit with\na successful exit code.\n\nIf the chosen command fails, the provided error handler will be invoked,\nthen the process will exit with a failure exit code.\n\nIf a matching command could not be found but there is any `executable-verb`\nstyle subcommand executable in the caller's `$PATH`, the subcommand will\nbe executed.\n\nIf a matching command could not be found or a usage error occurred,\na helpful error message will be written to `stderr`, then the process\nwill exit with a failure error code.", + "key.doc.column" : 14, + "key.doc.comment" : "Hands off execution to the CommandRegistry, by parsing `arguments`\nand then running whichever command has been identified in the argument\nlist.\n\nIf the chosen command executes successfully, the process will exit with\na successful exit code.\n\nIf the chosen command fails, the provided error handler will be invoked,\nthen the process will exit with a failure exit code.\n\nIf a matching command could not be found but there is any `executable-verb`\nstyle subcommand executable in the caller's `$PATH`, the subcommand will\nbe executed.\n\nIf a matching command could not be found or a usage error occurred,\na helpful error message will be written to `stderr`, then the process\nwill exit with a failure error code.", + "key.doc.declaration" : "public func main(arguments: [String], defaultVerb: String, errorHandler: (ClientError) -> Void) -> Never", + "key.doc.discussion" : [ + { + "Para" : "If the chosen command executes successfully, the process will exit with a successful exit code." + }, + { + "Para" : "If the chosen command fails, the provided error handler will be invoked, then the process will exit with a failure exit code." + }, + { + "Para" : "If a matching command could not be found but there is any `executable-verb` style subcommand executable in the caller’s `$PATH`, the subcommand will be executed." + }, + { + "Para" : "If a matching command could not be found or a usage error occurred, a helpful error message will be written to `stderr`, then the process will exit with a failure error code." + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Command.swift", + "key.doc.full_as_xml" : "main(arguments:defaultVerb:errorHandler:)<\/Name>s:10Commandant15CommandRegistryC4main9arguments11defaultVerb12errorHandlers5NeverOSaySSG_SSyxXEtF<\/USR>public func main(arguments: [String], defaultVerb: String, errorHandler: (ClientError) -> Void) -> Never<\/Declaration>Hands off execution to the CommandRegistry, by parsing arguments<\/codeVoice> and then running whichever command has been identified in the argument list.<\/Para><\/Abstract>If the chosen command executes successfully, the process will exit with a successful exit code.<\/Para>If the chosen command fails, the provided error handler will be invoked, then the process will exit with a failure exit code.<\/Para>If a matching command could not be found but there is any executable-verb<\/codeVoice> style subcommand executable in the caller’s $PATH<\/codeVoice>, the subcommand will be executed.<\/Para>If a matching command could not be found or a usage error occurred, a helpful error message will be written to stderr<\/codeVoice>, then the process will exit with a failure error code.<\/Para><\/Discussion><\/CommentParts><\/Function>", + "key.doc.line" : 157, + "key.doc.name" : "main(arguments:defaultVerb:errorHandler:)", + "key.doc.type" : "Function", + "key.doclength" : 787, + "key.docoffset" : 4433, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> func<\/syntaxtype.keyword> main<\/decl.name>(arguments<\/decl.var.parameter.argument_label>: [String<\/ref.struct>]<\/decl.var.parameter.type><\/decl.var.parameter>, defaultVerb<\/decl.var.parameter.argument_label>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>, errorHandler<\/decl.var.parameter.argument_label>: (ClientError<\/ref.generic_type_param><\/decl.var.parameter.type><\/decl.var.parameter>) -> Void<\/ref.typealias><\/decl.function.returntype><\/decl.var.parameter.type><\/decl.var.parameter>) -> Never<\/ref.enum><\/decl.function.returntype><\/decl.function.method.instance>", + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 1046, + "key.line" : 157, + "key.modulename" : "Commandant", + "key.name" : "main(arguments:defaultVerb:errorHandler:)", + "key.namelength" : 83, + "key.nameoffset" : 5233, + "key.offset" : 5228, + "key.parsed_declaration" : "public func main(arguments: [String], defaultVerb: String, errorHandler: (ClientError) -> Void) -> Never", + "key.parsed_scope.end" : 196, + "key.parsed_scope.start" : 157, + "key.related_decls" : [ + { + "key.annotated_decl" : "main(defaultVerb:errorHandler:)<\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "var arguments: [String<\/Type>]<\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "var<\/syntaxtype.keyword> arguments<\/decl.name>: [String<\/ref.struct>]<\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 25, + "key.line" : 160, + "key.modulename" : "Commandant", + "key.name" : "arguments", + "key.namelength" : 9, + "key.nameoffset" : 5367, + "key.offset" : 5363, + "key.parsed_declaration" : "var arguments = arguments", + "key.parsed_scope.end" : 160, + "key.parsed_scope.start" : 160, + "key.reusingastcontext" : false, + "key.typename" : "[String]", + "key.typeusr" : "$sSaySSGD", + "key.usr" : "s:10Commandant15CommandRegistryC4main9arguments11defaultVerb12errorHandlers5NeverOSaySSG_SSyxXEtFAEL0_AJvp" + }, + { + "key.annotated_decl" : "let executableName: String<\/Type><\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "let<\/syntaxtype.keyword> executableName<\/decl.name>: String<\/ref.struct><\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 44, + "key.line" : 163, + "key.modulename" : "Commandant", + "key.name" : "executableName", + "key.namelength" : 14, + "key.nameoffset" : 5430, + "key.offset" : 5426, + "key.parsed_declaration" : "let executableName = arguments.remove(at: 0)", + "key.parsed_scope.end" : 163, + "key.parsed_scope.start" : 163, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant15CommandRegistryC4main9arguments11defaultVerb12errorHandlers5NeverOSaySSG_SSyxXEtF14executableNameL_SSvp" + }, + { + "key.annotated_decl" : "var verb: String<\/Type><\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "var<\/syntaxtype.keyword> verb<\/decl.name>: String<\/ref.struct><\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 22, + "key.line" : 166, + "key.modulename" : "Commandant", + "key.name" : "verb", + "key.namelength" : 4, + "key.nameoffset" : 5536, + "key.offset" : 5532, + "key.parsed_declaration" : "var verb = defaultVerb", + "key.parsed_scope.end" : 166, + "key.parsed_scope.start" : 166, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant15CommandRegistryC4main9arguments11defaultVerb12errorHandlers5NeverOSaySSG_SSyxXEtF4verbL_SSvp" + } + ], + "key.typename" : " (CommandRegistry) -> ([String], String, (ClientError) -> ()) -> Never", + "key.typeusr" : "$s9arguments11defaultVerb12errorHandlers5NeverOSaySSG_SSyxXEtcD", + "key.usr" : "s:10Commandant15CommandRegistryC4main9arguments11defaultVerb12errorHandlers5NeverOSaySSG_SSyxXEtF" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.private", + "key.annotated_decl" : "private func executeSubcommandIfExists(_ executableName: String<\/Type>, verb: String<\/Type>, arguments: [String<\/Type>]) -> Int32<\/Type>?<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.private", + "key.length" : 7, + "key.offset" : 6474 + } + ], + "key.bodylength" : 933, + "key.bodyoffset" : 6585, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Finds and executes a subcommand which exists in your $PATH. The executable\nname must be in the form of `executable-verb`.\n\n- Returns: The exit status of found subcommand or nil.", + "key.doc.column" : 15, + "key.doc.comment" : "Finds and executes a subcommand which exists in your $PATH. The executable\nname must be in the form of `executable-verb`.\n\n- Returns: The exit status of found subcommand or nil.", + "key.doc.declaration" : "private func executeSubcommandIfExists(_ executableName: String, verb: String, arguments: [String]) -> Int32?", + "key.doc.file" : "\/private\/Sources\/Commandant\/Command.swift", + "key.doc.full_as_xml" : "executeSubcommandIfExists(_:verb:arguments:)<\/Name>s:10Commandant15CommandRegistryC25executeSubcommandIfExists33_1DD6990CD6DFDE28F713A55F8EE2B70ELL_4verb9argumentss5Int32VSgSS_SSSaySSGtF<\/USR>private func executeSubcommandIfExists(_ executableName: String, verb: String, arguments: [String]) -> Int32?<\/Declaration>Finds and executes a subcommand which exists in your $PATH. The executable name must be in the form of executable-verb<\/codeVoice>.<\/Para><\/Abstract>The exit status of found subcommand or nil.<\/Para><\/ResultDiscussion><\/CommentParts><\/Function>", + "key.doc.line" : 202, + "key.doc.name" : "executeSubcommandIfExists(_:verb:arguments:)", + "key.doc.result_discussion" : [ + { + "Para" : "The exit status of found subcommand or nil." + } + ], + "key.doc.type" : "Function", + "key.doclength" : 196, + "key.docoffset" : 6277, + "key.filepath" : "", + "key.fully_annotated_decl" : "private<\/syntaxtype.keyword> func<\/syntaxtype.keyword> executeSubcommandIfExists<\/decl.name>(_<\/decl.var.parameter.argument_label> executableName<\/decl.var.parameter.name>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>, verb<\/decl.var.parameter.argument_label>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>, arguments<\/decl.var.parameter.argument_label>: [String<\/ref.struct>]<\/decl.var.parameter.type><\/decl.var.parameter>) -> Int32<\/ref.struct>?<\/decl.function.returntype><\/decl.function.method.instance>", + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 1037, + "key.line" : 202, + "key.modulename" : "Commandant", + "key.name" : "executeSubcommandIfExists(_:verb:arguments:)", + "key.namelength" : 86, + "key.nameoffset" : 6487, + "key.offset" : 6482, + "key.parsed_declaration" : "private func executeSubcommandIfExists(_ executableName: String, verb: String, arguments: [String]) -> Int32?", + "key.parsed_scope.end" : 240, + "key.parsed_scope.start" : 202, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "let subcommand: String<\/Type><\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "let<\/syntaxtype.keyword> subcommand<\/decl.name>: String<\/ref.struct><\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 80, + "key.line" : 203, + "key.modulename" : "Commandant", + "key.name" : "subcommand", + "key.namelength" : 10, + "key.nameoffset" : 6592, + "key.offset" : 6588, + "key.parsed_declaration" : "let subcommand = \"\\(NSString(string: executableName).lastPathComponent)-\\(verb)\"", + "key.parsed_scope.end" : 203, + "key.parsed_scope.start" : 203, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant15CommandRegistryC25executeSubcommandIfExists33_1DD6990CD6DFDE28F713A55F8EE2B70ELL_4verb9argumentss5Int32VSgSS_SSSaySSGtF10subcommandL_SSvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.private", + "key.annotated_decl" : "func launchTask(_ path: String<\/Type>, arguments: [String<\/Type>]) -> Int32<\/Type><\/Declaration>", + "key.bodylength" : 603, + "key.bodyoffset" : 6735, + "key.column" : 8, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "func<\/syntaxtype.keyword> launchTask<\/decl.name>(_<\/decl.var.parameter.argument_label> path<\/decl.var.parameter.name>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>, arguments<\/decl.var.parameter.argument_label>: [String<\/ref.struct>]<\/decl.var.parameter.type><\/decl.var.parameter>) -> Int32<\/ref.struct><\/decl.function.returntype><\/decl.function.free>", + "key.kind" : "source.lang.swift.decl.function.free", + "key.length" : 667, + "key.line" : 205, + "key.modulename" : "Commandant", + "key.name" : "launchTask(_:arguments:)", + "key.namelength" : 47, + "key.nameoffset" : 6677, + "key.offset" : 6672, + "key.parsed_declaration" : "func launchTask(_ path: String, arguments: [String]) -> Int32", + "key.parsed_scope.end" : 233, + "key.parsed_scope.start" : 205, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "let task: Process<\/Type><\/Declaration>", + "key.column" : 8, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "let<\/syntaxtype.keyword> task<\/decl.name>: Process<\/ref.class><\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 20, + "key.line" : 206, + "key.modulename" : "Commandant", + "key.name" : "task", + "key.namelength" : 4, + "key.nameoffset" : 6743, + "key.offset" : 6739, + "key.parsed_declaration" : "let task = Process()", + "key.parsed_scope.end" : 206, + "key.parsed_scope.start" : 206, + "key.reusingastcontext" : false, + "key.typename" : "Process", + "key.typeusr" : "$sSo6NSTaskCD", + "key.usr" : "s:10Commandant15CommandRegistryC25executeSubcommandIfExists33_1DD6990CD6DFDE28F713A55F8EE2B70ELL_4verb9argumentss5Int32VSgSS_SSSaySSGtF10launchTaskL__AgISS_AKts5ErrorRzlF4taskL_So6NSTaskCvp" + } + ], + "key.typename" : " (String, arguments: [String]) -> Int32", + "key.typeusr" : "$s_9argumentss5Int32VSS_SaySSGtcs5ErrorRzluD", + "key.usr" : "s:10Commandant15CommandRegistryC25executeSubcommandIfExists33_1DD6990CD6DFDE28F713A55F8EE2B70ELL_4verb9argumentss5Int32VSgSS_SSSaySSGtF10launchTaskL__AgISS_AKts5ErrorRzlF" + } + ], + "key.typename" : " (CommandRegistry) -> (String, String, [String]) -> Int32?", + "key.typeusr" : "$s_4verb9argumentss5Int32VSgSS_SSSaySSGtcD", + "key.usr" : "s:10Commandant15CommandRegistryC25executeSubcommandIfExists33_1DD6990CD6DFDE28F713A55F8EE2B70ELL_4verb9argumentss5Int32VSgSS_SSSaySSGtF" + } + ], + "key.typename" : "CommandRegistry.Type", + "key.typeusr" : "$s10Commandant15CommandRegistryCyxGmD", + "key.usr" : "s:10Commandant15CommandRegistryC" + } + ] + } +}, { + "\/Sources\/Commandant\/Errors.swift" : { + "key.diagnostic_stage" : "source.diagnostic.stage.swift.parse", + "key.length" : 5739, + "key.offset" : 0, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public enum CommandantError<ClientError> : Error<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 323 + } + ], + "key.bodylength" : 157, + "key.bodyoffset" : 372, + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Possible errors that can originate from Commandant.\n\n`ClientError` should be the type of error (if any) that can occur when\nrunning commands.", + "key.doc.column" : 13, + "key.doc.comment" : "Possible errors that can originate from Commandant.\n\n`ClientError` should be the type of error (if any) that can occur when\nrunning commands.", + "key.doc.declaration" : "public enum CommandantError : Error", + "key.doc.discussion" : [ + { + "Para" : "`ClientError` should be the type of error (if any) that can occur when running commands." + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Errors.swift", + "key.doc.full_as_xml" : "CommandantError<\/Name>s:10Commandant0A5ErrorO<\/USR>public enum CommandantError<ClientError> : Error<\/Declaration>Possible errors that can originate from Commandant.<\/Para><\/Abstract>ClientError<\/codeVoice> should be the type of error (if any) that can occur when running commands.<\/Para><\/Discussion><\/CommentParts><\/Other>", + "key.doc.line" : 15, + "key.doc.name" : "CommandantError", + "key.doc.type" : "Other", + "key.doclength" : 157, + "key.docoffset" : 166, + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 5, + "key.offset" : 365 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> enum<\/syntaxtype.keyword> CommandantError<\/decl.name><ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>> : Error<\/ref.protocol><\/decl.enum>", + "key.inheritedtypes" : [ + { + "key.name" : "Error" + } + ], + "key.kind" : "source.lang.swift.decl.enum", + "key.length" : 200, + "key.line" : 15, + "key.modulename" : "Commandant", + "key.name" : "CommandantError", + "key.namelength" : 15, + "key.nameoffset" : 335, + "key.offset" : 330, + "key.parsed_declaration" : "public enum CommandantError: Error", + "key.parsed_scope.end" : 21, + "key.parsed_scope.start" : 15, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "ClientError<\/Declaration>", + "key.column" : 29, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 15, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 351, + "key.offset" : 351, + "key.parsed_declaration" : "public enum CommandantErrorcase usageError(description: String<\/Type>)<\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "An option was used incorrectly.", + "key.doc.column" : 7, + "key.doc.comment" : "An option was used incorrectly.", + "key.doc.declaration" : "", + "key.doc.file" : "\/private\/Sources\/Commandant\/Errors.swift", + "key.doc.full_as_xml" : "usageError(description:)<\/Name>s:10Commandant0A5ErrorO05usageB0yACyxGSS_tcAEmlF<\/USR><\/Declaration>An option was used incorrectly.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 17, + "key.doc.name" : "usageError(description:)", + "key.doc.type" : "Other", + "key.doclength" : 36, + "key.docoffset" : 374, + "key.filepath" : "", + "key.fully_annotated_decl" : "case<\/syntaxtype.keyword> usageError<\/decl.name>(description<\/decl.var.parameter.argument_label>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>)<\/decl.enumelement>", + "key.kind" : "source.lang.swift.decl.enumelement", + "key.length" : 31, + "key.line" : 17, + "key.modulename" : "Commandant", + "key.name" : "usageError(description:)", + "key.namelength" : 31, + "key.nameoffset" : 416, + "key.offset" : 416, + "key.parsed_declaration" : "case usageError(description: String)", + "key.parsed_scope.end" : 17, + "key.parsed_scope.start" : 17, + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : " (CommandantError.Type) -> (String) -> CommandantError", + "key.typeusr" : "$sy10Commandant0A5ErrorOyxGSS_tcADmcluD", + "key.usr" : "s:10Commandant0A5ErrorO05usageB0yACyxGSS_tcAEmlF" + } + ] + }, + { + "key.kind" : "source.lang.swift.decl.enumcase", + "key.length" : 30, + "key.offset" : 498, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "case commandError(ClientError<\/Type>)<\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "An error occurred while running a command.", + "key.doc.column" : 7, + "key.doc.comment" : "An error occurred while running a command.", + "key.doc.declaration" : "", + "key.doc.file" : "\/private\/Sources\/Commandant\/Errors.swift", + "key.doc.full_as_xml" : "commandError(_:)<\/Name>s:10Commandant0A5ErrorO07commandB0yACyxGxcAEmlF<\/USR><\/Declaration>An error occurred while running a command.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 20, + "key.doc.name" : "commandError(_:)", + "key.doc.type" : "Other", + "key.doclength" : 47, + "key.docoffset" : 450, + "key.filepath" : "", + "key.fully_annotated_decl" : "case<\/syntaxtype.keyword> commandError<\/decl.name>(ClientError<\/ref.generic_type_param><\/decl.var.parameter.type><\/decl.var.parameter>)<\/decl.enumelement>", + "key.kind" : "source.lang.swift.decl.enumelement", + "key.length" : 25, + "key.line" : 20, + "key.modulename" : "Commandant", + "key.name" : "commandError(_:)", + "key.namelength" : 25, + "key.nameoffset" : 503, + "key.offset" : 503, + "key.parsed_declaration" : "case commandError(ClientError)", + "key.parsed_scope.end" : 20, + "key.parsed_scope.start" : 20, + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : " (CommandantError.Type) -> (ClientError) -> CommandantError", + "key.typeusr" : "$sy10Commandant0A5ErrorOyxGxcADmcluD", + "key.usr" : "s:10Commandant0A5ErrorO07commandB0yACyxGxcAEmlF" + } + ] + } + ], + "key.typename" : "CommandantError.Type", + "key.typeusr" : "$s10Commandant0A5ErrorOyxGmD", + "key.usr" : "s:10Commandant0A5ErrorO" + }, + { + "key.annotated_decl" : "public enum CommandantError<ClientError> : Error<\/Type><\/Declaration>", + "key.bodylength" : 187, + "key.bodyoffset" : 584, + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Possible errors that can originate from Commandant.\n\n`ClientError` should be the type of error (if any) that can occur when\nrunning commands.", + "key.doc.column" : 13, + "key.doc.declaration" : "public enum CommandantError : Error", + "key.doc.discussion" : [ + { + "Para" : "`ClientError` should be the type of error (if any) that can occur when running commands." + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Errors.swift", + "key.doc.full_as_xml" : "CommandantError<\/Name>s:10Commandant0A5ErrorO<\/USR>public enum CommandantError<ClientError> : Error<\/Declaration>Possible errors that can originate from Commandant.<\/Para><\/Abstract>ClientError<\/codeVoice> should be the type of error (if any) that can occur when running commands.<\/Para><\/Discussion><\/CommentParts><\/Other>", + "key.doc.line" : 15, + "key.doc.name" : "CommandantError", + "key.doc.type" : "Other", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 23, + "key.offset" : 559 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> enum<\/syntaxtype.keyword> CommandantError<\/decl.name><ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>> : Error<\/ref.protocol><\/decl.enum>", + "key.inheritedtypes" : [ + { + "key.name" : "CustomStringConvertible" + } + ], + "key.kind" : "source.lang.swift.decl.extension", + "key.length" : 240, + "key.line" : 15, + "key.modulename" : "Commandant", + "key.name" : "CommandantError", + "key.namelength" : 15, + "key.nameoffset" : 542, + "key.offset" : 532, + "key.parsed_declaration" : "extension CommandantError: CustomStringConvertible", + "key.parsed_scope.end" : 33, + "key.parsed_scope.start" : 23, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public var description: String<\/Type> { get }<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 586 + } + ], + "key.bodylength" : 151, + "key.bodyoffset" : 618, + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A textual representation of this instance.\n\nCalling this property directly is discouraged. Instead, convert an\ninstance of any type to a string by using the `String(describing:)`\ninitializer. This initializer works with any type, and uses the custom\n`description` property for types that conform to\n`CustomStringConvertible`:\n\n struct Point: CustomStringConvertible {\n let x: Int, y: Int\n\n var description: String {\n return \"(\\(x), \\(y))\"\n }\n }\n\n let p = Point(x: 21, y: 30)\n let s = String(describing: p)\n print(s)\n \/\/ Prints \"(21, 30)\"\n\nThe conversion of `p` to a string in the assignment to `s` uses the\n`Point` type's `description` property.", + "key.doc.declaration" : "var description: String { get }", + "key.doc.discussion" : [ + { + "Para" : "Calling this property directly is discouraged. Instead, convert an instance of any type to a string by using the `String(describing:)` initializer. This initializer works with any type, and uses the custom `description` property for types that conform to `CustomStringConvertible`:" + }, + { + "CodeListing" : "" + }, + { + "Para" : "The conversion of `p` to a string in the assignment to `s` uses the `Point` type’s `description` property." + }, + { + "Note" : "" + } + ], + "key.doc.full_as_xml" : "description<\/Name>s:s23CustomStringConvertibleP11descriptionSSvp<\/USR>var description: String { get }<\/Declaration>A textual representation of this instance.<\/Para><\/Abstract>Calling this property directly is discouraged. Instead, convert an instance of any type to a string by using the String(describing:)<\/codeVoice> initializer. This initializer works with any type, and uses the custom description<\/codeVoice> property for types that conform to CustomStringConvertible<\/codeVoice>:<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>The conversion of p<\/codeVoice> to a string in the assignment to s<\/codeVoice> uses the Point<\/codeVoice> type’s description<\/codeVoice> property.<\/Para>This documentation comment was inherited from CustomStringConvertible<\/codeVoice>.<\/Para><\/Note><\/Discussion><\/CommentParts><\/Other>", + "key.doc.name" : "description", + "key.doc.type" : "Other", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> var<\/syntaxtype.keyword> description<\/decl.name>: String<\/ref.struct><\/decl.var.type> { get<\/syntaxtype.keyword> }<\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 177, + "key.line" : 24, + "key.modulename" : "Commandant", + "key.name" : "description", + "key.namelength" : 11, + "key.nameoffset" : 597, + "key.offset" : 593, + "key.overrides" : [ + { + "key.usr" : "s:s23CustomStringConvertibleP11descriptionSSvp" + } + ], + "key.parsed_declaration" : "public var description: String", + "key.parsed_scope.end" : 32, + "key.parsed_scope.start" : 24, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:s23CustomStringConvertibleP11descriptionSSvp" + } + ], + "key.typename" : "CommandantError.Type", + "key.typeusr" : "$s10Commandant0A5ErrorOyxGmD", + "key.usr" : "s:10Commandant0A5ErrorO" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "internal func missingArgumentError<ClientError>(_ argumentName: String<\/Type>) -> CommandantError<\/Type><ClientError<\/Type>><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.internal", + "key.length" : 8, + "key.offset" : 887 + } + ], + "key.bodylength" : 105, + "key.bodyoffset" : 992, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Constructs an `InvalidArgument` error that indicates a missing value for\nthe argument by the given name.", + "key.doc.column" : 15, + "key.doc.comment" : "Constructs an `InvalidArgument` error that indicates a missing value for\nthe argument by the given name.", + "key.doc.declaration" : "internal func missingArgumentError(_ argumentName: String) -> CommandantError", + "key.doc.file" : "\/private\/Sources\/Commandant\/Errors.swift", + "key.doc.full_as_xml" : "missingArgumentError(_:)<\/Name>s:10Commandant20missingArgumentErroryAA0aD0OyxGSSlF<\/USR>internal func missingArgumentError<ClientError>(_ argumentName: String) -> CommandantError<ClientError><\/Declaration>Constructs an InvalidArgument<\/codeVoice> error that indicates a missing value for the argument by the given name.<\/Para><\/Abstract><\/CommentParts><\/Function>", + "key.doc.line" : 37, + "key.doc.name" : "missingArgumentError(_:)", + "key.doc.type" : "Function", + "key.doclength" : 113, + "key.docoffset" : 774, + "key.filepath" : "", + "key.fully_annotated_decl" : "internal<\/syntaxtype.keyword> func<\/syntaxtype.keyword> missingArgumentError<\/decl.name><ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>>(_<\/decl.var.parameter.argument_label> argumentName<\/decl.var.parameter.name>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>) -> CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>><\/decl.function.returntype><\/decl.function.free>", + "key.kind" : "source.lang.swift.decl.function.free", + "key.length" : 202, + "key.line" : 37, + "key.modulename" : "Commandant", + "key.name" : "missingArgumentError(_:)", + "key.namelength" : 57, + "key.nameoffset" : 901, + "key.offset" : 896, + "key.parsed_declaration" : "internal func missingArgumentError(_ argumentName: String) -> CommandantError", + "key.parsed_scope.end" : 40, + "key.parsed_scope.start" : 37, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "ClientError<\/Declaration>", + "key.column" : 36, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 37, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 922, + "key.offset" : 922, + "key.parsed_declaration" : "internal func missingArgumentErrorlet description: String<\/Type><\/Declaration>", + "key.column" : 6, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "let<\/syntaxtype.keyword> description<\/decl.name>: String<\/ref.struct><\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 56, + "key.line" : 38, + "key.modulename" : "Commandant", + "key.name" : "description", + "key.namelength" : 11, + "key.nameoffset" : 998, + "key.offset" : 994, + "key.parsed_declaration" : "let description = \"Missing argument for \\(argumentName)\"", + "key.parsed_scope.end" : 38, + "key.parsed_scope.start" : 38, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant20missingArgumentErroryAA0aD0OyxGSSlF11descriptionL_SSvp" + } + ], + "key.typename" : " (String) -> CommandantError", + "key.typeusr" : "$sy10Commandant0A5ErrorOyxGSScluD", + "key.usr" : "s:10Commandant20missingArgumentErroryAA0aD0OyxGSSlF" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "internal func informativeUsageError<ClientError>(_ keyValueExample: String<\/Type>, usage: String<\/Type>) -> CommandantError<\/Type><ClientError<\/Type>><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.internal", + "key.length" : 8, + "key.offset" : 1215 + } + ], + "key.bodylength" : 179, + "key.bodyoffset" : 1339, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Constructs an error by combining the example of key (and value, if applicable)\nwith the usage description.", + "key.doc.column" : 15, + "key.doc.comment" : "Constructs an error by combining the example of key (and value, if applicable)\nwith the usage description.", + "key.doc.declaration" : "internal func informativeUsageError(_ keyValueExample: String, usage: String) -> CommandantError", + "key.doc.file" : "\/private\/Sources\/Commandant\/Errors.swift", + "key.doc.full_as_xml" : "informativeUsageError(_:usage:)<\/Name>s:10Commandant21informativeUsageError_5usageAA0aD0OyxGSS_SStlF<\/USR>internal func informativeUsageError<ClientError>(_ keyValueExample: String, usage: String) -> CommandantError<ClientError><\/Declaration>Constructs an error by combining the example of key (and value, if applicable) with the usage description.<\/Para><\/Abstract><\/CommentParts><\/Function>", + "key.doc.line" : 44, + "key.doc.name" : "informativeUsageError(_:usage:)", + "key.doc.type" : "Function", + "key.doclength" : 115, + "key.docoffset" : 1100, + "key.filepath" : "", + "key.fully_annotated_decl" : "internal<\/syntaxtype.keyword> func<\/syntaxtype.keyword> informativeUsageError<\/decl.name><ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>>(_<\/decl.var.parameter.argument_label> keyValueExample<\/decl.var.parameter.name>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>, usage<\/decl.var.parameter.argument_label>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>) -> CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>><\/decl.function.returntype><\/decl.function.free>", + "key.kind" : "source.lang.swift.decl.function.free", + "key.length" : 295, + "key.line" : 44, + "key.modulename" : "Commandant", + "key.name" : "informativeUsageError(_:usage:)", + "key.namelength" : 76, + "key.nameoffset" : 1229, + "key.offset" : 1224, + "key.parsed_declaration" : "internal func informativeUsageError(_ keyValueExample: String, usage: String) -> CommandantError", + "key.parsed_scope.end" : 50, + "key.parsed_scope.start" : 44, + "key.related_decls" : [ + { + "key.annotated_decl" : "informativeUsageError(_:argument:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Argument<T>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Argument<[T]>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError(_:option:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<T>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<T?>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<[T]>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<[T]?>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<ClientError>(_: Option<Bool>) -> CommandantError<ClientError><\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "ClientError<\/Declaration>", + "key.column" : 37, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 44, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 1251, + "key.offset" : 1251, + "key.parsed_declaration" : "internal func informativeUsageErrorlet lines: [String<\/Type>]<\/Declaration>", + "key.column" : 6, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "let<\/syntaxtype.keyword> lines<\/decl.name>: [String<\/ref.struct>]<\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 52, + "key.line" : 45, + "key.modulename" : "Commandant", + "key.name" : "lines", + "key.namelength" : 5, + "key.nameoffset" : 1345, + "key.offset" : 1341, + "key.parsed_declaration" : "let lines = usage.components(separatedBy: .newlines)", + "key.parsed_scope.end" : 45, + "key.parsed_scope.start" : 45, + "key.reusingastcontext" : false, + "key.typename" : "[String]", + "key.typeusr" : "$sSaySSGD", + "key.usr" : "s:10Commandant21informativeUsageError_5usageAA0aD0OyxGSS_SStlF5linesL_SaySSGvp" + } + ], + "key.typename" : " (String, usage: String) -> CommandantError", + "key.typeusr" : "$s_5usage10Commandant0B5ErrorOyxGSS_SStcluD", + "key.usr" : "s:10Commandant21informativeUsageError_5usageAA0aD0OyxGSS_SStlF" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "internal func combineUsageErrors<ClientError>(_ lhs: CommandantError<\/Type><ClientError<\/Type>>, _ rhs: CommandantError<\/Type><ClientError<\/Type>>) -> CommandantError<\/Type><ClientError<\/Type>><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.internal", + "key.length" : 8, + "key.offset" : 1660 + } + ], + "key.bodylength" : 265, + "key.bodyoffset" : 1813, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Combines the text of the two errors, if they're both `UsageError`s.\nOtherwise, uses whichever one is not (biased toward the left).", + "key.doc.column" : 15, + "key.doc.comment" : "Combines the text of the two errors, if they're both `UsageError`s.\nOtherwise, uses whichever one is not (biased toward the left).", + "key.doc.declaration" : "internal func combineUsageErrors(_ lhs: CommandantError, _ rhs: CommandantError) -> CommandantError", + "key.doc.file" : "\/private\/Sources\/Commandant\/Errors.swift", + "key.doc.full_as_xml" : "combineUsageErrors(_:_:)<\/Name>s:10Commandant18combineUsageErrorsyAA0A5ErrorOyxGAE_AEtlF<\/USR>internal func combineUsageErrors<ClientError>(_ lhs: CommandantError<ClientError>, _ rhs: CommandantError<ClientError>) -> CommandantError<ClientError><\/Declaration>Combines the text of the two errors, if they’re both UsageError<\/codeVoice>s. Otherwise, uses whichever one is not (biased toward the left).<\/Para><\/Abstract><\/CommentParts><\/Function>", + "key.doc.line" : 54, + "key.doc.name" : "combineUsageErrors(_:_:)", + "key.doc.type" : "Function", + "key.doclength" : 139, + "key.docoffset" : 1521, + "key.filepath" : "", + "key.fully_annotated_decl" : "internal<\/syntaxtype.keyword> func<\/syntaxtype.keyword> combineUsageErrors<\/decl.name><ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>>(_<\/decl.var.parameter.argument_label> lhs<\/decl.var.parameter.name>: CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>><\/decl.var.parameter.type><\/decl.var.parameter>, _<\/decl.var.parameter.argument_label> rhs<\/decl.var.parameter.name>: CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>><\/decl.var.parameter.type><\/decl.var.parameter>) -> CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>><\/decl.function.returntype><\/decl.function.free>", + "key.kind" : "source.lang.swift.decl.function.free", + "key.length" : 410, + "key.line" : 54, + "key.modulename" : "Commandant", + "key.name" : "combineUsageErrors(_:_:)", + "key.namelength" : 105, + "key.nameoffset" : 1674, + "key.offset" : 1669, + "key.parsed_declaration" : "internal func combineUsageErrors(_ lhs: CommandantError, _ rhs: CommandantError) -> CommandantError", + "key.parsed_scope.end" : 66, + "key.parsed_scope.start" : 54, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "ClientError<\/Declaration>", + "key.column" : 34, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 54, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 1693, + "key.offset" : 1693, + "key.parsed_declaration" : "internal func combineUsageErrors (CommandantError, CommandantError) -> CommandantError", + "key.typeusr" : "$sy10Commandant0A5ErrorOyxGAD_ADtcluD", + "key.usr" : "s:10Commandant18combineUsageErrorsyAA0A5ErrorOyxGAE_AEtlF" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "internal func unrecognizedArgumentsError<ClientError>(_ options: [String<\/Type>]) -> CommandantError<\/Type><ClientError<\/Type>><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.internal", + "key.length" : 8, + "key.offset" : 2152 + } + ], + "key.bodylength" : 96, + "key.bodyoffset" : 2260, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Constructs an error that indicates unrecognized arguments remains.", + "key.doc.column" : 15, + "key.doc.comment" : "Constructs an error that indicates unrecognized arguments remains.", + "key.doc.declaration" : "internal func unrecognizedArgumentsError(_ options: [String]) -> CommandantError", + "key.doc.file" : "\/private\/Sources\/Commandant\/Errors.swift", + "key.doc.full_as_xml" : "unrecognizedArgumentsError(_:)<\/Name>s:10Commandant26unrecognizedArgumentsErroryAA0aD0OyxGSaySSGlF<\/USR>internal func unrecognizedArgumentsError<ClientError>(_ options: [String]) -> CommandantError<ClientError><\/Declaration>Constructs an error that indicates unrecognized arguments remains.<\/Para><\/Abstract><\/CommentParts><\/Function>", + "key.doc.line" : 69, + "key.doc.name" : "unrecognizedArgumentsError(_:)", + "key.doc.type" : "Function", + "key.doclength" : 71, + "key.docoffset" : 2081, + "key.filepath" : "", + "key.fully_annotated_decl" : "internal<\/syntaxtype.keyword> func<\/syntaxtype.keyword> unrecognizedArgumentsError<\/decl.name><ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>>(_<\/decl.var.parameter.argument_label> options<\/decl.var.parameter.name>: [String<\/ref.struct>]<\/decl.var.parameter.type><\/decl.var.parameter>) -> CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>><\/decl.function.returntype><\/decl.function.free>", + "key.kind" : "source.lang.swift.decl.function.free", + "key.length" : 196, + "key.line" : 69, + "key.modulename" : "Commandant", + "key.name" : "unrecognizedArgumentsError(_:)", + "key.namelength" : 60, + "key.nameoffset" : 2166, + "key.offset" : 2161, + "key.parsed_declaration" : "internal func unrecognizedArgumentsError(_ options: [String]) -> CommandantError", + "key.parsed_scope.end" : 71, + "key.parsed_scope.start" : 69, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "ClientError<\/Declaration>", + "key.column" : 42, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 69, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 2193, + "key.offset" : 2193, + "key.parsed_declaration" : "internal func unrecognizedArgumentsError ([String]) -> CommandantError", + "key.typeusr" : "$sy10Commandant0A5ErrorOyxGSaySSGcluD", + "key.usr" : "s:10Commandant26unrecognizedArgumentsErroryAA0aD0OyxGSaySSGlF" + }, + { + "key.kind" : "source.lang.swift.syntaxtype.comment.mark", + "key.length" : 14, + "key.name" : "MARK: Argument", + "key.offset" : 2362 + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "internal func informativeUsageError<T, ClientError>(_ valueExample: String<\/Type>, argument: Argument<\/Type><T<\/Type>>) -> CommandantError<\/Type><ClientError<\/Type>><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.internal", + "key.length" : 8, + "key.offset" : 2499 + } + ], + "key.bodylength" : 192, + "key.bodyoffset" : 2631, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Constructs an error that describes how to use the argument, with the given\nexample of value usage if applicable.", + "key.doc.column" : 15, + "key.doc.comment" : "Constructs an error that describes how to use the argument, with the given\nexample of value usage if applicable.", + "key.doc.declaration" : "internal func informativeUsageError(_ valueExample: String, argument: Argument) -> CommandantError", + "key.doc.file" : "\/private\/Sources\/Commandant\/Errors.swift", + "key.doc.full_as_xml" : "informativeUsageError(_:argument:)<\/Name>s:10Commandant21informativeUsageError_8argumentAA0aD0Oyq_GSS_AA8ArgumentVyxGtr0_lF<\/USR>internal func informativeUsageError<T, ClientError>(_ valueExample: String, argument: Argument<T>) -> CommandantError<ClientError><\/Declaration>Constructs an error that describes how to use the argument, with the given example of value usage if applicable.<\/Para><\/Abstract><\/CommentParts><\/Function>", + "key.doc.line" : 77, + "key.doc.name" : "informativeUsageError(_:argument:)", + "key.doc.type" : "Function", + "key.doclength" : 121, + "key.docoffset" : 2378, + "key.filepath" : "", + "key.fully_annotated_decl" : "internal<\/syntaxtype.keyword> func<\/syntaxtype.keyword> informativeUsageError<\/decl.name><T<\/decl.generic_type_param.name><\/decl.generic_type_param>, ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>>(_<\/decl.var.parameter.argument_label> valueExample<\/decl.var.parameter.name>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>, argument<\/decl.var.parameter.argument_label>: Argument<\/ref.struct><T<\/ref.generic_type_param>><\/decl.var.parameter.type><\/decl.var.parameter>) -> CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>><\/decl.function.returntype><\/decl.function.free>", + "key.kind" : "source.lang.swift.decl.function.free", + "key.length" : 316, + "key.line" : 77, + "key.modulename" : "Commandant", + "key.name" : "informativeUsageError(_:argument:)", + "key.namelength" : 84, + "key.nameoffset" : 2513, + "key.offset" : 2508, + "key.parsed_declaration" : "internal func informativeUsageError(_ valueExample: String, argument: Argument) -> CommandantError", + "key.parsed_scope.end" : 83, + "key.parsed_scope.start" : 77, + "key.related_decls" : [ + { + "key.annotated_decl" : "informativeUsageError(_:usage:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Argument<T>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Argument<[T]>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError(_:option:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<T>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<T?>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<[T]>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<[T]?>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<ClientError>(_: Option<Bool>) -> CommandantError<ClientError><\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "T<\/Declaration>", + "key.column" : 37, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "T<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 1, + "key.line" : 77, + "key.modulename" : "Commandant", + "key.name" : "T", + "key.namelength" : 1, + "key.nameoffset" : 2535, + "key.offset" : 2535, + "key.parsed_declaration" : "internal func informativeUsageErrorClientError<\/Declaration>", + "key.column" : 40, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 77, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 2538, + "key.offset" : 2538, + "key.parsed_declaration" : "internal func informativeUsageError (String, argument: Argument) -> CommandantError", + "key.typeusr" : "$s_8argument10Commandant0B5ErrorOyq_GSS_AB8ArgumentVyxGtcr0_luD", + "key.usr" : "s:10Commandant21informativeUsageError_8argumentAA0aD0Oyq_GSS_AA8ArgumentVyxGtr0_lF" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "internal func informativeUsageError<T, ClientError>(_ argument: Argument<\/Type><T<\/Type>>) -> CommandantError<\/Type><ClientError<\/Type>> where T<\/Type> : ArgumentProtocol<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.internal", + "key.length" : 8, + "key.offset" : 2890 + } + ], + "key.bodylength" : 378, + "key.bodyoffset" : 3018, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Constructs an error that describes how to use the argument.", + "key.doc.column" : 15, + "key.doc.comment" : "Constructs an error that describes how to use the argument.", + "key.doc.declaration" : "internal func informativeUsageError(_ argument: Argument) -> CommandantError where T : Commandant.ArgumentProtocol", + "key.doc.file" : "\/private\/Sources\/Commandant\/Errors.swift", + "key.doc.full_as_xml" : "informativeUsageError(_:)<\/Name>s:10Commandant21informativeUsageErroryAA0aD0Oyq_GAA8ArgumentVyxGAA0E8ProtocolRzr0_lF<\/USR>internal func informativeUsageError<T, ClientError>(_ argument: Argument<T>) -> CommandantError<ClientError> where T : Commandant.ArgumentProtocol<\/Declaration>Constructs an error that describes how to use the argument.<\/Para><\/Abstract><\/CommentParts><\/Function>", + "key.doc.line" : 86, + "key.doc.name" : "informativeUsageError(_:)", + "key.doc.type" : "Function", + "key.doclength" : 64, + "key.docoffset" : 2826, + "key.filepath" : "", + "key.fully_annotated_decl" : "internal<\/syntaxtype.keyword> func<\/syntaxtype.keyword> informativeUsageError<\/decl.name><T<\/decl.generic_type_param.name><\/decl.generic_type_param>, ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>>(_<\/decl.var.parameter.argument_label> argument<\/decl.var.parameter.name>: Argument<\/ref.struct><T<\/ref.generic_type_param>><\/decl.var.parameter.type><\/decl.var.parameter>) -> CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>><\/decl.function.returntype> where<\/syntaxtype.keyword> T<\/ref.generic_type_param> : ArgumentProtocol<\/ref.protocol><\/decl.generic_type_requirement><\/decl.function.free>", + "key.kind" : "source.lang.swift.decl.function.free", + "key.length" : 498, + "key.line" : 86, + "key.modulename" : "Commandant", + "key.name" : "informativeUsageError(_:)", + "key.namelength" : 80, + "key.nameoffset" : 2904, + "key.offset" : 2899, + "key.parsed_declaration" : "internal func informativeUsageError(_ argument: Argument) -> CommandantError", + "key.parsed_scope.end" : 103, + "key.parsed_scope.start" : 86, + "key.related_decls" : [ + { + "key.annotated_decl" : "informativeUsageError(_:usage:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError(_:argument:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Argument<[T]>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError(_:option:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<T>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<T?>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<[T]>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<[T]?>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<ClientError>(_: Option<Bool>) -> CommandantError<ClientError><\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "T : ArgumentProtocol<\/Type><\/Declaration>", + "key.column" : 37, + "key.decl_lang" : "source.lang.swift", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 16, + "key.offset" : 2929 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "T<\/decl.generic_type_param.name> : ArgumentProtocol<\/ref.protocol><\/decl.generic_type_param.constraint><\/decl.generic_type_param>", + "key.inheritedtypes" : [ + { + "key.name" : "ArgumentProtocol" + } + ], + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 19, + "key.line" : 86, + "key.modulename" : "Commandant", + "key.name" : "T", + "key.namelength" : 1, + "key.nameoffset" : 2926, + "key.offset" : 2926, + "key.parsed_declaration" : "internal func informativeUsageErrorClientError<\/Declaration>", + "key.column" : 58, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 86, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 2947, + "key.offset" : 2947, + "key.parsed_declaration" : "internal func informativeUsageErrorvar example: String<\/Type><\/Declaration>", + "key.column" : 6, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "var<\/syntaxtype.keyword> example<\/decl.name>: String<\/ref.struct><\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 16, + "key.line" : 87, + "key.modulename" : "Commandant", + "key.name" : "example", + "key.namelength" : 7, + "key.nameoffset" : 3024, + "key.offset" : 3020, + "key.parsed_declaration" : "var example = \"\"", + "key.parsed_scope.end" : 87, + "key.parsed_scope.start" : 87, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant21informativeUsageErroryAA0aD0Oyq_GAA8ArgumentVyxGAA0E8ProtocolRzr0_lF7exampleL_SSvp" + }, + { + "key.annotated_decl" : "var valueExample: String<\/Type><\/Declaration>", + "key.column" : 6, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "var<\/syntaxtype.keyword> valueExample<\/decl.name>: String<\/ref.struct><\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 21, + "key.line" : 89, + "key.modulename" : "Commandant", + "key.name" : "valueExample", + "key.namelength" : 12, + "key.nameoffset" : 3043, + "key.offset" : 3039, + "key.parsed_declaration" : "var valueExample = \"\"", + "key.parsed_scope.end" : 89, + "key.parsed_scope.start" : 89, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant21informativeUsageErroryAA0aD0Oyq_GAA8ArgumentVyxGAA0E8ProtocolRzr0_lF12valueExampleL_SSvp" + } + ], + "key.typename" : " (Argument) -> CommandantError", + "key.typeusr" : "$sy10Commandant0A5ErrorOyq_GAA8ArgumentVyxGcAA0C8ProtocolRzr0_luD", + "key.usr" : "s:10Commandant21informativeUsageErroryAA0aD0Oyq_GAA8ArgumentVyxGAA0E8ProtocolRzr0_lF" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "internal func informativeUsageError<T, ClientError>(_ argument: Argument<\/Type><[T<\/Type>]>) -> CommandantError<\/Type><ClientError<\/Type>> where T<\/Type> : ArgumentProtocol<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.internal", + "key.length" : 8, + "key.offset" : 3468 + } + ], + "key.bodylength" : 378, + "key.bodyoffset" : 3598, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Constructs an error that describes how to use the argument list.", + "key.doc.column" : 15, + "key.doc.comment" : "Constructs an error that describes how to use the argument list.", + "key.doc.declaration" : "internal func informativeUsageError(_ argument: Argument<[T]>) -> CommandantError where T : Commandant.ArgumentProtocol", + "key.doc.file" : "\/private\/Sources\/Commandant\/Errors.swift", + "key.doc.full_as_xml" : "informativeUsageError(_:)<\/Name>s:10Commandant21informativeUsageErroryAA0aD0Oyq_GAA8ArgumentVySayxGGAA0E8ProtocolRzr0_lF<\/USR>internal func informativeUsageError<T, ClientError>(_ argument: Argument<[T]>) -> CommandantError<ClientError> where T : Commandant.ArgumentProtocol<\/Declaration>Constructs an error that describes how to use the argument list.<\/Para><\/Abstract><\/CommentParts><\/Function>", + "key.doc.line" : 106, + "key.doc.name" : "informativeUsageError(_:)", + "key.doc.type" : "Function", + "key.doclength" : 69, + "key.docoffset" : 3399, + "key.filepath" : "", + "key.fully_annotated_decl" : "internal<\/syntaxtype.keyword> func<\/syntaxtype.keyword> informativeUsageError<\/decl.name><T<\/decl.generic_type_param.name><\/decl.generic_type_param>, ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>>(_<\/decl.var.parameter.argument_label> argument<\/decl.var.parameter.name>: Argument<\/ref.struct><[T<\/ref.generic_type_param>]><\/decl.var.parameter.type><\/decl.var.parameter>) -> CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>><\/decl.function.returntype> where<\/syntaxtype.keyword> T<\/ref.generic_type_param> : ArgumentProtocol<\/ref.protocol><\/decl.generic_type_requirement><\/decl.function.free>", + "key.kind" : "source.lang.swift.decl.function.free", + "key.length" : 500, + "key.line" : 106, + "key.modulename" : "Commandant", + "key.name" : "informativeUsageError(_:)", + "key.namelength" : 82, + "key.nameoffset" : 3482, + "key.offset" : 3477, + "key.parsed_declaration" : "internal func informativeUsageError(_ argument: Argument<[T]>) -> CommandantError", + "key.parsed_scope.end" : 123, + "key.parsed_scope.start" : 106, + "key.related_decls" : [ + { + "key.annotated_decl" : "informativeUsageError(_:usage:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError(_:argument:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Argument<T>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError(_:option:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<T>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<T?>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<[T]>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<[T]?>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<ClientError>(_: Option<Bool>) -> CommandantError<ClientError><\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "T : ArgumentProtocol<\/Type><\/Declaration>", + "key.column" : 37, + "key.decl_lang" : "source.lang.swift", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 16, + "key.offset" : 3507 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "T<\/decl.generic_type_param.name> : ArgumentProtocol<\/ref.protocol><\/decl.generic_type_param.constraint><\/decl.generic_type_param>", + "key.inheritedtypes" : [ + { + "key.name" : "ArgumentProtocol" + } + ], + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 19, + "key.line" : 106, + "key.modulename" : "Commandant", + "key.name" : "T", + "key.namelength" : 1, + "key.nameoffset" : 3504, + "key.offset" : 3504, + "key.parsed_declaration" : "internal func informativeUsageErrorClientError<\/Declaration>", + "key.column" : 58, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 106, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 3525, + "key.offset" : 3525, + "key.parsed_declaration" : "internal func informativeUsageErrorvar example: String<\/Type><\/Declaration>", + "key.column" : 6, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "var<\/syntaxtype.keyword> example<\/decl.name>: String<\/ref.struct><\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 16, + "key.line" : 107, + "key.modulename" : "Commandant", + "key.name" : "example", + "key.namelength" : 7, + "key.nameoffset" : 3604, + "key.offset" : 3600, + "key.parsed_declaration" : "var example = \"\"", + "key.parsed_scope.end" : 107, + "key.parsed_scope.start" : 107, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant21informativeUsageErroryAA0aD0Oyq_GAA8ArgumentVySayxGGAA0E8ProtocolRzr0_lF7exampleL_SSvp" + }, + { + "key.annotated_decl" : "var valueExample: String<\/Type><\/Declaration>", + "key.column" : 6, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "var<\/syntaxtype.keyword> valueExample<\/decl.name>: String<\/ref.struct><\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 21, + "key.line" : 109, + "key.modulename" : "Commandant", + "key.name" : "valueExample", + "key.namelength" : 12, + "key.nameoffset" : 3623, + "key.offset" : 3619, + "key.parsed_declaration" : "var valueExample = \"\"", + "key.parsed_scope.end" : 109, + "key.parsed_scope.start" : 109, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant21informativeUsageErroryAA0aD0Oyq_GAA8ArgumentVySayxGGAA0E8ProtocolRzr0_lF12valueExampleL_SSvp" + } + ], + "key.typename" : " (Argument<[T]>) -> CommandantError", + "key.typeusr" : "$sy10Commandant0A5ErrorOyq_GAA8ArgumentVySayxGGcAA0C8ProtocolRzr0_luD", + "key.usr" : "s:10Commandant21informativeUsageErroryAA0aD0Oyq_GAA8ArgumentVySayxGGAA0E8ProtocolRzr0_lF" + }, + { + "key.kind" : "source.lang.swift.syntaxtype.comment.mark", + "key.length" : 12, + "key.name" : "MARK: Option", + "key.offset" : 3982 + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "internal func informativeUsageError<T, ClientError>(_ keyValueExample: String<\/Type>, option: Option<\/Type><T<\/Type>>) -> CommandantError<\/Type><ClientError<\/Type>><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.internal", + "key.length" : 8, + "key.offset" : 4126 + } + ], + "key.bodylength" : 76, + "key.bodyoffset" : 4257, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Constructs an error that describes how to use the option, with the given\nexample of key (and value, if applicable) usage.", + "key.doc.column" : 15, + "key.doc.comment" : "Constructs an error that describes how to use the option, with the given\nexample of key (and value, if applicable) usage.", + "key.doc.declaration" : "internal func informativeUsageError(_ keyValueExample: String, option: Option) -> CommandantError", + "key.doc.file" : "\/private\/Sources\/Commandant\/Errors.swift", + "key.doc.full_as_xml" : "informativeUsageError(_:option:)<\/Name>s:10Commandant21informativeUsageError_6optionAA0aD0Oyq_GSS_AA6OptionVyxGtr0_lF<\/USR>internal func informativeUsageError<T, ClientError>(_ keyValueExample: String, option: Option<T>) -> CommandantError<ClientError><\/Declaration>Constructs an error that describes how to use the option, with the given example of key (and value, if applicable) usage.<\/Para><\/Abstract><\/CommentParts><\/Function>", + "key.doc.line" : 129, + "key.doc.name" : "informativeUsageError(_:option:)", + "key.doc.type" : "Function", + "key.doclength" : 130, + "key.docoffset" : 3996, + "key.filepath" : "", + "key.fully_annotated_decl" : "internal<\/syntaxtype.keyword> func<\/syntaxtype.keyword> informativeUsageError<\/decl.name><T<\/decl.generic_type_param.name><\/decl.generic_type_param>, ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>>(_<\/decl.var.parameter.argument_label> keyValueExample<\/decl.var.parameter.name>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>, option<\/decl.var.parameter.argument_label>: Option<\/ref.struct><T<\/ref.generic_type_param>><\/decl.var.parameter.type><\/decl.var.parameter>) -> CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>><\/decl.function.returntype><\/decl.function.free>", + "key.kind" : "source.lang.swift.decl.function.free", + "key.length" : 199, + "key.line" : 129, + "key.modulename" : "Commandant", + "key.name" : "informativeUsageError(_:option:)", + "key.namelength" : 83, + "key.nameoffset" : 4140, + "key.offset" : 4135, + "key.parsed_declaration" : "internal func informativeUsageError(_ keyValueExample: String, option: Option) -> CommandantError", + "key.parsed_scope.end" : 131, + "key.parsed_scope.start" : 129, + "key.related_decls" : [ + { + "key.annotated_decl" : "informativeUsageError(_:usage:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError(_:argument:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Argument<T>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Argument<[T]>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<T>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<T?>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<[T]>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<[T]?>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<ClientError>(_: Option<Bool>) -> CommandantError<ClientError><\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "T<\/Declaration>", + "key.column" : 37, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "T<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 1, + "key.line" : 129, + "key.modulename" : "Commandant", + "key.name" : "T", + "key.namelength" : 1, + "key.nameoffset" : 4162, + "key.offset" : 4162, + "key.parsed_declaration" : "internal func informativeUsageErrorClientError<\/Declaration>", + "key.column" : 40, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 129, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 4165, + "key.offset" : 4165, + "key.parsed_declaration" : "internal func informativeUsageError (String, option: Option) -> CommandantError", + "key.typeusr" : "$s_6option10Commandant0B5ErrorOyq_GSS_AB6OptionVyxGtcr0_luD", + "key.usr" : "s:10Commandant21informativeUsageError_6optionAA0aD0Oyq_GSS_AA6OptionVyxGtr0_lF" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "internal func informativeUsageError<T, ClientError>(_ option: Option<\/Type><T<\/Type>>) -> CommandantError<\/Type><ClientError<\/Type>> where T<\/Type> : ArgumentProtocol<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.internal", + "key.length" : 8, + "key.offset" : 4398 + } + ], + "key.bodylength" : 89, + "key.bodyoffset" : 4522, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Constructs an error that describes how to use the option.", + "key.doc.column" : 15, + "key.doc.comment" : "Constructs an error that describes how to use the option.", + "key.doc.declaration" : "internal func informativeUsageError(_ option: Option) -> CommandantError where T : Commandant.ArgumentProtocol", + "key.doc.file" : "\/private\/Sources\/Commandant\/Errors.swift", + "key.doc.full_as_xml" : "informativeUsageError(_:)<\/Name>s:10Commandant21informativeUsageErroryAA0aD0Oyq_GAA6OptionVyxGAA16ArgumentProtocolRzr0_lF<\/USR>internal func informativeUsageError<T, ClientError>(_ option: Option<T>) -> CommandantError<ClientError> where T : Commandant.ArgumentProtocol<\/Declaration>Constructs an error that describes how to use the option.<\/Para><\/Abstract><\/CommentParts><\/Function>", + "key.doc.line" : 134, + "key.doc.name" : "informativeUsageError(_:)", + "key.doc.type" : "Function", + "key.doclength" : 62, + "key.docoffset" : 4336, + "key.filepath" : "", + "key.fully_annotated_decl" : "internal<\/syntaxtype.keyword> func<\/syntaxtype.keyword> informativeUsageError<\/decl.name><T<\/decl.generic_type_param.name><\/decl.generic_type_param>, ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>>(_<\/decl.var.parameter.argument_label> option<\/decl.var.parameter.name>: Option<\/ref.struct><T<\/ref.generic_type_param>><\/decl.var.parameter.type><\/decl.var.parameter>) -> CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>><\/decl.function.returntype> where<\/syntaxtype.keyword> T<\/ref.generic_type_param> : ArgumentProtocol<\/ref.protocol><\/decl.generic_type_requirement><\/decl.function.free>", + "key.kind" : "source.lang.swift.decl.function.free", + "key.length" : 205, + "key.line" : 134, + "key.modulename" : "Commandant", + "key.name" : "informativeUsageError(_:)", + "key.namelength" : 76, + "key.nameoffset" : 4412, + "key.offset" : 4407, + "key.parsed_declaration" : "internal func informativeUsageError(_ option: Option) -> CommandantError", + "key.parsed_scope.end" : 136, + "key.parsed_scope.start" : 134, + "key.related_decls" : [ + { + "key.annotated_decl" : "informativeUsageError(_:usage:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError(_:argument:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Argument<T>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Argument<[T]>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError(_:option:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<T?>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<[T]>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<[T]?>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<ClientError>(_: Option<Bool>) -> CommandantError<ClientError><\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "T : ArgumentProtocol<\/Type><\/Declaration>", + "key.column" : 37, + "key.decl_lang" : "source.lang.swift", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 16, + "key.offset" : 4437 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "T<\/decl.generic_type_param.name> : ArgumentProtocol<\/ref.protocol><\/decl.generic_type_param.constraint><\/decl.generic_type_param>", + "key.inheritedtypes" : [ + { + "key.name" : "ArgumentProtocol" + } + ], + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 19, + "key.line" : 134, + "key.modulename" : "Commandant", + "key.name" : "T", + "key.namelength" : 1, + "key.nameoffset" : 4434, + "key.offset" : 4434, + "key.parsed_declaration" : "internal func informativeUsageErrorClientError<\/Declaration>", + "key.column" : 58, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 134, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 4455, + "key.offset" : 4455, + "key.parsed_declaration" : "internal func informativeUsageError (Option) -> CommandantError", + "key.typeusr" : "$sy10Commandant0A5ErrorOyq_GAA6OptionVyxGcAA16ArgumentProtocolRzr0_luD", + "key.usr" : "s:10Commandant21informativeUsageErroryAA0aD0Oyq_GAA6OptionVyxGAA16ArgumentProtocolRzr0_lF" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "internal func informativeUsageError<T, ClientError>(_ option: Option<\/Type><T<\/Type>?>) -> CommandantError<\/Type><ClientError<\/Type>> where T<\/Type> : ArgumentProtocol<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.internal", + "key.length" : 8, + "key.offset" : 4676 + } + ], + "key.bodylength" : 78, + "key.bodyoffset" : 4801, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Constructs an error that describes how to use the option.", + "key.doc.column" : 15, + "key.doc.comment" : "Constructs an error that describes how to use the option.", + "key.doc.declaration" : "internal func informativeUsageError(_ option: Option) -> CommandantError where T : Commandant.ArgumentProtocol", + "key.doc.file" : "\/private\/Sources\/Commandant\/Errors.swift", + "key.doc.full_as_xml" : "informativeUsageError(_:)<\/Name>s:10Commandant21informativeUsageErroryAA0aD0Oyq_GAA6OptionVyxSgGAA16ArgumentProtocolRzr0_lF<\/USR>internal func informativeUsageError<T, ClientError>(_ option: Option<T?>) -> CommandantError<ClientError> where T : Commandant.ArgumentProtocol<\/Declaration>Constructs an error that describes how to use the option.<\/Para><\/Abstract><\/CommentParts><\/Function>", + "key.doc.line" : 139, + "key.doc.name" : "informativeUsageError(_:)", + "key.doc.type" : "Function", + "key.doclength" : 62, + "key.docoffset" : 4614, + "key.filepath" : "", + "key.fully_annotated_decl" : "internal<\/syntaxtype.keyword> func<\/syntaxtype.keyword> informativeUsageError<\/decl.name><T<\/decl.generic_type_param.name><\/decl.generic_type_param>, ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>>(_<\/decl.var.parameter.argument_label> option<\/decl.var.parameter.name>: Option<\/ref.struct><T<\/ref.generic_type_param>?><\/decl.var.parameter.type><\/decl.var.parameter>) -> CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>><\/decl.function.returntype> where<\/syntaxtype.keyword> T<\/ref.generic_type_param> : ArgumentProtocol<\/ref.protocol><\/decl.generic_type_requirement><\/decl.function.free>", + "key.kind" : "source.lang.swift.decl.function.free", + "key.length" : 195, + "key.line" : 139, + "key.modulename" : "Commandant", + "key.name" : "informativeUsageError(_:)", + "key.namelength" : 77, + "key.nameoffset" : 4690, + "key.offset" : 4685, + "key.parsed_declaration" : "internal func informativeUsageError(_ option: Option) -> CommandantError", + "key.parsed_scope.end" : 141, + "key.parsed_scope.start" : 139, + "key.related_decls" : [ + { + "key.annotated_decl" : "informativeUsageError(_:usage:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError(_:argument:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Argument<T>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Argument<[T]>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError(_:option:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<T>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<[T]>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<[T]?>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<ClientError>(_: Option<Bool>) -> CommandantError<ClientError><\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "T : ArgumentProtocol<\/Type><\/Declaration>", + "key.column" : 37, + "key.decl_lang" : "source.lang.swift", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 16, + "key.offset" : 4715 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "T<\/decl.generic_type_param.name> : ArgumentProtocol<\/ref.protocol><\/decl.generic_type_param.constraint><\/decl.generic_type_param>", + "key.inheritedtypes" : [ + { + "key.name" : "ArgumentProtocol" + } + ], + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 19, + "key.line" : 139, + "key.modulename" : "Commandant", + "key.name" : "T", + "key.namelength" : 1, + "key.nameoffset" : 4712, + "key.offset" : 4712, + "key.parsed_declaration" : "internal func informativeUsageErrorClientError<\/Declaration>", + "key.column" : 58, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 139, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 4733, + "key.offset" : 4733, + "key.parsed_declaration" : "internal func informativeUsageError (Option) -> CommandantError", + "key.typeusr" : "$sy10Commandant0A5ErrorOyq_GAA6OptionVyxSgGcAA16ArgumentProtocolRzr0_luD", + "key.usr" : "s:10Commandant21informativeUsageErroryAA0aD0Oyq_GAA6OptionVyxSgGAA16ArgumentProtocolRzr0_lF" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "internal func informativeUsageError<T, ClientError>(_ option: Option<\/Type><[T<\/Type>]>) -> CommandantError<\/Type><ClientError<\/Type>> where T<\/Type> : ArgumentProtocol<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.internal", + "key.length" : 8, + "key.offset" : 4944 + } + ], + "key.bodylength" : 91, + "key.bodyoffset" : 5070, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Constructs an error that describes how to use the option.", + "key.doc.column" : 15, + "key.doc.comment" : "Constructs an error that describes how to use the option.", + "key.doc.declaration" : "internal func informativeUsageError(_ option: Option<[T]>) -> CommandantError where T : Commandant.ArgumentProtocol", + "key.doc.file" : "\/private\/Sources\/Commandant\/Errors.swift", + "key.doc.full_as_xml" : "informativeUsageError(_:)<\/Name>s:10Commandant21informativeUsageErroryAA0aD0Oyq_GAA6OptionVySayxGGAA16ArgumentProtocolRzr0_lF<\/USR>internal func informativeUsageError<T, ClientError>(_ option: Option<[T]>) -> CommandantError<ClientError> where T : Commandant.ArgumentProtocol<\/Declaration>Constructs an error that describes how to use the option.<\/Para><\/Abstract><\/CommentParts><\/Function>", + "key.doc.line" : 144, + "key.doc.name" : "informativeUsageError(_:)", + "key.doc.type" : "Function", + "key.doclength" : 62, + "key.docoffset" : 4882, + "key.filepath" : "", + "key.fully_annotated_decl" : "internal<\/syntaxtype.keyword> func<\/syntaxtype.keyword> informativeUsageError<\/decl.name><T<\/decl.generic_type_param.name><\/decl.generic_type_param>, ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>>(_<\/decl.var.parameter.argument_label> option<\/decl.var.parameter.name>: Option<\/ref.struct><[T<\/ref.generic_type_param>]><\/decl.var.parameter.type><\/decl.var.parameter>) -> CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>><\/decl.function.returntype> where<\/syntaxtype.keyword> T<\/ref.generic_type_param> : ArgumentProtocol<\/ref.protocol><\/decl.generic_type_requirement><\/decl.function.free>", + "key.kind" : "source.lang.swift.decl.function.free", + "key.length" : 209, + "key.line" : 144, + "key.modulename" : "Commandant", + "key.name" : "informativeUsageError(_:)", + "key.namelength" : 78, + "key.nameoffset" : 4958, + "key.offset" : 4953, + "key.parsed_declaration" : "internal func informativeUsageError(_ option: Option<[T]>) -> CommandantError", + "key.parsed_scope.end" : 146, + "key.parsed_scope.start" : 144, + "key.related_decls" : [ + { + "key.annotated_decl" : "informativeUsageError(_:usage:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError(_:argument:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Argument<T>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Argument<[T]>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError(_:option:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<T>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<T?>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<[T]?>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<ClientError>(_: Option<Bool>) -> CommandantError<ClientError><\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "T : ArgumentProtocol<\/Type><\/Declaration>", + "key.column" : 37, + "key.decl_lang" : "source.lang.swift", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 16, + "key.offset" : 4983 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "T<\/decl.generic_type_param.name> : ArgumentProtocol<\/ref.protocol><\/decl.generic_type_param.constraint><\/decl.generic_type_param>", + "key.inheritedtypes" : [ + { + "key.name" : "ArgumentProtocol" + } + ], + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 19, + "key.line" : 144, + "key.modulename" : "Commandant", + "key.name" : "T", + "key.namelength" : 1, + "key.nameoffset" : 4980, + "key.offset" : 4980, + "key.parsed_declaration" : "internal func informativeUsageErrorClientError<\/Declaration>", + "key.column" : 58, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 144, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 5001, + "key.offset" : 5001, + "key.parsed_declaration" : "internal func informativeUsageError (Option<[T]>) -> CommandantError", + "key.typeusr" : "$sy10Commandant0A5ErrorOyq_GAA6OptionVySayxGGcAA16ArgumentProtocolRzr0_luD", + "key.usr" : "s:10Commandant21informativeUsageErroryAA0aD0Oyq_GAA6OptionVySayxGGAA16ArgumentProtocolRzr0_lF" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "internal func informativeUsageError<T, ClientError>(_ option: Option<\/Type><[T<\/Type>]?>) -> CommandantError<\/Type><ClientError<\/Type>> where T<\/Type> : ArgumentProtocol<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.internal", + "key.length" : 8, + "key.offset" : 5226 + } + ], + "key.bodylength" : 78, + "key.bodyoffset" : 5353, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Constructs an error that describes how to use the option.", + "key.doc.column" : 15, + "key.doc.comment" : "Constructs an error that describes how to use the option.", + "key.doc.declaration" : "internal func informativeUsageError(_ option: Option<[T]?>) -> CommandantError where T : Commandant.ArgumentProtocol", + "key.doc.file" : "\/private\/Sources\/Commandant\/Errors.swift", + "key.doc.full_as_xml" : "informativeUsageError(_:)<\/Name>s:10Commandant21informativeUsageErroryAA0aD0Oyq_GAA6OptionVySayxGSgGAA16ArgumentProtocolRzr0_lF<\/USR>internal func informativeUsageError<T, ClientError>(_ option: Option<[T]?>) -> CommandantError<ClientError> where T : Commandant.ArgumentProtocol<\/Declaration>Constructs an error that describes how to use the option.<\/Para><\/Abstract><\/CommentParts><\/Function>", + "key.doc.line" : 149, + "key.doc.name" : "informativeUsageError(_:)", + "key.doc.type" : "Function", + "key.doclength" : 62, + "key.docoffset" : 5164, + "key.filepath" : "", + "key.fully_annotated_decl" : "internal<\/syntaxtype.keyword> func<\/syntaxtype.keyword> informativeUsageError<\/decl.name><T<\/decl.generic_type_param.name><\/decl.generic_type_param>, ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>>(_<\/decl.var.parameter.argument_label> option<\/decl.var.parameter.name>: Option<\/ref.struct><[T<\/ref.generic_type_param>]?><\/decl.var.parameter.type><\/decl.var.parameter>) -> CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>><\/decl.function.returntype> where<\/syntaxtype.keyword> T<\/ref.generic_type_param> : ArgumentProtocol<\/ref.protocol><\/decl.generic_type_requirement><\/decl.function.free>", + "key.kind" : "source.lang.swift.decl.function.free", + "key.length" : 197, + "key.line" : 149, + "key.modulename" : "Commandant", + "key.name" : "informativeUsageError(_:)", + "key.namelength" : 79, + "key.nameoffset" : 5240, + "key.offset" : 5235, + "key.parsed_declaration" : "internal func informativeUsageError(_ option: Option<[T]?>) -> CommandantError", + "key.parsed_scope.end" : 151, + "key.parsed_scope.start" : 149, + "key.related_decls" : [ + { + "key.annotated_decl" : "informativeUsageError(_:usage:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError(_:argument:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Argument<T>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Argument<[T]>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError(_:option:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<T>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<T?>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<[T]>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<ClientError>(_: Option<Bool>) -> CommandantError<ClientError><\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "T : ArgumentProtocol<\/Type><\/Declaration>", + "key.column" : 37, + "key.decl_lang" : "source.lang.swift", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 16, + "key.offset" : 5265 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "T<\/decl.generic_type_param.name> : ArgumentProtocol<\/ref.protocol><\/decl.generic_type_param.constraint><\/decl.generic_type_param>", + "key.inheritedtypes" : [ + { + "key.name" : "ArgumentProtocol" + } + ], + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 19, + "key.line" : 149, + "key.modulename" : "Commandant", + "key.name" : "T", + "key.namelength" : 1, + "key.nameoffset" : 5262, + "key.offset" : 5262, + "key.parsed_declaration" : "internal func informativeUsageErrorClientError<\/Declaration>", + "key.column" : 58, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 149, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 5283, + "key.offset" : 5283, + "key.parsed_declaration" : "internal func informativeUsageError (Option<[T]?>) -> CommandantError", + "key.typeusr" : "$sy10Commandant0A5ErrorOyq_GAA6OptionVySayxGSgGcAA16ArgumentProtocolRzr0_luD", + "key.usr" : "s:10Commandant21informativeUsageErroryAA0aD0Oyq_GAA6OptionVySayxGSgGAA16ArgumentProtocolRzr0_lF" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "internal func informativeUsageError<ClientError>(_ option: Option<\/Type><Bool<\/Type>>) -> CommandantError<\/Type><ClientError<\/Type>><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.internal", + "key.length" : 8, + "key.offset" : 5510 + } + ], + "key.bodylength" : 121, + "key.bodyoffset" : 5616, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Constructs an error that describes how to use the given boolean option.", + "key.doc.column" : 15, + "key.doc.comment" : "Constructs an error that describes how to use the given boolean option.", + "key.doc.declaration" : "internal func informativeUsageError(_ option: Option) -> CommandantError", + "key.doc.file" : "\/private\/Sources\/Commandant\/Errors.swift", + "key.doc.full_as_xml" : "informativeUsageError(_:)<\/Name>s:10Commandant21informativeUsageErroryAA0aD0OyxGAA6OptionVySbGlF<\/USR>internal func informativeUsageError<ClientError>(_ option: Option<Bool>) -> CommandantError<ClientError><\/Declaration>Constructs an error that describes how to use the given boolean option.<\/Para><\/Abstract><\/CommentParts><\/Function>", + "key.doc.line" : 154, + "key.doc.name" : "informativeUsageError(_:)", + "key.doc.type" : "Function", + "key.doclength" : 76, + "key.docoffset" : 5434, + "key.filepath" : "", + "key.fully_annotated_decl" : "internal<\/syntaxtype.keyword> func<\/syntaxtype.keyword> informativeUsageError<\/decl.name><ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>>(_<\/decl.var.parameter.argument_label> option<\/decl.var.parameter.name>: Option<\/ref.struct><Bool<\/ref.struct>><\/decl.var.parameter.type><\/decl.var.parameter>) -> CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>><\/decl.function.returntype><\/decl.function.free>", + "key.kind" : "source.lang.swift.decl.function.free", + "key.length" : 219, + "key.line" : 154, + "key.modulename" : "Commandant", + "key.name" : "informativeUsageError(_:)", + "key.namelength" : 58, + "key.nameoffset" : 5524, + "key.offset" : 5519, + "key.parsed_declaration" : "internal func informativeUsageError(_ option: Option) -> CommandantError", + "key.parsed_scope.end" : 157, + "key.parsed_scope.start" : 154, + "key.related_decls" : [ + { + "key.annotated_decl" : "informativeUsageError(_:usage:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError(_:argument:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Argument<T>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Argument<[T]>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError(_:option:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<T>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<T?>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<[T]>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<[T]?>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "ClientError<\/Declaration>", + "key.column" : 37, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 154, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 5546, + "key.offset" : 5546, + "key.parsed_declaration" : "internal func informativeUsageErrorlet key: String<\/Type><\/Declaration>", + "key.column" : 6, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "let<\/syntaxtype.keyword> key<\/decl.name>: String<\/ref.struct><\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 20, + "key.line" : 155, + "key.modulename" : "Commandant", + "key.name" : "key", + "key.namelength" : 3, + "key.nameoffset" : 5622, + "key.offset" : 5618, + "key.parsed_declaration" : "let key = option.key", + "key.parsed_scope.end" : 155, + "key.parsed_scope.start" : 155, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant21informativeUsageErroryAA0aD0OyxGAA6OptionVySbGlF3keyL_SSvp" + } + ], + "key.typename" : " (Option) -> CommandantError", + "key.typeusr" : "$sy10Commandant0A5ErrorOyxGAA6OptionVySbGcluD", + "key.usr" : "s:10Commandant21informativeUsageErroryAA0aD0OyxGAA6OptionVySbGlF" + } + ] + } +}, { + "\/Sources\/Commandant\/HelpCommand.swift" : { + "key.diagnostic_stage" : "source.diagnostic.stage.swift.parse", + "key.length" : 2203, + "key.offset" : 0, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public struct HelpCommand<ClientError> : CommandProtocol<\/Type> where ClientError<\/Type> : Error<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 537 + } + ], + "key.bodylength" : 1127, + "key.bodyoffset" : 601, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A basic implementation of a `help` command, using information available in a\n`CommandRegistry`.\n\nIf you want to use this command, initialize it with the registry, then add\nit to that same registry:\n\n\tlet commands: CommandRegistry = …\n\tlet helpCommand = HelpCommand(registry: commands)\n\tcommands.register(helpCommand)", + "key.doc.column" : 15, + "key.doc.comment" : "A basic implementation of a `help` command, using information available in a\n`CommandRegistry`.\n\nIf you want to use this command, initialize it with the registry, then add\nit to that same registry:\n\n\tlet commands: CommandRegistry = …\n\tlet helpCommand = HelpCommand(registry: commands)\n\tcommands.register(helpCommand)", + "key.doc.declaration" : "public struct HelpCommand : CommandProtocol where ClientError : Error", + "key.doc.discussion" : [ + { + "Para" : "If you want to use this command, initialize it with the registry, then add it to that same registry:" + }, + { + "CodeListing" : "" + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/HelpCommand.swift", + "key.doc.full_as_xml" : "HelpCommand<\/Name>s:10Commandant11HelpCommandV<\/USR>public struct HelpCommand<ClientError> : CommandProtocol where ClientError : Error<\/Declaration>A basic implementation of a help<\/codeVoice> command, using information available in a CommandRegistry<\/codeVoice>.<\/Para><\/Abstract>If you want to use this command, initialize it with the registry, then add it to that same registry:<\/Para> = …]]><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing><\/Discussion><\/CommentParts><\/Class>", + "key.doc.line" : 20, + "key.doc.name" : "HelpCommand", + "key.doc.type" : "Class", + "key.doclength" : 366, + "key.docoffset" : 171, + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 15, + "key.offset" : 584 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> struct<\/syntaxtype.keyword> HelpCommand<\/decl.name><ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>> : CommandProtocol<\/ref.protocol> where<\/syntaxtype.keyword> ClientError<\/ref.generic_type_param> : Error<\/ref.protocol><\/decl.generic_type_requirement><\/decl.struct>", + "key.inheritedtypes" : [ + { + "key.name" : "CommandProtocol" + } + ], + "key.kind" : "source.lang.swift.decl.struct", + "key.length" : 1185, + "key.line" : 20, + "key.modulename" : "Commandant", + "key.name" : "HelpCommand", + "key.namelength" : 11, + "key.nameoffset" : 551, + "key.offset" : 544, + "key.parsed_declaration" : "public struct HelpCommand: CommandProtocol", + "key.parsed_scope.end" : 59, + "key.parsed_scope.start" : 20, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "ClientError : Error<\/Type><\/Declaration>", + "key.column" : 27, + "key.decl_lang" : "source.lang.swift", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 5, + "key.offset" : 576 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name> : Error<\/ref.protocol><\/decl.generic_type_param.constraint><\/decl.generic_type_param>", + "key.inheritedtypes" : [ + { + "key.name" : "Error" + } + ], + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 18, + "key.line" : 20, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 563, + "key.offset" : 563, + "key.parsed_declaration" : "public struct HelpCommandClientError<\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.typename" : "ClientError.Type", + "key.typeusr" : "$sxmD", + "key.usr" : "s:10Commandant11HelpCommandV11ClientErrorxmfp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public typealias HelpCommand<\/Type><ClientError<\/Type>>.Options = HelpOptions<\/Type><ClientError<\/Type>><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 603 + } + ], + "key.column" : 19, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "The command's options type.", + "key.doc.column" : 17, + "key.doc.declaration" : "associatedtype Options : Commandant.OptionsProtocol", + "key.doc.discussion" : [ + { + "Note" : "" + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Command.swift", + "key.doc.full_as_xml" : "Options<\/Name>s:10Commandant15CommandProtocolP7OptionsQa<\/USR>associatedtype Options : Commandant.OptionsProtocol<\/Declaration>The command’s options type.<\/Para><\/Abstract>This documentation comment was inherited from CommandProtocol<\/codeVoice>.<\/Para><\/Note><\/Discussion><\/CommentParts><\/Other>", + "key.doc.line" : 15, + "key.doc.name" : "Options", + "key.doc.type" : "Other", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> typealias<\/syntaxtype.keyword> HelpCommand<\/ref.struct><ClientError<\/ref.generic_type_param>>.Options<\/decl.name> = HelpOptions<\/ref.struct><ClientError<\/ref.generic_type_param>><\/decl.typealias>", + "key.kind" : "source.lang.swift.decl.typealias", + "key.length" : 44, + "key.line" : 21, + "key.modulename" : "Commandant", + "key.name" : "Options", + "key.namelength" : 7, + "key.nameoffset" : 620, + "key.offset" : 610, + "key.overrides" : [ + { + "key.usr" : "s:10Commandant15CommandProtocolP7OptionsQa" + } + ], + "key.parsed_declaration" : "public typealias Options = HelpOptions", + "key.parsed_scope.end" : 21, + "key.parsed_scope.start" : 21, + "key.reusingastcontext" : false, + "key.typename" : "HelpOptions.Type", + "key.typeusr" : "$s10Commandant11HelpOptionsVyxGmD", + "key.usr" : "s:10Commandant15CommandProtocolP7OptionsQa" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public let verb: String<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 657 + } + ], + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "The action that users should specify to use this subcommand (e.g.,\n`help`).", + "key.doc.column" : 6, + "key.doc.declaration" : "var verb: String { get }", + "key.doc.discussion" : [ + { + "Note" : "" + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Command.swift", + "key.doc.full_as_xml" : "verb<\/Name>s:10Commandant15CommandProtocolP4verbSSvp<\/USR>var verb: String { get }<\/Declaration>The action that users should specify to use this subcommand (e.g., help<\/codeVoice>).<\/Para><\/Abstract>This documentation comment was inherited from CommandProtocol<\/codeVoice>.<\/Para><\/Note><\/Discussion><\/CommentParts><\/Other>", + "key.doc.line" : 21, + "key.doc.name" : "verb", + "key.doc.type" : "Other", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> let<\/syntaxtype.keyword> verb<\/decl.name>: String<\/ref.struct><\/decl.var.type><\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 17, + "key.line" : 23, + "key.modulename" : "Commandant", + "key.name" : "verb", + "key.namelength" : 4, + "key.nameoffset" : 668, + "key.offset" : 664, + "key.overrides" : [ + { + "key.usr" : "s:10Commandant15CommandProtocolP4verbSSvp" + } + ], + "key.parsed_declaration" : "public let verb = \"help\"", + "key.parsed_scope.end" : 23, + "key.parsed_scope.start" : 23, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant15CommandProtocolP4verbSSvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public let function: String<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 683 + } + ], + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A human-readable, high-level description of what this command is used\nfor.", + "key.doc.column" : 6, + "key.doc.declaration" : "var function: String { get }", + "key.doc.discussion" : [ + { + "Note" : "" + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Command.swift", + "key.doc.full_as_xml" : "function<\/Name>s:10Commandant15CommandProtocolP8functionSSvp<\/USR>var function: String { get }<\/Declaration>A human-readable, high-level description of what this command is used for.<\/Para><\/Abstract>This documentation comment was inherited from CommandProtocol<\/codeVoice>.<\/Para><\/Note><\/Discussion><\/CommentParts><\/Other>", + "key.doc.line" : 25, + "key.doc.name" : "function", + "key.doc.type" : "Other", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> let<\/syntaxtype.keyword> function<\/decl.name>: String<\/ref.struct><\/decl.var.type><\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 20, + "key.line" : 24, + "key.modulename" : "Commandant", + "key.name" : "function", + "key.namelength" : 8, + "key.nameoffset" : 694, + "key.offset" : 690, + "key.overrides" : [ + { + "key.usr" : "s:10Commandant15CommandProtocolP8functionSSvp" + } + ], + "key.parsed_declaration" : "public let function: String", + "key.parsed_scope.end" : 24, + "key.parsed_scope.start" : 24, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant15CommandProtocolP8functionSSvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.private", + "key.annotated_decl" : "private let registry: CommandRegistry<\/Type><ClientError<\/Type>><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.private", + "key.length" : 7, + "key.offset" : 713 + } + ], + "key.column" : 14, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "private<\/syntaxtype.keyword> let<\/syntaxtype.keyword> registry<\/decl.name>: CommandRegistry<\/ref.class><ClientError<\/ref.generic_type_param>><\/decl.var.type><\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 42, + "key.line" : 26, + "key.modulename" : "Commandant", + "key.name" : "registry", + "key.namelength" : 8, + "key.nameoffset" : 725, + "key.offset" : 721, + "key.parsed_declaration" : "private let registry: CommandRegistry", + "key.parsed_scope.end" : 26, + "key.parsed_scope.start" : 26, + "key.reusingastcontext" : false, + "key.typename" : "CommandRegistry", + "key.typeusr" : "$s10Commandant15CommandRegistryCyxGD", + "key.usr" : "s:10Commandant11HelpCommandV8registry33_38F61CE0DF9D73793CEDF5D1C3140331LLAA0C8RegistryCyxGvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public init(registry: CommandRegistry<\/Type><ClientError<\/Type>>, function: String<\/Type>? = nil)<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 853 + } + ], + "key.bodylength" : 102, + "key.bodyoffset" : 931, + "key.column" : 9, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Initializes the command to provide help from the given registry of\ncommands.", + "key.doc.column" : 9, + "key.doc.comment" : "Initializes the command to provide help from the given registry of\ncommands.", + "key.doc.declaration" : "public init(registry: CommandRegistry, function: String? = nil)", + "key.doc.file" : "\/private\/Sources\/Commandant\/HelpCommand.swift", + "key.doc.full_as_xml" : "init(registry:function:)<\/Name>s:10Commandant11HelpCommandV8registry8functionACyxGAA0C8RegistryCyxG_SSSgtcfc<\/USR>public init(registry: CommandRegistry<ClientError>, function: String? = nil)<\/Declaration>Initializes the command to provide help from the given registry of commands.<\/Para><\/Abstract><\/CommentParts><\/Function>", + "key.doc.line" : 30, + "key.doc.name" : "init(registry:function:)", + "key.doc.type" : "Function", + "key.doclength" : 86, + "key.docoffset" : 766, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> init<\/syntaxtype.keyword>(registry<\/decl.var.parameter.argument_label>: CommandRegistry<\/ref.class><ClientError<\/ref.generic_type_param>><\/decl.var.parameter.type><\/decl.var.parameter>, function<\/decl.var.parameter.argument_label>: String<\/ref.struct>?<\/decl.var.parameter.type> = nil<\/decl.var.parameter>)<\/decl.function.constructor>", + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 174, + "key.line" : 30, + "key.modulename" : "Commandant", + "key.name" : "init(registry:function:)", + "key.namelength" : 69, + "key.nameoffset" : 860, + "key.offset" : 860, + "key.parsed_declaration" : "public init(registry: CommandRegistry, function: String? = nil)", + "key.parsed_scope.end" : 33, + "key.parsed_scope.start" : 30, + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : " (HelpCommand.Type) -> (CommandRegistry, String?) -> HelpCommand", + "key.typeusr" : "$s8registry8function10Commandant11HelpCommandVyxGAC0E8RegistryCyxG_SSSgtcD", + "key.usr" : "s:10Commandant11HelpCommandV8registry8functionACyxGAA0C8RegistryCyxG_SSSgtcfc" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public func run(_ options: Options<\/Type>) -> Result<\/Type><(), ClientError<\/Type>><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 1037 + } + ], + "key.bodylength" : 625, + "key.bodyoffset" : 1101, + "key.column" : 14, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Runs this subcommand with the given options.", + "key.doc.column" : 7, + "key.doc.declaration" : "func run(_ options: Options) -> Result<(), ClientError>", + "key.doc.discussion" : [ + { + "Note" : "" + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Command.swift", + "key.doc.full_as_xml" : "run(_:)<\/Name>s:10Commandant15CommandProtocolP3runys6ResultOyyt11ClientErrorQzG7OptionsQzF<\/USR>func run(_ options: Options) -> Result<(), ClientError><\/Declaration>Runs this subcommand with the given options.<\/Para><\/Abstract>This documentation comment was inherited from CommandProtocol<\/codeVoice>.<\/Para><\/Note><\/Discussion><\/CommentParts><\/Function>", + "key.doc.line" : 28, + "key.doc.name" : "run(_:)", + "key.doc.type" : "Function", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> func<\/syntaxtype.keyword> run<\/decl.name>(_<\/decl.var.parameter.argument_label> options<\/decl.var.parameter.name>: Options<\/ref.typealias><\/decl.var.parameter.type><\/decl.var.parameter>) -> Result<\/ref.enum><()<\/tuple>, ClientError<\/ref.generic_type_param>><\/decl.function.returntype><\/decl.function.method.instance>", + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 683, + "key.line" : 35, + "key.modulename" : "Commandant", + "key.name" : "run(_:)", + "key.namelength" : 23, + "key.nameoffset" : 1049, + "key.offset" : 1044, + "key.overrides" : [ + { + "key.usr" : "s:10Commandant15CommandProtocolP3runys6ResultOyyt11ClientErrorQzG7OptionsQzF" + } + ], + "key.parsed_declaration" : "public func run(_ options: Options) -> Result<(), ClientError>", + "key.parsed_scope.end" : 58, + "key.parsed_scope.start" : 35, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "let maxVerbLength: Int<\/Type><\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "let<\/syntaxtype.keyword> maxVerbLength<\/decl.name>: Int<\/ref.struct><\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 75, + "key.line" : 50, + "key.modulename" : "Commandant", + "key.name" : "maxVerbLength", + "key.namelength" : 13, + "key.nameoffset" : 1422, + "key.offset" : 1418, + "key.parsed_declaration" : "let maxVerbLength = self.registry.commands.map { $0.verb.count }.max() ?? 0", + "key.parsed_scope.end" : 50, + "key.parsed_scope.start" : 50, + "key.reusingastcontext" : false, + "key.typename" : "Int", + "key.typeusr" : "$sSiD", + "key.usr" : "s:10Commandant11HelpCommandV3runys6ResultOyytxGAA0B7OptionsVyxGF13maxVerbLengthL_Sivp" + } + ], + "key.typename" : " (HelpCommand) -> (HelpOptions) -> Result<(), ClientError>", + "key.typeusr" : "$sys6ResultOyytxG10Commandant11HelpOptionsVyxGcD", + "key.usr" : "s:10Commandant15CommandProtocolP3runys6ResultOyyt11ClientErrorQzG7OptionsQzF" + } + ], + "key.typename" : "HelpCommand.Type", + "key.typeusr" : "$s10Commandant11HelpCommandVyxGmD", + "key.usr" : "s:10Commandant11HelpCommandV" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public struct HelpOptions<ClientError> : OptionsProtocol<\/Type> where ClientError<\/Type> : Error<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 1731 + } + ], + "key.bodylength" : 406, + "key.bodyoffset" : 1795, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 15, + "key.offset" : 1778 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> struct<\/syntaxtype.keyword> HelpOptions<\/decl.name><ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>> : OptionsProtocol<\/ref.protocol> where<\/syntaxtype.keyword> ClientError<\/ref.generic_type_param> : Error<\/ref.protocol><\/decl.generic_type_requirement><\/decl.struct>", + "key.inheritedtypes" : [ + { + "key.name" : "OptionsProtocol" + } + ], + "key.kind" : "source.lang.swift.decl.struct", + "key.length" : 464, + "key.line" : 61, + "key.modulename" : "Commandant", + "key.name" : "HelpOptions", + "key.namelength" : 11, + "key.nameoffset" : 1745, + "key.offset" : 1738, + "key.parsed_declaration" : "public struct HelpOptions: OptionsProtocol", + "key.parsed_scope.end" : 76, + "key.parsed_scope.start" : 61, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "ClientError : Error<\/Type><\/Declaration>", + "key.column" : 27, + "key.decl_lang" : "source.lang.swift", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 5, + "key.offset" : 1770 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name> : Error<\/ref.protocol><\/decl.generic_type_param.constraint><\/decl.generic_type_param>", + "key.inheritedtypes" : [ + { + "key.name" : "Error" + } + ], + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 18, + "key.line" : 61, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 1757, + "key.offset" : 1757, + "key.parsed_declaration" : "public struct HelpOptionsClientError<\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.typename" : "ClientError.Type", + "key.typeusr" : "$sxmD", + "key.usr" : "s:10Commandant11HelpOptionsV11ClientErrorxmfp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.fileprivate", + "key.annotated_decl" : "fileprivate let verb: String<\/Type>?<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.fileprivate", + "key.length" : 11, + "key.offset" : 1797 + } + ], + "key.column" : 18, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "fileprivate<\/syntaxtype.keyword> let<\/syntaxtype.keyword> verb<\/decl.name>: String<\/ref.struct>?<\/decl.var.type><\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 17, + "key.line" : 62, + "key.modulename" : "Commandant", + "key.name" : "verb", + "key.namelength" : 4, + "key.nameoffset" : 1813, + "key.offset" : 1809, + "key.parsed_declaration" : "fileprivate let verb: String?", + "key.parsed_scope.end" : 62, + "key.parsed_scope.start" : 62, + "key.reusingastcontext" : false, + "key.typename" : "String?", + "key.typeusr" : "$sSSSgD", + "key.usr" : "s:10Commandant11HelpOptionsV4verb33_38F61CE0DF9D73793CEDF5D1C3140331LLSSSgvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.private", + "key.annotated_decl" : "private init(verb: String<\/Type>?)<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.private", + "key.length" : 7, + "key.offset" : 1829 + } + ], + "key.bodylength" : 21, + "key.bodyoffset" : 1858, + "key.column" : 10, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "private<\/syntaxtype.keyword> init<\/syntaxtype.keyword>(verb<\/decl.var.parameter.argument_label>: String<\/ref.struct>?<\/decl.var.parameter.type><\/decl.var.parameter>)<\/decl.function.constructor>", + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 43, + "key.line" : 64, + "key.modulename" : "Commandant", + "key.name" : "init(verb:)", + "key.namelength" : 19, + "key.nameoffset" : 1837, + "key.offset" : 1837, + "key.parsed_declaration" : "private init(verb: String?)", + "key.parsed_scope.end" : 66, + "key.parsed_scope.start" : 64, + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : " (HelpOptions.Type) -> (String?) -> HelpOptions", + "key.typeusr" : "$s4verb10Commandant11HelpOptionsVyxGSSSg_tcD", + "key.usr" : "s:10Commandant11HelpOptionsV4verbACyxGSSSg_tc33_38F61CE0DF9D73793CEDF5D1C3140331Llfc" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.private", + "key.annotated_decl" : "private static func create(_ verb: String<\/Type>) -> HelpOptions<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.private", + "key.length" : 7, + "key.offset" : 1883 + } + ], + "key.bodylength" : 54, + "key.bodyoffset" : 1942, + "key.column" : 22, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "private<\/syntaxtype.keyword> static<\/syntaxtype.keyword> func<\/syntaxtype.keyword> create<\/decl.name>(_<\/decl.var.parameter.argument_label> verb<\/decl.var.parameter.name>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>) -> HelpOptions<\/ref.struct><\/decl.function.returntype><\/decl.function.method.static>", + "key.kind" : "source.lang.swift.decl.function.method.static", + "key.length" : 106, + "key.line" : 68, + "key.modulename" : "Commandant", + "key.name" : "create(_:)", + "key.namelength" : 22, + "key.nameoffset" : 1903, + "key.offset" : 1891, + "key.parsed_declaration" : "private static func create(_ verb: String) -> HelpOptions", + "key.parsed_scope.end" : 70, + "key.parsed_scope.start" : 68, + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : " (HelpOptions.Type) -> (String) -> HelpOptions", + "key.typeusr" : "$sy10Commandant11HelpOptionsVyxGSScD", + "key.usr" : "s:10Commandant11HelpOptionsV6create33_38F61CE0DF9D73793CEDF5D1C3140331LLyACyxGSSFZ" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public static func evaluate(_ m: CommandMode<\/Type>) -> Result<\/Type><HelpOptions<\/Type>, CommandantError<\/Type><ClientError<\/Type>>><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 2000 + } + ], + "key.bodylength" : 99, + "key.bodyoffset" : 2100, + "key.column" : 21, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Evaluates this set of options in the given mode.\n\nReturns the parsed options or a `UsageError`.", + "key.doc.column" : 14, + "key.doc.declaration" : "static func evaluate(_ m: CommandMode) -> Result>", + "key.doc.discussion" : [ + { + "Para" : "Returns the parsed options or a `UsageError`." + }, + { + "Note" : "" + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Option.swift", + "key.doc.full_as_xml" : "evaluate(_:)<\/Name>s:10Commandant15OptionsProtocolP8evaluateys6ResultOyxAA0A5ErrorOy06ClientF0QzGGAA11CommandModeOFZ<\/USR>static func evaluate(_ m: CommandMode) -> Result<Self, CommandantError<ClientError>><\/Declaration>Evaluates this set of options in the given mode.<\/Para><\/Abstract>Returns the parsed options or a UsageError<\/codeVoice>.<\/Para>This documentation comment was inherited from OptionsProtocol<\/codeVoice>.<\/Para><\/Note><\/Discussion><\/CommentParts><\/Function>", + "key.doc.line" : 43, + "key.doc.name" : "evaluate(_:)", + "key.doc.type" : "Function", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> static<\/syntaxtype.keyword> func<\/syntaxtype.keyword> evaluate<\/decl.name>(_<\/decl.var.parameter.argument_label> m<\/decl.var.parameter.name>: CommandMode<\/ref.enum><\/decl.var.parameter.type><\/decl.var.parameter>) -> Result<\/ref.enum><HelpOptions<\/ref.struct>, CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>>><\/decl.function.returntype><\/decl.function.method.static>", + "key.kind" : "source.lang.swift.decl.function.method.static", + "key.length" : 193, + "key.line" : 72, + "key.modulename" : "Commandant", + "key.name" : "evaluate(_:)", + "key.namelength" : 26, + "key.nameoffset" : 2019, + "key.offset" : 2007, + "key.overrides" : [ + { + "key.usr" : "s:10Commandant15OptionsProtocolP8evaluateys6ResultOyxAA0A5ErrorOy06ClientF0QzGGAA11CommandModeOFZ" + } + ], + "key.parsed_declaration" : "public static func evaluate(_ m: CommandMode) -> Result>", + "key.parsed_scope.end" : 75, + "key.parsed_scope.start" : 72, + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : " (HelpOptions.Type) -> (CommandMode) -> Result, CommandantError>", + "key.typeusr" : "$sys6ResultOy10Commandant11HelpOptionsVyxGAC0B5ErrorOyxGGAC11CommandModeOcD", + "key.usr" : "s:10Commandant15OptionsProtocolP8evaluateys6ResultOyxAA0A5ErrorOy06ClientF0QzGGAA11CommandModeOFZ" + } + ], + "key.typename" : "HelpOptions.Type", + "key.typeusr" : "$s10Commandant11HelpOptionsVyxGmD", + "key.usr" : "s:10Commandant11HelpOptionsV" + } + ] + } +}, { + "\/Sources\/Commandant\/Option.swift" : { + "key.diagnostic_stage" : "source.diagnostic.stage.swift.parse", + "key.length" : 9661, + "key.offset" : 0, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public protocol OptionsProtocol<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 1388 + } + ], + "key.bodylength" : 233, + "key.bodyoffset" : 1421, + "key.column" : 17, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Represents a record of options for a command, which can be parsed from\na list of command-line arguments.\n\nThis is most helpful when used in conjunction with the `Option` and `Switch`\ntypes, and `<*>` and `<|` combinators.\n\nExample:\n\n\tstruct LogOptions: OptionsProtocol {\n\t\tlet verbosity: Int\n\t\tlet outputFilename: String\n\t\tlet shouldDelete: Bool\n\t\tlet logName: String\n\n\t\tstatic func create(_ verbosity: Int) -> (String) -> (Bool) -> (String) -> LogOptions {\n\t\t\treturn { outputFilename in { shouldDelete in { logName in LogOptions(verbosity: verbosity, outputFilename: outputFilename, shouldDelete: shouldDelete, logName: logName) } } }\n\t\t}\n\n\t\tstatic func evaluate(_ m: CommandMode) -> Result> {\n\t\t\treturn create\n\t\t\t\t<*> m <| Option(key: \"verbose\", defaultValue: 0, usage: \"the verbosity level with which to read the logs\")\n\t\t\t\t<*> m <| Option(key: \"outputFilename\", defaultValue: \"\", usage: \"a file to print output to, instead of stdout\")\n\t\t\t\t<*> m <| Switch(flag: \"d\", key: \"delete\", usage: \"delete the logs when finished\")\n\t\t\t\t<*> m <| Argument(usage: \"the log to read\")\n\t\t}\n\t}", + "key.doc.column" : 17, + "key.doc.comment" : "Represents a record of options for a command, which can be parsed from\na list of command-line arguments.\n\nThis is most helpful when used in conjunction with the `Option` and `Switch`\ntypes, and `<*>` and `<|` combinators.\n\nExample:\n\n\tstruct LogOptions: OptionsProtocol {\n\t\tlet verbosity: Int\n\t\tlet outputFilename: String\n\t\tlet shouldDelete: Bool\n\t\tlet logName: String\n\n\t\tstatic func create(_ verbosity: Int) -> (String) -> (Bool) -> (String) -> LogOptions {\n\t\t\treturn { outputFilename in { shouldDelete in { logName in LogOptions(verbosity: verbosity, outputFilename: outputFilename, shouldDelete: shouldDelete, logName: logName) } } }\n\t\t}\n\n\t\tstatic func evaluate(_ m: CommandMode) -> Result> {\n\t\t\treturn create\n\t\t\t\t<*> m <| Option(key: \"verbose\", defaultValue: 0, usage: \"the verbosity level with which to read the logs\")\n\t\t\t\t<*> m <| Option(key: \"outputFilename\", defaultValue: \"\", usage: \"a file to print output to, instead of stdout\")\n\t\t\t\t<*> m <| Switch(flag: \"d\", key: \"delete\", usage: \"delete the logs when finished\")\n\t\t\t\t<*> m <| Argument(usage: \"the log to read\")\n\t\t}\n\t}", + "key.doc.declaration" : "public protocol OptionsProtocol", + "key.doc.discussion" : [ + { + "Para" : "This is most helpful when used in conjunction with the `Option` and `Switch` types, and `<*>` and `<|` combinators." + }, + { + "Para" : "Example:" + }, + { + "CodeListing" : "" + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Option.swift", + "key.doc.full_as_xml" : "OptionsProtocol<\/Name>s:10Commandant15OptionsProtocolP<\/USR>public protocol OptionsProtocol<\/Declaration>Represents a record of options for a command, which can be parsed from a list of command-line arguments.<\/Para><\/Abstract>This is most helpful when used in conjunction with the Option<\/codeVoice> and Switch<\/codeVoice> types, and <*><\/codeVoice> and <|<\/codeVoice> combinators.<\/Para>Example:<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered> (String) -> (Bool) -> (String) -> LogOptions {]]><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered> Result> {]]><\/zCodeLineNumbered><\/zCodeLineNumbered> m <| Option(key: \"verbose\", defaultValue: 0, usage: \"the verbosity level with which to read the logs\")]]><\/zCodeLineNumbered> m <| Option(key: \"outputFilename\", defaultValue: \"\", usage: \"a file to print output to, instead of stdout\")]]><\/zCodeLineNumbered> m <| Switch(flag: \"d\", key: \"delete\", usage: \"delete the logs when finished\")]]><\/zCodeLineNumbered> m <| Argument(usage: \"the log to read\")]]><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing><\/Discussion><\/CommentParts><\/Class>", + "key.doc.line" : 37, + "key.doc.name" : "OptionsProtocol", + "key.doc.type" : "Class", + "key.doclength" : 1222, + "key.docoffset" : 166, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> protocol<\/syntaxtype.keyword> OptionsProtocol<\/decl.name><\/decl.protocol>", + "key.kind" : "source.lang.swift.decl.protocol", + "key.length" : 260, + "key.line" : 37, + "key.modulename" : "Commandant", + "key.name" : "OptionsProtocol", + "key.namelength" : 15, + "key.nameoffset" : 1404, + "key.offset" : 1395, + "key.parsed_declaration" : "public protocol OptionsProtocol", + "key.parsed_scope.end" : 44, + "key.parsed_scope.start" : 37, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "associatedtype ClientError : Error<\/Type><\/Declaration>", + "key.column" : 17, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "associatedtype<\/syntaxtype.keyword> ClientError<\/decl.name> : Error<\/ref.protocol><\/decl.associatedtype>", + "key.is_dynamic" : true, + "key.kind" : "source.lang.swift.decl.associatedtype", + "key.length" : 33, + "key.line" : 38, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 1438, + "key.offset" : 1423, + "key.parsed_declaration" : "associatedtype ClientError: Error", + "key.parsed_scope.end" : 38, + "key.parsed_scope.start" : 38, + "key.receivers" : [ + { + "key.usr" : "s:10Commandant15OptionsProtocolP" + } + ], + "key.reusingastcontext" : false, + "key.typename" : "Self.ClientError.Type", + "key.typeusr" : "$s11ClientErrorQzmD", + "key.usr" : "s:10Commandant15OptionsProtocolP11ClientErrorQa" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "static func evaluate(_ m: CommandMode<\/Type>) -> Result<\/Type><Self<\/Type>, CommandantError<\/Type><ClientError<\/Type>>><\/Declaration>", + "key.column" : 14, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Evaluates this set of options in the given mode.\n\nReturns the parsed options or a `UsageError`.", + "key.doc.column" : 14, + "key.doc.comment" : "Evaluates this set of options in the given mode.\n\nReturns the parsed options or a `UsageError`.", + "key.doc.declaration" : "static func evaluate(_ m: CommandMode) -> Result>", + "key.doc.discussion" : [ + { + "Para" : "Returns the parsed options or a `UsageError`." + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Option.swift", + "key.doc.full_as_xml" : "evaluate(_:)<\/Name>s:10Commandant15OptionsProtocolP8evaluateys6ResultOyxAA0A5ErrorOy06ClientF0QzGGAA11CommandModeOFZ<\/USR>static func evaluate(_ m: CommandMode) -> Result<Self, CommandantError<ClientError>><\/Declaration>Evaluates this set of options in the given mode.<\/Para><\/Abstract>Returns the parsed options or a UsageError<\/codeVoice>.<\/Para><\/Discussion><\/CommentParts><\/Function>", + "key.doc.line" : 43, + "key.doc.name" : "evaluate(_:)", + "key.doc.type" : "Function", + "key.doclength" : 109, + "key.docoffset" : 1459, + "key.filepath" : "", + "key.fully_annotated_decl" : "static<\/syntaxtype.keyword> func<\/syntaxtype.keyword> evaluate<\/decl.name>(_<\/decl.var.parameter.argument_label> m<\/decl.var.parameter.name>: CommandMode<\/ref.enum><\/decl.var.parameter.type><\/decl.var.parameter>) -> Result<\/ref.enum><Self<\/ref.generic_type_param>, CommandantError<\/ref.enum><ClientError<\/ref.associatedtype>>><\/decl.function.returntype><\/decl.function.method.static>", + "key.is_dynamic" : true, + "key.kind" : "source.lang.swift.decl.function.method.static", + "key.length" : 84, + "key.line" : 43, + "key.modulename" : "Commandant", + "key.name" : "evaluate(_:)", + "key.namelength" : 26, + "key.nameoffset" : 1581, + "key.offset" : 1569, + "key.parsed_declaration" : "static func evaluate(_ m: CommandMode) -> Result>", + "key.parsed_scope.end" : 43, + "key.parsed_scope.start" : 43, + "key.receivers" : [ + { + "key.usr" : "s:10Commandant15OptionsProtocolP" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : " (Self.Type) -> (CommandMode) -> Result>", + "key.typeusr" : "$sys6ResultOyx10Commandant0B5ErrorOy06ClientC0QzGGAC11CommandModeOcD", + "key.usr" : "s:10Commandant15OptionsProtocolP8evaluateys6ResultOyxAA0A5ErrorOy06ClientF0QzGGAA11CommandModeOFZ" + } + ], + "key.typename" : "OptionsProtocol.Type", + "key.typeusr" : "$s10Commandant15OptionsProtocol_pmD", + "key.usr" : "s:10Commandant15OptionsProtocolP" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public struct NoOptions<ClientError> : OptionsProtocol<\/Type> where ClientError<\/Type> : Error<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 1703 + } + ], + "key.bodylength" : 154, + "key.bodyoffset" : 1765, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "An `OptionsProtocol` that has no options.", + "key.doc.column" : 15, + "key.doc.comment" : "An `OptionsProtocol` that has no options.", + "key.doc.declaration" : "public struct NoOptions : OptionsProtocol where ClientError : Error", + "key.doc.file" : "\/private\/Sources\/Commandant\/Option.swift", + "key.doc.full_as_xml" : "NoOptions<\/Name>s:10Commandant9NoOptionsV<\/USR>public struct NoOptions<ClientError> : OptionsProtocol where ClientError : Error<\/Declaration>An OptionsProtocol<\/codeVoice> that has no options.<\/Para><\/Abstract><\/CommentParts><\/Class>", + "key.doc.line" : 47, + "key.doc.name" : "NoOptions", + "key.doc.type" : "Class", + "key.doclength" : 46, + "key.docoffset" : 1657, + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 15, + "key.offset" : 1748 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> struct<\/syntaxtype.keyword> NoOptions<\/decl.name><ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>> : OptionsProtocol<\/ref.protocol> where<\/syntaxtype.keyword> ClientError<\/ref.generic_type_param> : Error<\/ref.protocol><\/decl.generic_type_requirement><\/decl.struct>", + "key.inheritedtypes" : [ + { + "key.name" : "OptionsProtocol" + } + ], + "key.kind" : "source.lang.swift.decl.struct", + "key.length" : 210, + "key.line" : 47, + "key.modulename" : "Commandant", + "key.name" : "NoOptions", + "key.namelength" : 9, + "key.nameoffset" : 1717, + "key.offset" : 1710, + "key.parsed_declaration" : "public struct NoOptions: OptionsProtocol", + "key.parsed_scope.end" : 53, + "key.parsed_scope.start" : 47, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "ClientError : Error<\/Type><\/Declaration>", + "key.column" : 25, + "key.decl_lang" : "source.lang.swift", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 5, + "key.offset" : 1740 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name> : Error<\/ref.protocol><\/decl.generic_type_param.constraint><\/decl.generic_type_param>", + "key.inheritedtypes" : [ + { + "key.name" : "Error" + } + ], + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 18, + "key.line" : 47, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 1727, + "key.offset" : 1727, + "key.parsed_declaration" : "public struct NoOptionsClientError<\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.typename" : "ClientError.Type", + "key.typeusr" : "$sxmD", + "key.usr" : "s:10Commandant9NoOptionsV11ClientErrorxmfp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public init()<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 1767 + } + ], + "key.bodylength" : 0, + "key.bodyoffset" : 1782, + "key.column" : 9, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> init<\/syntaxtype.keyword>()<\/decl.function.constructor>", + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 9, + "key.line" : 48, + "key.modulename" : "Commandant", + "key.name" : "init()", + "key.namelength" : 6, + "key.nameoffset" : 1774, + "key.offset" : 1774, + "key.parsed_declaration" : "public init()", + "key.parsed_scope.end" : 48, + "key.parsed_scope.start" : 48, + "key.reusingastcontext" : false, + "key.typename" : " (NoOptions.Type) -> () -> NoOptions", + "key.typeusr" : "$s10Commandant9NoOptionsVyxGycD", + "key.usr" : "s:10Commandant9NoOptionsVACyxGycfc" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public static func evaluate(_ m: CommandMode<\/Type>) -> Result<\/Type><NoOptions<\/Type>, CommandantError<\/Type><ClientError<\/Type>>><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 1786 + } + ], + "key.bodylength" : 33, + "key.bodyoffset" : 1884, + "key.column" : 21, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Evaluates this set of options in the given mode.\n\nReturns the parsed options or a `UsageError`.", + "key.doc.column" : 14, + "key.doc.declaration" : "static func evaluate(_ m: CommandMode) -> Result>", + "key.doc.discussion" : [ + { + "Para" : "Returns the parsed options or a `UsageError`." + }, + { + "Note" : "" + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Option.swift", + "key.doc.full_as_xml" : "evaluate(_:)<\/Name>s:10Commandant15OptionsProtocolP8evaluateys6ResultOyxAA0A5ErrorOy06ClientF0QzGGAA11CommandModeOFZ<\/USR>static func evaluate(_ m: CommandMode) -> Result<Self, CommandantError<ClientError>><\/Declaration>Evaluates this set of options in the given mode.<\/Para><\/Abstract>Returns the parsed options or a UsageError<\/codeVoice>.<\/Para>This documentation comment was inherited from OptionsProtocol<\/codeVoice>.<\/Para><\/Note><\/Discussion><\/CommentParts><\/Function>", + "key.doc.line" : 43, + "key.doc.name" : "evaluate(_:)", + "key.doc.type" : "Function", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> static<\/syntaxtype.keyword> func<\/syntaxtype.keyword> evaluate<\/decl.name>(_<\/decl.var.parameter.argument_label> m<\/decl.var.parameter.name>: CommandMode<\/ref.enum><\/decl.var.parameter.type><\/decl.var.parameter>) -> Result<\/ref.enum><NoOptions<\/ref.struct>, CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>>><\/decl.function.returntype><\/decl.function.method.static>", + "key.kind" : "source.lang.swift.decl.function.method.static", + "key.length" : 125, + "key.line" : 50, + "key.modulename" : "Commandant", + "key.name" : "evaluate(_:)", + "key.namelength" : 26, + "key.nameoffset" : 1805, + "key.offset" : 1793, + "key.overrides" : [ + { + "key.usr" : "s:10Commandant15OptionsProtocolP8evaluateys6ResultOyxAA0A5ErrorOy06ClientF0QzGGAA11CommandModeOFZ" + } + ], + "key.parsed_declaration" : "public static func evaluate(_ m: CommandMode) -> Result>", + "key.parsed_scope.end" : 52, + "key.parsed_scope.start" : 50, + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : " (NoOptions.Type) -> (CommandMode) -> Result, CommandantError>", + "key.typeusr" : "$sys6ResultOy10Commandant9NoOptionsVyxGAC0B5ErrorOyxGGAC11CommandModeOcD", + "key.usr" : "s:10Commandant15OptionsProtocolP8evaluateys6ResultOyxAA0A5ErrorOy06ClientF0QzGGAA11CommandModeOFZ" + } + ], + "key.typename" : "NoOptions.Type", + "key.typeusr" : "$s10Commandant9NoOptionsVyxGmD", + "key.usr" : "s:10Commandant9NoOptionsV" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public struct Option<T><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 1988 + } + ], + "key.bodylength" : 786, + "key.bodyoffset" : 2013, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Describes an option that can be provided on the command line.", + "key.doc.column" : 15, + "key.doc.comment" : "Describes an option that can be provided on the command line.", + "key.doc.declaration" : "public struct Option", + "key.doc.file" : "\/private\/Sources\/Commandant\/Option.swift", + "key.doc.full_as_xml" : "Option<\/Name>s:10Commandant6OptionV<\/USR>public struct Option<T><\/Declaration>Describes an option that can be provided on the command line.<\/Para><\/Abstract><\/CommentParts><\/Class>", + "key.doc.line" : 56, + "key.doc.name" : "Option", + "key.doc.type" : "Class", + "key.doclength" : 66, + "key.docoffset" : 1922, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> struct<\/syntaxtype.keyword> Option<\/decl.name><T<\/decl.generic_type_param.name><\/decl.generic_type_param>><\/decl.struct>", + "key.kind" : "source.lang.swift.decl.struct", + "key.length" : 805, + "key.line" : 56, + "key.modulename" : "Commandant", + "key.name" : "Option", + "key.namelength" : 6, + "key.nameoffset" : 2002, + "key.offset" : 1995, + "key.parsed_declaration" : "public struct Option", + "key.parsed_scope.end" : 78, + "key.parsed_scope.start" : 56, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "T<\/Declaration>", + "key.column" : 22, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "T<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 1, + "key.line" : 56, + "key.modulename" : "Commandant", + "key.name" : "T", + "key.namelength" : 1, + "key.nameoffset" : 2009, + "key.offset" : 2009, + "key.parsed_declaration" : "public struct Optionpublic let key: String<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 2132 + } + ], + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "The key that controls this option. For example, a key of `verbose` would\nbe used for a `--verbose` option.", + "key.doc.column" : 13, + "key.doc.comment" : "The key that controls this option. For example, a key of `verbose` would\nbe used for a `--verbose` option.", + "key.doc.declaration" : "public let key: String", + "key.doc.file" : "\/private\/Sources\/Commandant\/Option.swift", + "key.doc.full_as_xml" : "key<\/Name>s:10Commandant6OptionV3keySSvp<\/USR>public let key: String<\/Declaration>The key that controls this option. For example, a key of verbose<\/codeVoice> would be used for a --verbose<\/codeVoice> option.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 59, + "key.doc.name" : "key", + "key.doc.type" : "Other", + "key.doclength" : 116, + "key.docoffset" : 2015, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> let<\/syntaxtype.keyword> key<\/decl.name>: String<\/ref.struct><\/decl.var.type><\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 15, + "key.line" : 59, + "key.modulename" : "Commandant", + "key.name" : "key", + "key.namelength" : 3, + "key.nameoffset" : 2143, + "key.offset" : 2139, + "key.parsed_declaration" : "public let key: String", + "key.parsed_scope.end" : 59, + "key.parsed_scope.start" : 59, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant6OptionV3keySSvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public let defaultValue: T<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 2303 + } + ], + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "The default value for this option. This is the value that will be used\nif the option is never explicitly specified on the command line.", + "key.doc.column" : 13, + "key.doc.comment" : "The default value for this option. This is the value that will be used\nif the option is never explicitly specified on the command line.", + "key.doc.declaration" : "public let defaultValue: T", + "key.doc.file" : "\/private\/Sources\/Commandant\/Option.swift", + "key.doc.full_as_xml" : "defaultValue<\/Name>s:10Commandant6OptionV12defaultValuexvp<\/USR>public let defaultValue: T<\/Declaration>The default value for this option. This is the value that will be used if the option is never explicitly specified on the command line.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 63, + "key.doc.name" : "defaultValue", + "key.doc.type" : "Other", + "key.doclength" : 145, + "key.docoffset" : 2157, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> let<\/syntaxtype.keyword> defaultValue<\/decl.name>: T<\/ref.generic_type_param><\/decl.var.type><\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 19, + "key.line" : 63, + "key.modulename" : "Commandant", + "key.name" : "defaultValue", + "key.namelength" : 12, + "key.nameoffset" : 2314, + "key.offset" : 2310, + "key.parsed_declaration" : "public let defaultValue: T", + "key.parsed_scope.end" : 63, + "key.parsed_scope.start" : 63, + "key.reusingastcontext" : false, + "key.typename" : "T", + "key.typeusr" : "$sxD", + "key.usr" : "s:10Commandant6OptionV12defaultValuexvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public let usage: String<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 2637 + } + ], + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A human-readable string describing the purpose of this option. This will\nbe shown in help messages.\n\nFor boolean operations, this should describe the effect of _not_ using\nthe default value (i.e., what will happen if you disable\/enable the flag\ndifferently from the default).", + "key.doc.column" : 13, + "key.doc.comment" : "A human-readable string describing the purpose of this option. This will\nbe shown in help messages.\n\nFor boolean operations, this should describe the effect of _not_ using\nthe default value (i.e., what will happen if you disable\/enable the flag\ndifferently from the default).", + "key.doc.declaration" : "public let usage: String", + "key.doc.discussion" : [ + { + "Para" : "For boolean operations, this should describe the effect of using the default value (i.e., what will happen if you disable\/enable the flag differently from the default)." + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Option.swift", + "key.doc.full_as_xml" : "usage<\/Name>s:10Commandant6OptionV5usageSSvp<\/USR>public let usage: String<\/Declaration>A human-readable string describing the purpose of this option. This will be shown in help messages.<\/Para><\/Abstract>For boolean operations, this should describe the effect of not<\/emphasis> using the default value (i.e., what will happen if you disable\/enable the flag differently from the default).<\/Para><\/Discussion><\/CommentParts><\/Other>", + "key.doc.line" : 71, + "key.doc.name" : "usage", + "key.doc.type" : "Other", + "key.doclength" : 304, + "key.docoffset" : 2332, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> let<\/syntaxtype.keyword> usage<\/decl.name>: String<\/ref.struct><\/decl.var.type><\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 17, + "key.line" : 71, + "key.modulename" : "Commandant", + "key.name" : "usage", + "key.namelength" : 5, + "key.nameoffset" : 2648, + "key.offset" : 2644, + "key.parsed_declaration" : "public let usage: String", + "key.parsed_scope.end" : 71, + "key.parsed_scope.start" : 71, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant6OptionV5usageSSvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public init(key: String<\/Type>, defaultValue: T<\/Type>, usage: String<\/Type>)<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 2664 + } + ], + "key.bodylength" : 75, + "key.bodyoffset" : 2722, + "key.column" : 9, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> init<\/syntaxtype.keyword>(key<\/decl.var.parameter.argument_label>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>, defaultValue<\/decl.var.parameter.argument_label>: T<\/ref.generic_type_param><\/decl.var.parameter.type><\/decl.var.parameter>, usage<\/decl.var.parameter.argument_label>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>)<\/decl.function.constructor>", + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 127, + "key.line" : 73, + "key.modulename" : "Commandant", + "key.name" : "init(key:defaultValue:usage:)", + "key.namelength" : 49, + "key.nameoffset" : 2671, + "key.offset" : 2671, + "key.parsed_declaration" : "public init(key: String, defaultValue: T, usage: String)", + "key.parsed_scope.end" : 77, + "key.parsed_scope.start" : 73, + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : " (Option.Type) -> (String, T, String) -> Option", + "key.typeusr" : "$s3key12defaultValue5usage10Commandant6OptionVyxGSS_xSStcD", + "key.usr" : "s:10Commandant6OptionV3key12defaultValue5usageACyxGSS_xSStcfc" + } + ], + "key.typename" : "Option.Type", + "key.typeusr" : "$s10Commandant6OptionVyxGmD", + "key.usr" : "s:10Commandant6OptionV" + }, + { + "key.annotated_decl" : "public struct Option<T><\/Declaration>", + "key.bodylength" : 58, + "key.bodyoffset" : 2845, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Describes an option that can be provided on the command line.", + "key.doc.column" : 15, + "key.doc.declaration" : "public struct Option", + "key.doc.file" : "\/private\/Sources\/Commandant\/Option.swift", + "key.doc.full_as_xml" : "Option<\/Name>s:10Commandant6OptionV<\/USR>public struct Option<T><\/Declaration>Describes an option that can be provided on the command line.<\/Para><\/Abstract><\/CommentParts><\/Class>", + "key.doc.line" : 56, + "key.doc.name" : "Option", + "key.doc.type" : "Class", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 23, + "key.offset" : 2820 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> struct<\/syntaxtype.keyword> Option<\/decl.name><T<\/decl.generic_type_param.name><\/decl.generic_type_param>><\/decl.struct>", + "key.inheritedtypes" : [ + { + "key.name" : "CustomStringConvertible" + } + ], + "key.kind" : "source.lang.swift.decl.extension", + "key.length" : 102, + "key.line" : 56, + "key.modulename" : "Commandant", + "key.name" : "Option", + "key.namelength" : 6, + "key.nameoffset" : 2812, + "key.offset" : 2802, + "key.parsed_declaration" : "extension Option: CustomStringConvertible", + "key.parsed_scope.end" : 84, + "key.parsed_scope.start" : 80, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public var description: String<\/Type> { get }<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 2847 + } + ], + "key.bodylength" : 22, + "key.bodyoffset" : 2879, + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A textual representation of this instance.\n\nCalling this property directly is discouraged. Instead, convert an\ninstance of any type to a string by using the `String(describing:)`\ninitializer. This initializer works with any type, and uses the custom\n`description` property for types that conform to\n`CustomStringConvertible`:\n\n struct Point: CustomStringConvertible {\n let x: Int, y: Int\n\n var description: String {\n return \"(\\(x), \\(y))\"\n }\n }\n\n let p = Point(x: 21, y: 30)\n let s = String(describing: p)\n print(s)\n \/\/ Prints \"(21, 30)\"\n\nThe conversion of `p` to a string in the assignment to `s` uses the\n`Point` type's `description` property.", + "key.doc.declaration" : "var description: String { get }", + "key.doc.discussion" : [ + { + "Para" : "Calling this property directly is discouraged. Instead, convert an instance of any type to a string by using the `String(describing:)` initializer. This initializer works with any type, and uses the custom `description` property for types that conform to `CustomStringConvertible`:" + }, + { + "CodeListing" : "" + }, + { + "Para" : "The conversion of `p` to a string in the assignment to `s` uses the `Point` type’s `description` property." + }, + { + "Note" : "" + } + ], + "key.doc.full_as_xml" : "description<\/Name>s:s23CustomStringConvertibleP11descriptionSSvp<\/USR>var description: String { get }<\/Declaration>A textual representation of this instance.<\/Para><\/Abstract>Calling this property directly is discouraged. Instead, convert an instance of any type to a string by using the String(describing:)<\/codeVoice> initializer. This initializer works with any type, and uses the custom description<\/codeVoice> property for types that conform to CustomStringConvertible<\/codeVoice>:<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>The conversion of p<\/codeVoice> to a string in the assignment to s<\/codeVoice> uses the Point<\/codeVoice> type’s description<\/codeVoice> property.<\/Para>This documentation comment was inherited from CustomStringConvertible<\/codeVoice>.<\/Para><\/Note><\/Discussion><\/CommentParts><\/Other>", + "key.doc.name" : "description", + "key.doc.type" : "Other", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> var<\/syntaxtype.keyword> description<\/decl.name>: String<\/ref.struct><\/decl.var.type> { get<\/syntaxtype.keyword> }<\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 48, + "key.line" : 81, + "key.modulename" : "Commandant", + "key.name" : "description", + "key.namelength" : 11, + "key.nameoffset" : 2858, + "key.offset" : 2854, + "key.overrides" : [ + { + "key.usr" : "s:s23CustomStringConvertibleP11descriptionSSvp" + } + ], + "key.parsed_declaration" : "public var description: String", + "key.parsed_scope.end" : 83, + "key.parsed_scope.start" : 81, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:s23CustomStringConvertibleP11descriptionSSvp" + } + ], + "key.typename" : "Option.Type", + "key.typeusr" : "$s10Commandant6OptionVyxGmD", + "key.usr" : "s:10Commandant6OptionV" + }, + { + "key.kind" : "source.lang.swift.syntaxtype.comment.mark", + "key.length" : 17, + "key.name" : "MARK: - Operators", + "key.offset" : 2909 + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public func <*> <T, U, ClientError>(f: (T<\/Type>) -> U<\/Type>, value: Result<\/Type><T<\/Type>, CommandantError<\/Type><ClientError<\/Type>>>) -> Result<\/Type><U<\/Type>, CommandantError<\/Type><ClientError<\/Type>>><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 4404 + } + ], + "key.bodylength" : 22, + "key.bodyoffset" : 4545, + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Applies `f` to the value in the given result.\n\nIn the context of command-line option parsing, this is used to chain\ntogether the parsing of multiple arguments. See OptionsProtocol for an example.", + "key.doc.column" : 13, + "key.doc.comment" : "Applies `f` to the value in the given result.\n\nIn the context of command-line option parsing, this is used to chain\ntogether the parsing of multiple arguments. See OptionsProtocol for an example.", + "key.doc.declaration" : "public func <*> (f: (T) -> U, value: Result>) -> Result>", + "key.doc.discussion" : [ + { + "Para" : "In the context of command-line option parsing, this is used to chain together the parsing of multiple arguments. See OptionsProtocol for an example." + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Option.swift", + "key.doc.full_as_xml" : "<*>(_:_:)<\/Name>s:10Commandant3lmgoiys6ResultOyq_AA0A5ErrorOyq0_GGq_xXE_ADyxAGGtr1_lF<\/USR>public func <*> <T, U, ClientError>(f: (T) -> U, value: Result<T, CommandantError<ClientError>>) -> Result<U, CommandantError<ClientError>><\/Declaration>Applies f<\/codeVoice> to the value in the given result.<\/Para><\/Abstract>In the context of command-line option parsing, this is used to chain together the parsing of multiple arguments. See OptionsProtocol for an example.<\/Para><\/Discussion><\/CommentParts><\/Function>", + "key.doc.line" : 122, + "key.doc.name" : "<*>(_:_:)", + "key.doc.type" : "Function", + "key.doclength" : 211, + "key.docoffset" : 4193, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> func<\/syntaxtype.keyword> <*> <\/decl.name><T<\/decl.generic_type_param.name><\/decl.generic_type_param>, U<\/decl.generic_type_param.name><\/decl.generic_type_param>, ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>>(f<\/decl.var.parameter.name>: (T<\/ref.generic_type_param><\/decl.var.parameter.type><\/decl.var.parameter>) -> U<\/ref.generic_type_param><\/decl.function.returntype><\/decl.var.parameter.type><\/decl.var.parameter>, value<\/decl.var.parameter.name>: Result<\/ref.enum><T<\/ref.generic_type_param>, CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>>><\/decl.var.parameter.type><\/decl.var.parameter>) -> Result<\/ref.enum><U<\/ref.generic_type_param>, CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>>><\/decl.function.returntype><\/decl.function.operator.infix>", + "key.kind" : "source.lang.swift.decl.function.free", + "key.length" : 157, + "key.line" : 122, + "key.modulename" : "Commandant", + "key.name" : "<*>(_:_:)", + "key.namelength" : 84, + "key.nameoffset" : 4416, + "key.offset" : 4411, + "key.parsed_declaration" : "public func <*> (f: (T) -> U, value: Result>) -> Result>", + "key.parsed_scope.end" : 124, + "key.parsed_scope.start" : 122, + "key.related_decls" : [ + { + "key.annotated_decl" : "<*> <T, U, ClientError>(_: Result<((T) -> U), CommandantError<ClientError>>, _: Result<T, CommandantError<ClientError>>) -> Result<U, CommandantError<ClientError>><\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "T<\/Declaration>", + "key.column" : 18, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "T<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 1, + "key.line" : 122, + "key.modulename" : "Commandant", + "key.name" : "T", + "key.namelength" : 1, + "key.nameoffset" : 4421, + "key.offset" : 4421, + "key.parsed_declaration" : "public func <*> U<\/Declaration>", + "key.column" : 21, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "U<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 1, + "key.line" : 122, + "key.modulename" : "Commandant", + "key.name" : "U", + "key.namelength" : 1, + "key.nameoffset" : 4424, + "key.offset" : 4424, + "key.parsed_declaration" : "public func <*> ClientError<\/Declaration>", + "key.column" : 24, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 122, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 4427, + "key.offset" : 4427, + "key.parsed_declaration" : "public func <*> ((T) -> U, Result>) -> Result>", + "key.typeusr" : "$sys6ResultOyq_10Commandant0B5ErrorOyq0_GGq_xXE_AByxAFGtcr1_luD", + "key.usr" : "s:10Commandant3lmgoiys6ResultOyq_AA0A5ErrorOyq0_GGq_xXE_ADyxAGGtr1_lF" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public func <*> <T, U, ClientError>(f: Result<\/Type><((T<\/Type>) -> U<\/Type>), CommandantError<\/Type><ClientError<\/Type>>>, value: Result<\/Type><T<\/Type>, CommandantError<\/Type><ClientError<\/Type>>>) -> Result<\/Type><U<\/Type>, CommandantError<\/Type><ClientError<\/Type>>><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 4797 + } + ], + "key.bodylength" : 346, + "key.bodyoffset" : 4978, + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Applies the function in `f` to the value in the given result.\n\nIn the context of command-line option parsing, this is used to chain\ntogether the parsing of multiple arguments. See OptionsProtocol for an example.", + "key.doc.column" : 13, + "key.doc.comment" : "Applies the function in `f` to the value in the given result.\n\nIn the context of command-line option parsing, this is used to chain\ntogether the parsing of multiple arguments. See OptionsProtocol for an example.", + "key.doc.declaration" : "public func <*> (f: Result<((T) -> U), CommandantError>, value: Result>) -> Result>", + "key.doc.discussion" : [ + { + "Para" : "In the context of command-line option parsing, this is used to chain together the parsing of multiple arguments. See OptionsProtocol for an example." + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Option.swift", + "key.doc.full_as_xml" : "<*>(_:_:)<\/Name>s:10Commandant3lmgoiys6ResultOyq_AA0A5ErrorOyq0_GGADyq_xcAGG_ADyxAGGtr1_lF<\/USR>public func <*> <T, U, ClientError>(f: Result<((T) -> U), CommandantError<ClientError>>, value: Result<T, CommandantError<ClientError>>) -> Result<U, CommandantError<ClientError>><\/Declaration>Applies the function in f<\/codeVoice> to the value in the given result.<\/Para><\/Abstract>In the context of command-line option parsing, this is used to chain together the parsing of multiple arguments. See OptionsProtocol for an example.<\/Para><\/Discussion><\/CommentParts><\/Function>", + "key.doc.line" : 130, + "key.doc.name" : "<*>(_:_:)", + "key.doc.type" : "Function", + "key.doclength" : 227, + "key.docoffset" : 4570, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> func<\/syntaxtype.keyword> <*> <\/decl.name><T<\/decl.generic_type_param.name><\/decl.generic_type_param>, U<\/decl.generic_type_param.name><\/decl.generic_type_param>, ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>>(f<\/decl.var.parameter.name>: Result<\/ref.enum><((T<\/ref.generic_type_param><\/decl.var.parameter.type><\/decl.var.parameter>) -> U<\/ref.generic_type_param><\/decl.function.returntype><\/tuple.element.type><\/tuple.element>)<\/tuple>, CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>>><\/decl.var.parameter.type><\/decl.var.parameter>, value<\/decl.var.parameter.name>: Result<\/ref.enum><T<\/ref.generic_type_param>, CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>>><\/decl.var.parameter.type><\/decl.var.parameter>) -> Result<\/ref.enum><U<\/ref.generic_type_param>, CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>>><\/decl.function.returntype><\/decl.function.operator.infix>", + "key.kind" : "source.lang.swift.decl.function.free", + "key.length" : 521, + "key.line" : 130, + "key.modulename" : "Commandant", + "key.name" : "<*>(_:_:)", + "key.namelength" : 124, + "key.nameoffset" : 4809, + "key.offset" : 4804, + "key.parsed_declaration" : "public func <*> (f: Result<((T) -> U), CommandantError>, value: Result>) -> Result>", + "key.parsed_scope.end" : 145, + "key.parsed_scope.start" : 130, + "key.related_decls" : [ + { + "key.annotated_decl" : "<*> <T, U, ClientError>(_: (T) -> U, _: Result<T, CommandantError<ClientError>>) -> Result<U, CommandantError<ClientError>><\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "T<\/Declaration>", + "key.column" : 18, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "T<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 1, + "key.line" : 130, + "key.modulename" : "Commandant", + "key.name" : "T", + "key.namelength" : 1, + "key.nameoffset" : 4814, + "key.offset" : 4814, + "key.parsed_declaration" : "public func <*> U<\/Declaration>", + "key.column" : 21, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "U<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 1, + "key.line" : 130, + "key.modulename" : "Commandant", + "key.name" : "U", + "key.namelength" : 1, + "key.nameoffset" : 4817, + "key.offset" : 4817, + "key.parsed_declaration" : "public func <*> ClientError<\/Declaration>", + "key.column" : 24, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 130, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 4820, + "key.offset" : 4820, + "key.parsed_declaration" : "public func <*> (Result<((T) -> U), CommandantError>, Result>) -> Result>", + "key.typeusr" : "$sys6ResultOyq_10Commandant0B5ErrorOyq0_GGAByq_xcAFG_AByxAFGtcr1_luD", + "key.usr" : "s:10Commandant3lmgoiys6ResultOyq_AA0A5ErrorOyq0_GGADyq_xcAGG_ADyxAGGtr1_lF" + }, + { + "key.annotated_decl" : "public enum CommandMode<\/Declaration>", + "key.bodylength" : 4309, + "key.bodyoffset" : 5350, + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Describes the \"mode\" in which a command should run.", + "key.doc.column" : 13, + "key.doc.declaration" : "public enum CommandMode", + "key.doc.file" : "\/private\/Sources\/Commandant\/Command.swift", + "key.doc.full_as_xml" : "CommandMode<\/Name>s:10Commandant11CommandModeO<\/USR>public enum CommandMode<\/Declaration>Describes the “mode” in which a command should run.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 68, + "key.doc.name" : "CommandMode", + "key.doc.type" : "Other", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> enum<\/syntaxtype.keyword> CommandMode<\/decl.name><\/decl.enum>", + "key.kind" : "source.lang.swift.decl.extension", + "key.length" : 4333, + "key.line" : 68, + "key.modulename" : "Commandant", + "key.name" : "CommandMode", + "key.namelength" : 11, + "key.nameoffset" : 5337, + "key.offset" : 5327, + "key.parsed_declaration" : "extension CommandMode", + "key.parsed_scope.end" : 273, + "key.parsed_scope.start" : 147, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public static func <| <T, ClientError>(mode: CommandMode<\/Type>, option: Option<\/Type><T<\/Type>>) -> Result<\/Type><T<\/Type>, CommandantError<\/Type><ClientError<\/Type>>> where T<\/Type> : ArgumentProtocol<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 5538 + } + ], + "key.bodylength" : 230, + "key.bodyoffset" : 5677, + "key.column" : 21, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Evaluates the given option in the given mode.\n\nIf parsing command line arguments, and no value was specified on the command\nline, the option's `defaultValue` is used.", + "key.doc.column" : 21, + "key.doc.comment" : "Evaluates the given option in the given mode.\n\nIf parsing command line arguments, and no value was specified on the command\nline, the option's `defaultValue` is used.", + "key.doc.declaration" : "public static func <| (mode: CommandMode, option: Option) -> Result> where T : Commandant.ArgumentProtocol", + "key.doc.discussion" : [ + { + "Para" : "If parsing command line arguments, and no value was specified on the command line, the option’s `defaultValue` is used." + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Option.swift", + "key.doc.full_as_xml" : "<|(_:_:)<\/Name>s:10Commandant11CommandModeO2looiys6ResultOyxAA0A5ErrorOyq_GGAC_AA6OptionVyxGtAA16ArgumentProtocolRzr0_lFZ<\/USR>public static func <| <T, ClientError>(mode: CommandMode, option: Option<T>) -> Result<T, CommandantError<ClientError>> where T : Commandant.ArgumentProtocol<\/Declaration>Evaluates the given option in the given mode.<\/Para><\/Abstract>If parsing command line arguments, and no value was specified on the command line, the option’s defaultValue<\/codeVoice> is used.<\/Para><\/Discussion><\/CommentParts><\/Function>", + "key.doc.line" : 152, + "key.doc.name" : "<|(_:_:)", + "key.doc.type" : "Function", + "key.doclength" : 185, + "key.docoffset" : 5352, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> static<\/syntaxtype.keyword> func<\/syntaxtype.keyword> <| <\/decl.name><T<\/decl.generic_type_param.name><\/decl.generic_type_param>, ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>>(mode<\/decl.var.parameter.name>: CommandMode<\/ref.enum><\/decl.var.parameter.type><\/decl.var.parameter>, option<\/decl.var.parameter.name>: Option<\/ref.struct><T<\/ref.generic_type_param>><\/decl.var.parameter.type><\/decl.var.parameter>) -> Result<\/ref.enum><T<\/ref.generic_type_param>, CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>>><\/decl.function.returntype> where<\/syntaxtype.keyword> T<\/ref.generic_type_param> : ArgumentProtocol<\/ref.protocol><\/decl.generic_type_requirement><\/decl.function.operator.infix>", + "key.kind" : "source.lang.swift.decl.function.method.static", + "key.length" : 363, + "key.line" : 152, + "key.modulename" : "Commandant", + "key.name" : "<|(_:_:)", + "key.namelength" : 75, + "key.nameoffset" : 5557, + "key.offset" : 5545, + "key.parsed_declaration" : "public static func <| (mode: CommandMode, option: Option) -> Result>", + "key.parsed_scope.end" : 157, + "key.parsed_scope.start" : 152, + "key.related_decls" : [ + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Argument<T>) -> Result<T, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Argument<[T]>) -> Result<[T], CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<T?>) -> Result<T?, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<[T]>) -> Result<[T], CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<[T]?>) -> Result<[T]?, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <ClientError>(_: CommandMode, _: Option<Bool>) -> Result<Bool, CommandantError<ClientError>><\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <ClientError>(_: CommandMode, _: Switch) -> Result<Bool, CommandantError<ClientError>><\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "T : ArgumentProtocol<\/Type><\/Declaration>", + "key.column" : 25, + "key.decl_lang" : "source.lang.swift", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 16, + "key.offset" : 5564 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "T<\/decl.generic_type_param.name> : ArgumentProtocol<\/ref.protocol><\/decl.generic_type_param.constraint><\/decl.generic_type_param>", + "key.inheritedtypes" : [ + { + "key.name" : "ArgumentProtocol" + } + ], + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 19, + "key.line" : 152, + "key.modulename" : "Commandant", + "key.name" : "T", + "key.namelength" : 1, + "key.nameoffset" : 5561, + "key.offset" : 5561, + "key.parsed_declaration" : "public static func <| ClientError<\/Declaration>", + "key.column" : 46, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 152, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 5582, + "key.offset" : 5582, + "key.parsed_declaration" : "public static func <| let wrapped: Option<\/Type><T<\/Type>?><\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "let<\/syntaxtype.keyword> wrapped<\/decl.name>: Option<\/ref.struct><T<\/ref.generic_type_param>?><\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 97, + "key.line" : 153, + "key.modulename" : "Commandant", + "key.name" : "wrapped", + "key.namelength" : 7, + "key.nameoffset" : 5684, + "key.offset" : 5680, + "key.parsed_declaration" : "let wrapped = Option(key: option.key, defaultValue: option.defaultValue, usage: option.usage)", + "key.parsed_scope.end" : 153, + "key.parsed_scope.start" : 153, + "key.reusingastcontext" : false, + "key.typename" : "Option", + "key.typeusr" : "$s10Commandant6OptionVyxSgGD", + "key.usr" : "s:10Commandant11CommandModeO2looiys6ResultOyxAA0A5ErrorOyq_GGAC_AA6OptionVyxGtAA16ArgumentProtocolRzr0_lFZ7wrappedL_ALyxSgGvp" + } + ], + "key.typename" : " (CommandMode.Type) -> (CommandMode, Option) -> Result>", + "key.typeusr" : "$sys6ResultOyx10Commandant0B5ErrorOyq_GGAC11CommandModeO_AC6OptionVyxGtcAC16ArgumentProtocolRzr0_luD", + "key.usr" : "s:10Commandant11CommandModeO2looiys6ResultOyxAA0A5ErrorOyq_GGAC_AA6OptionVyxGtAA16ArgumentProtocolRzr0_lFZ" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public static func <| <T, ClientError>(mode: CommandMode<\/Type>, option: Option<\/Type><T<\/Type>?>) -> Result<\/Type><T<\/Type>?, CommandantError<\/Type><ClientError<\/Type>>> where T<\/Type> : ArgumentProtocol<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 6075 + } + ], + "key.bodylength" : 852, + "key.bodyoffset" : 6216, + "key.column" : 21, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Evaluates the given option in the given mode.\n\nIf parsing command line arguments, and no value was specified on the command\nline, `nil` is used.", + "key.doc.column" : 21, + "key.doc.comment" : "Evaluates the given option in the given mode.\n\nIf parsing command line arguments, and no value was specified on the command\nline, `nil` is used.", + "key.doc.declaration" : "public static func <| (mode: CommandMode, option: Option) -> Result> where T : Commandant.ArgumentProtocol", + "key.doc.discussion" : [ + { + "Para" : "If parsing command line arguments, and no value was specified on the command line, `nil` is used." + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Option.swift", + "key.doc.full_as_xml" : "<|(_:_:)<\/Name>s:10Commandant11CommandModeO2looiys6ResultOyxSgAA0A5ErrorOyq_GGAC_AA6OptionVyAGGtAA16ArgumentProtocolRzr0_lFZ<\/USR>public static func <| <T, ClientError>(mode: CommandMode, option: Option<T?>) -> Result<T?, CommandantError<ClientError>> where T : Commandant.ArgumentProtocol<\/Declaration>Evaluates the given option in the given mode.<\/Para><\/Abstract>If parsing command line arguments, and no value was specified on the command line, nil<\/codeVoice> is used.<\/Para><\/Discussion><\/CommentParts><\/Function>", + "key.doc.line" : 163, + "key.doc.name" : "<|(_:_:)", + "key.doc.type" : "Function", + "key.doclength" : 163, + "key.docoffset" : 5911, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> static<\/syntaxtype.keyword> func<\/syntaxtype.keyword> <| <\/decl.name><T<\/decl.generic_type_param.name><\/decl.generic_type_param>, ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>>(mode<\/decl.var.parameter.name>: CommandMode<\/ref.enum><\/decl.var.parameter.type><\/decl.var.parameter>, option<\/decl.var.parameter.name>: Option<\/ref.struct><T<\/ref.generic_type_param>?><\/decl.var.parameter.type><\/decl.var.parameter>) -> Result<\/ref.enum><T<\/ref.generic_type_param>?, CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>>><\/decl.function.returntype> where<\/syntaxtype.keyword> T<\/ref.generic_type_param> : ArgumentProtocol<\/ref.protocol><\/decl.generic_type_requirement><\/decl.function.operator.infix>", + "key.kind" : "source.lang.swift.decl.function.method.static", + "key.length" : 987, + "key.line" : 163, + "key.modulename" : "Commandant", + "key.name" : "<|(_:_:)", + "key.namelength" : 76, + "key.nameoffset" : 6094, + "key.offset" : 6082, + "key.parsed_declaration" : "public static func <| (mode: CommandMode, option: Option) -> Result>", + "key.parsed_scope.end" : 196, + "key.parsed_scope.start" : 163, + "key.related_decls" : [ + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Argument<T>) -> Result<T, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Argument<[T]>) -> Result<[T], CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<T>) -> Result<T, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<[T]>) -> Result<[T], CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<[T]?>) -> Result<[T]?, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <ClientError>(_: CommandMode, _: Option<Bool>) -> Result<Bool, CommandantError<ClientError>><\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <ClientError>(_: CommandMode, _: Switch) -> Result<Bool, CommandantError<ClientError>><\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "T : ArgumentProtocol<\/Type><\/Declaration>", + "key.column" : 25, + "key.decl_lang" : "source.lang.swift", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 16, + "key.offset" : 6101 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "T<\/decl.generic_type_param.name> : ArgumentProtocol<\/ref.protocol><\/decl.generic_type_param.constraint><\/decl.generic_type_param>", + "key.inheritedtypes" : [ + { + "key.name" : "ArgumentProtocol" + } + ], + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 19, + "key.line" : 163, + "key.modulename" : "Commandant", + "key.name" : "T", + "key.namelength" : 1, + "key.nameoffset" : 6098, + "key.offset" : 6098, + "key.parsed_declaration" : "public static func <| ClientError<\/Declaration>", + "key.column" : 46, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 163, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 6119, + "key.offset" : 6119, + "key.parsed_declaration" : "public static func <| let key: String<\/Type><\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "let<\/syntaxtype.keyword> key<\/decl.name>: String<\/ref.struct><\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 20, + "key.line" : 164, + "key.modulename" : "Commandant", + "key.name" : "key", + "key.namelength" : 3, + "key.nameoffset" : 6223, + "key.offset" : 6219, + "key.parsed_declaration" : "let key = option.key", + "key.parsed_scope.end" : 164, + "key.parsed_scope.start" : 164, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant11CommandModeO2looiys6ResultOyxSgAA0A5ErrorOyq_GGAC_AA6OptionVyAGGtAA16ArgumentProtocolRzr0_lFZ3keyL_SSvp" + } + ], + "key.typename" : " (CommandMode.Type) -> (CommandMode, Option) -> Result>", + "key.typeusr" : "$sys6ResultOyxSg10Commandant0B5ErrorOyq_GGAD11CommandModeO_AD6OptionVyACGtcAD16ArgumentProtocolRzr0_luD", + "key.usr" : "s:10Commandant11CommandModeO2looiys6ResultOyxSgAA0A5ErrorOyq_GGAC_AA6OptionVyAGGtAA16ArgumentProtocolRzr0_lFZ" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public static func <| <T, ClientError>(mode: CommandMode<\/Type>, option: Option<\/Type><[T<\/Type>]>) -> Result<\/Type><[T<\/Type>], CommandantError<\/Type><ClientError<\/Type>>> where T<\/Type> : ArgumentProtocol<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 7258 + } + ], + "key.bodylength" : 232, + "key.bodyoffset" : 7401, + "key.column" : 21, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Evaluates the given option in the given mode.\n\nIf parsing command line arguments, and no value was specified on the command\nline, the option's `defaultValue` is used.", + "key.doc.column" : 21, + "key.doc.comment" : "Evaluates the given option in the given mode.\n\nIf parsing command line arguments, and no value was specified on the command\nline, the option's `defaultValue` is used.", + "key.doc.declaration" : "public static func <| (mode: CommandMode, option: Option<[T]>) -> Result<[T], CommandantError> where T : Commandant.ArgumentProtocol", + "key.doc.discussion" : [ + { + "Para" : "If parsing command line arguments, and no value was specified on the command line, the option’s `defaultValue` is used." + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Option.swift", + "key.doc.full_as_xml" : "<|(_:_:)<\/Name>s:10Commandant11CommandModeO2looiys6ResultOySayxGAA0A5ErrorOyq_GGAC_AA6OptionVyAGGtAA16ArgumentProtocolRzr0_lFZ<\/USR>public static func <| <T, ClientError>(mode: CommandMode, option: Option<[T]>) -> Result<[T], CommandantError<ClientError>> where T : Commandant.ArgumentProtocol<\/Declaration>Evaluates the given option in the given mode.<\/Para><\/Abstract>If parsing command line arguments, and no value was specified on the command line, the option’s defaultValue<\/codeVoice> is used.<\/Para><\/Discussion><\/CommentParts><\/Function>", + "key.doc.line" : 202, + "key.doc.name" : "<|(_:_:)", + "key.doc.type" : "Function", + "key.doclength" : 185, + "key.docoffset" : 7072, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> static<\/syntaxtype.keyword> func<\/syntaxtype.keyword> <| <\/decl.name><T<\/decl.generic_type_param.name><\/decl.generic_type_param>, ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>>(mode<\/decl.var.parameter.name>: CommandMode<\/ref.enum><\/decl.var.parameter.type><\/decl.var.parameter>, option<\/decl.var.parameter.name>: Option<\/ref.struct><[T<\/ref.generic_type_param>]><\/decl.var.parameter.type><\/decl.var.parameter>) -> Result<\/ref.enum><[T<\/ref.generic_type_param>], CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>>><\/decl.function.returntype> where<\/syntaxtype.keyword> T<\/ref.generic_type_param> : ArgumentProtocol<\/ref.protocol><\/decl.generic_type_requirement><\/decl.function.operator.infix>", + "key.kind" : "source.lang.swift.decl.function.method.static", + "key.length" : 369, + "key.line" : 202, + "key.modulename" : "Commandant", + "key.name" : "<|(_:_:)", + "key.namelength" : 77, + "key.nameoffset" : 7277, + "key.offset" : 7265, + "key.parsed_declaration" : "public static func <| (mode: CommandMode, option: Option<[T]>) -> Result<[T], CommandantError>", + "key.parsed_scope.end" : 207, + "key.parsed_scope.start" : 202, + "key.related_decls" : [ + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Argument<T>) -> Result<T, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Argument<[T]>) -> Result<[T], CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<T>) -> Result<T, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<T?>) -> Result<T?, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<[T]?>) -> Result<[T]?, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <ClientError>(_: CommandMode, _: Option<Bool>) -> Result<Bool, CommandantError<ClientError>><\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <ClientError>(_: CommandMode, _: Switch) -> Result<Bool, CommandantError<ClientError>><\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "T : ArgumentProtocol<\/Type><\/Declaration>", + "key.column" : 25, + "key.decl_lang" : "source.lang.swift", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 16, + "key.offset" : 7284 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "T<\/decl.generic_type_param.name> : ArgumentProtocol<\/ref.protocol><\/decl.generic_type_param.constraint><\/decl.generic_type_param>", + "key.inheritedtypes" : [ + { + "key.name" : "ArgumentProtocol" + } + ], + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 19, + "key.line" : 202, + "key.modulename" : "Commandant", + "key.name" : "T", + "key.namelength" : 1, + "key.nameoffset" : 7281, + "key.offset" : 7281, + "key.parsed_declaration" : "public static func <| ClientError<\/Declaration>", + "key.column" : 46, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 202, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 7302, + "key.offset" : 7302, + "key.parsed_declaration" : "public static func <| let wrapped: Option<\/Type><[T<\/Type>]?><\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "let<\/syntaxtype.keyword> wrapped<\/decl.name>: Option<\/ref.struct><[T<\/ref.generic_type_param>]?><\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 99, + "key.line" : 203, + "key.modulename" : "Commandant", + "key.name" : "wrapped", + "key.namelength" : 7, + "key.nameoffset" : 7408, + "key.offset" : 7404, + "key.parsed_declaration" : "let wrapped = Option<[T]?>(key: option.key, defaultValue: option.defaultValue, usage: option.usage)", + "key.parsed_scope.end" : 203, + "key.parsed_scope.start" : 203, + "key.reusingastcontext" : false, + "key.typename" : "Option<[T]?>", + "key.typeusr" : "$s10Commandant6OptionVySayxGSgGD", + "key.usr" : "s:10Commandant11CommandModeO2looiys6ResultOySayxGAA0A5ErrorOyq_GGAC_AA6OptionVyAGGtAA16ArgumentProtocolRzr0_lFZ7wrappedL_AMyAGSgGvp" + } + ], + "key.typename" : " (CommandMode.Type) -> (CommandMode, Option<[T]>) -> Result<[T], CommandantError>", + "key.typeusr" : "$sys6ResultOySayxG10Commandant0B5ErrorOyq_GGAD11CommandModeO_AD6OptionVyACGtcAD16ArgumentProtocolRzr0_luD", + "key.usr" : "s:10Commandant11CommandModeO2looiys6ResultOySayxGAA0A5ErrorOyq_GGAC_AA6OptionVyAGGtAA16ArgumentProtocolRzr0_lFZ" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public static func <| <T, ClientError>(mode: CommandMode<\/Type>, option: Option<\/Type><[T<\/Type>]?>) -> Result<\/Type><[T<\/Type>]?, CommandantError<\/Type><ClientError<\/Type>>> where T<\/Type> : ArgumentProtocol<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 7801 + } + ], + "key.bodylength" : 1117, + "key.bodyoffset" : 7946, + "key.column" : 21, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Evaluates the given option in the given mode.\n\nIf parsing command line arguments, and no value was specified on the command\nline, `nil` is used.", + "key.doc.column" : 21, + "key.doc.comment" : "Evaluates the given option in the given mode.\n\nIf parsing command line arguments, and no value was specified on the command\nline, `nil` is used.", + "key.doc.declaration" : "public static func <| (mode: CommandMode, option: Option<[T]?>) -> Result<[T]?, CommandantError> where T : Commandant.ArgumentProtocol", + "key.doc.discussion" : [ + { + "Para" : "If parsing command line arguments, and no value was specified on the command line, `nil` is used." + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Option.swift", + "key.doc.full_as_xml" : "<|(_:_:)<\/Name>s:10Commandant11CommandModeO2looiys6ResultOySayxGSgAA0A5ErrorOyq_GGAC_AA6OptionVyAHGtAA16ArgumentProtocolRzr0_lFZ<\/USR>public static func <| <T, ClientError>(mode: CommandMode, option: Option<[T]?>) -> Result<[T]?, CommandantError<ClientError>> where T : Commandant.ArgumentProtocol<\/Declaration>Evaluates the given option in the given mode.<\/Para><\/Abstract>If parsing command line arguments, and no value was specified on the command line, nil<\/codeVoice> is used.<\/Para><\/Discussion><\/CommentParts><\/Function>", + "key.doc.line" : 213, + "key.doc.name" : "<|(_:_:)", + "key.doc.type" : "Function", + "key.doclength" : 163, + "key.docoffset" : 7637, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> static<\/syntaxtype.keyword> func<\/syntaxtype.keyword> <| <\/decl.name><T<\/decl.generic_type_param.name><\/decl.generic_type_param>, ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>>(mode<\/decl.var.parameter.name>: CommandMode<\/ref.enum><\/decl.var.parameter.type><\/decl.var.parameter>, option<\/decl.var.parameter.name>: Option<\/ref.struct><[T<\/ref.generic_type_param>]?><\/decl.var.parameter.type><\/decl.var.parameter>) -> Result<\/ref.enum><[T<\/ref.generic_type_param>]?, CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>>><\/decl.function.returntype> where<\/syntaxtype.keyword> T<\/ref.generic_type_param> : ArgumentProtocol<\/ref.protocol><\/decl.generic_type_requirement><\/decl.function.operator.infix>", + "key.kind" : "source.lang.swift.decl.function.method.static", + "key.length" : 1256, + "key.line" : 213, + "key.modulename" : "Commandant", + "key.name" : "<|(_:_:)", + "key.namelength" : 78, + "key.nameoffset" : 7820, + "key.offset" : 7808, + "key.parsed_declaration" : "public static func <| (mode: CommandMode, option: Option<[T]?>) -> Result<[T]?, CommandantError>", + "key.parsed_scope.end" : 254, + "key.parsed_scope.start" : 213, + "key.related_decls" : [ + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Argument<T>) -> Result<T, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Argument<[T]>) -> Result<[T], CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<T>) -> Result<T, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<T?>) -> Result<T?, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<[T]>) -> Result<[T], CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <ClientError>(_: CommandMode, _: Option<Bool>) -> Result<Bool, CommandantError<ClientError>><\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <ClientError>(_: CommandMode, _: Switch) -> Result<Bool, CommandantError<ClientError>><\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "T : ArgumentProtocol<\/Type><\/Declaration>", + "key.column" : 25, + "key.decl_lang" : "source.lang.swift", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 16, + "key.offset" : 7827 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "T<\/decl.generic_type_param.name> : ArgumentProtocol<\/ref.protocol><\/decl.generic_type_param.constraint><\/decl.generic_type_param>", + "key.inheritedtypes" : [ + { + "key.name" : "ArgumentProtocol" + } + ], + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 19, + "key.line" : 213, + "key.modulename" : "Commandant", + "key.name" : "T", + "key.namelength" : 1, + "key.nameoffset" : 7824, + "key.offset" : 7824, + "key.parsed_declaration" : "public static func <| ClientError<\/Declaration>", + "key.column" : 46, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 213, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 7845, + "key.offset" : 7845, + "key.parsed_declaration" : "public static func <| let key: String<\/Type><\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "let<\/syntaxtype.keyword> key<\/decl.name>: String<\/ref.struct><\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 20, + "key.line" : 214, + "key.modulename" : "Commandant", + "key.name" : "key", + "key.namelength" : 3, + "key.nameoffset" : 7953, + "key.offset" : 7949, + "key.parsed_declaration" : "let key = option.key", + "key.parsed_scope.end" : 214, + "key.parsed_scope.start" : 214, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant11CommandModeO2looiys6ResultOySayxGSgAA0A5ErrorOyq_GGAC_AA6OptionVyAHGtAA16ArgumentProtocolRzr0_lFZ3keyL_SSvp" + } + ], + "key.typename" : " (CommandMode.Type) -> (CommandMode, Option<[T]?>) -> Result<[T]?, CommandantError>", + "key.typeusr" : "$sys6ResultOySayxGSg10Commandant0B5ErrorOyq_GGAE11CommandModeO_AE6OptionVyADGtcAE16ArgumentProtocolRzr0_luD", + "key.usr" : "s:10Commandant11CommandModeO2looiys6ResultOySayxGSgAA0A5ErrorOyq_GGAC_AA6OptionVyAHGtAA16ArgumentProtocolRzr0_lFZ" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public static func <| <ClientError>(mode: CommandMode<\/Type>, option: Option<\/Type><Bool<\/Type>>) -> Result<\/Type><Bool<\/Type>, CommandantError<\/Type><ClientError<\/Type>>><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 9261 + } + ], + "key.bodylength" : 272, + "key.bodyoffset" : 9385, + "key.column" : 21, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Evaluates the given boolean option in the given mode.\n\nIf parsing command line arguments, and no value was specified on the command\nline, the option's `defaultValue` is used.", + "key.doc.column" : 21, + "key.doc.comment" : "Evaluates the given boolean option in the given mode.\n\nIf parsing command line arguments, and no value was specified on the command\nline, the option's `defaultValue` is used.", + "key.doc.declaration" : "public static func <| (mode: CommandMode, option: Option) -> Result>", + "key.doc.discussion" : [ + { + "Para" : "If parsing command line arguments, and no value was specified on the command line, the option’s `defaultValue` is used." + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Option.swift", + "key.doc.full_as_xml" : "<|(_:_:)<\/Name>s:10Commandant11CommandModeO2looiys6ResultOySbAA0A5ErrorOyxGGAC_AA6OptionVySbGtlFZ<\/USR>public static func <| <ClientError>(mode: CommandMode, option: Option<Bool>) -> Result<Bool, CommandantError<ClientError>><\/Declaration>Evaluates the given boolean option in the given mode.<\/Para><\/Abstract>If parsing command line arguments, and no value was specified on the command line, the option’s defaultValue<\/codeVoice> is used.<\/Para><\/Discussion><\/CommentParts><\/Function>", + "key.doc.line" : 260, + "key.doc.name" : "<|(_:_:)", + "key.doc.type" : "Function", + "key.doclength" : 193, + "key.docoffset" : 9067, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> static<\/syntaxtype.keyword> func<\/syntaxtype.keyword> <| <\/decl.name><ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>>(mode<\/decl.var.parameter.name>: CommandMode<\/ref.enum><\/decl.var.parameter.type><\/decl.var.parameter>, option<\/decl.var.parameter.name>: Option<\/ref.struct><Bool<\/ref.struct>><\/decl.var.parameter.type><\/decl.var.parameter>) -> Result<\/ref.enum><Bool<\/ref.struct>, CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>>><\/decl.function.returntype><\/decl.function.operator.infix>", + "key.kind" : "source.lang.swift.decl.function.method.static", + "key.length" : 390, + "key.line" : 260, + "key.modulename" : "Commandant", + "key.name" : "<|(_:_:)", + "key.namelength" : 57, + "key.nameoffset" : 9280, + "key.offset" : 9268, + "key.parsed_declaration" : "public static func <| (mode: CommandMode, option: Option) -> Result>", + "key.parsed_scope.end" : 272, + "key.parsed_scope.start" : 260, + "key.related_decls" : [ + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Argument<T>) -> Result<T, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Argument<[T]>) -> Result<[T], CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<T>) -> Result<T, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<T?>) -> Result<T?, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<[T]>) -> Result<[T], CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<[T]?>) -> Result<[T]?, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <ClientError>(_: CommandMode, _: Switch) -> Result<Bool, CommandantError<ClientError>><\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "ClientError<\/Declaration>", + "key.column" : 25, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 260, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 9284, + "key.offset" : 9284, + "key.parsed_declaration" : "public static func <| (CommandMode.Type) -> (CommandMode, Option) -> Result>", + "key.typeusr" : "$sys6ResultOySb10Commandant0B5ErrorOyxGGAC11CommandModeO_AC6OptionVySbGtcluD", + "key.usr" : "s:10Commandant11CommandModeO2looiys6ResultOySbAA0A5ErrorOyxGGAC_AA6OptionVySbGtlFZ" + } + ], + "key.typename" : "CommandMode.Type", + "key.typeusr" : "$s10Commandant11CommandModeOmD", + "key.usr" : "s:10Commandant11CommandModeO" + } + ] + } +}, { + "\/Sources\/Commandant\/OrderedSet.swift" : { + "key.diagnostic_stage" : "source.diagnostic.stage.swift.parse", + "key.length" : 800, + "key.offset" : 0, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "internal struct OrderedSet<T> : Equatable<\/Type> where T<\/Type> : Hashable<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.internal", + "key.length" : 8, + "key.offset" : 30 + } + ], + "key.bodylength" : 348, + "key.bodyoffset" : 82, + "key.column" : 17, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A poor man's ordered set.", + "key.doc.column" : 17, + "key.doc.comment" : "A poor man's ordered set.", + "key.doc.declaration" : "internal struct OrderedSet : Equatable where T : Hashable", + "key.doc.file" : "\/private\/Sources\/Commandant\/OrderedSet.swift", + "key.doc.full_as_xml" : "OrderedSet<\/Name>s:10Commandant10OrderedSetV<\/USR>internal struct OrderedSet<T> : Equatable where T : Hashable<\/Declaration>A poor man’s ordered set.<\/Para><\/Abstract><\/CommentParts><\/Class>", + "key.doc.line" : 2, + "key.doc.name" : "OrderedSet", + "key.doc.type" : "Class", + "key.doclength" : 30, + "key.docoffset" : 0, + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 9, + "key.offset" : 71 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "internal<\/syntaxtype.keyword> struct<\/syntaxtype.keyword> OrderedSet<\/decl.name><T<\/decl.generic_type_param.name><\/decl.generic_type_param>> : Equatable<\/ref.protocol> where<\/syntaxtype.keyword> T<\/ref.generic_type_param> : Hashable<\/ref.protocol><\/decl.generic_type_requirement><\/decl.struct>", + "key.inheritedtypes" : [ + { + "key.name" : "Equatable" + } + ], + "key.kind" : "source.lang.swift.decl.struct", + "key.length" : 392, + "key.line" : 2, + "key.modulename" : "Commandant", + "key.name" : "OrderedSet", + "key.namelength" : 10, + "key.nameoffset" : 46, + "key.offset" : 39, + "key.parsed_declaration" : "internal struct OrderedSet: Equatable", + "key.parsed_scope.end" : 19, + "key.parsed_scope.start" : 2, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "T : Hashable<\/Type><\/Declaration>", + "key.column" : 28, + "key.decl_lang" : "source.lang.swift", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 8, + "key.offset" : 60 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "T<\/decl.generic_type_param.name> : Hashable<\/ref.protocol><\/decl.generic_type_param.constraint><\/decl.generic_type_param>", + "key.inheritedtypes" : [ + { + "key.name" : "Hashable" + } + ], + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 2, + "key.modulename" : "Commandant", + "key.name" : "T", + "key.namelength" : 1, + "key.nameoffset" : 57, + "key.offset" : 57, + "key.parsed_declaration" : "internal struct OrderedSetfileprivate var values: [T<\/Type>]<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.fileprivate", + "key.length" : 11, + "key.offset" : 84 + } + ], + "key.column" : 18, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "fileprivate<\/syntaxtype.keyword> var<\/syntaxtype.keyword> values<\/decl.name>: [T<\/ref.generic_type_param>]<\/decl.var.type><\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 20, + "key.line" : 3, + "key.modulename" : "Commandant", + "key.name" : "values", + "key.namelength" : 6, + "key.nameoffset" : 100, + "key.offset" : 96, + "key.parsed_declaration" : "fileprivate var values: [T] = []", + "key.parsed_scope.end" : 3, + "key.parsed_scope.start" : 3, + "key.reusingastcontext" : false, + "key.setter_accessibility" : "source.lang.swift.accessibility.fileprivate", + "key.typename" : "[T]", + "key.typeusr" : "$sSayxGD", + "key.usr" : "s:10Commandant10OrderedSetV6values33_E700A43BE27995F7283A44882E2B4A42LLSayxGvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "init<S>(_ sequence: S<\/Type>) where T<\/Type> == S<\/Type>.Element<\/Type>, S<\/Type> : Sequence<\/Type><\/Declaration>", + "key.bodylength" : 74, + "key.bodyoffset" : 174, + "key.column" : 2, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "init<\/syntaxtype.keyword><S<\/decl.generic_type_param.name><\/decl.generic_type_param>>(_<\/decl.var.parameter.argument_label> sequence<\/decl.var.parameter.name>: S<\/ref.generic_type_param><\/decl.var.parameter.type><\/decl.var.parameter>) where<\/syntaxtype.keyword> T<\/ref.generic_type_param> == S<\/ref.generic_type_param>.Element<\/ref.associatedtype><\/decl.generic_type_requirement>, S<\/ref.generic_type_param> : Sequence<\/ref.protocol><\/decl.generic_type_requirement><\/decl.function.constructor>", + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 130, + "key.line" : 5, + "key.modulename" : "Commandant", + "key.name" : "init(_:)", + "key.namelength" : 32, + "key.nameoffset" : 119, + "key.offset" : 119, + "key.parsed_declaration" : "init(_ sequence: S) where S.Element == T", + "key.parsed_scope.end" : 9, + "key.parsed_scope.start" : 5, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "S : Sequence<\/Type><\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 8, + "key.offset" : 127 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "S<\/decl.generic_type_param.name> : Sequence<\/ref.protocol><\/decl.generic_type_param.constraint><\/decl.generic_type_param>", + "key.inheritedtypes" : [ + { + "key.name" : "Sequence" + } + ], + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 5, + "key.modulename" : "Commandant", + "key.name" : "S", + "key.namelength" : 1, + "key.nameoffset" : 124, + "key.offset" : 124, + "key.parsed_declaration" : "init (OrderedSet.Type) -> (S) -> OrderedSet", + "key.typeusr" : "$sy10Commandant10OrderedSetVyxGqd__c7ElementQyd__RszSTRd__luD", + "key.usr" : "s:10Commandant10OrderedSetVyACyxGqd__c7ElementQyd__RszSTRd__lufc" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "@discardableResult mutating func remove(_ member: T<\/Type>) -> T<\/Type>?<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.mutating", + "key.length" : 8, + "key.offset" : 272 + }, + { + "key.attribute" : "source.decl.attribute.discardableResult", + "key.length" : 18, + "key.offset" : 252 + } + ], + "key.bodylength" : 115, + "key.bodyoffset" : 313, + "key.column" : 16, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "@discardableResult<\/syntaxtype.attribute.name><\/syntaxtype.attribute.builtin> mutating<\/syntaxtype.keyword> func<\/syntaxtype.keyword> remove<\/decl.name>(_<\/decl.var.parameter.argument_label> member<\/decl.var.parameter.name>: T<\/ref.generic_type_param><\/decl.var.parameter.type><\/decl.var.parameter>) -> T<\/ref.generic_type_param>?<\/decl.function.returntype><\/decl.function.method.instance>", + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 148, + "key.line" : 12, + "key.modulename" : "Commandant", + "key.name" : "remove(_:)", + "key.namelength" : 19, + "key.nameoffset" : 286, + "key.offset" : 281, + "key.parsed_declaration" : "mutating func remove(_ member: T) -> T?", + "key.parsed_scope.end" : 18, + "key.parsed_scope.start" : 12, + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : " (inout OrderedSet) -> (T) -> T?", + "key.typeusr" : "$syxSgxcD", + "key.usr" : "s:10Commandant10OrderedSetV6removeyxSgxF" + } + ], + "key.typename" : "OrderedSet.Type", + "key.typeusr" : "$s10Commandant10OrderedSetVyxGmD", + "key.usr" : "s:10Commandant10OrderedSetV" + }, + { + "key.annotated_decl" : "internal struct OrderedSet<T> : Equatable<\/Type> where T<\/Type> : Hashable<\/Type><\/Declaration>", + "key.bodylength" : 331, + "key.bodyoffset" : 467, + "key.column" : 17, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A poor man's ordered set.", + "key.doc.column" : 17, + "key.doc.declaration" : "internal struct OrderedSet : Equatable where T : Hashable", + "key.doc.file" : "\/private\/Sources\/Commandant\/OrderedSet.swift", + "key.doc.full_as_xml" : "OrderedSet<\/Name>s:10Commandant10OrderedSetV<\/USR>internal struct OrderedSet<T> : Equatable where T : Hashable<\/Declaration>A poor man’s ordered set.<\/Para><\/Abstract><\/CommentParts><\/Class>", + "key.doc.line" : 2, + "key.doc.name" : "OrderedSet", + "key.doc.type" : "Class", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 10, + "key.offset" : 455 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "internal<\/syntaxtype.keyword> struct<\/syntaxtype.keyword> OrderedSet<\/decl.name><T<\/decl.generic_type_param.name><\/decl.generic_type_param>> : Equatable<\/ref.protocol> where<\/syntaxtype.keyword> T<\/ref.generic_type_param> : Hashable<\/ref.protocol><\/decl.generic_type_requirement><\/decl.struct>", + "key.inheritedtypes" : [ + { + "key.name" : "Collection" + } + ], + "key.kind" : "source.lang.swift.decl.extension", + "key.length" : 366, + "key.line" : 2, + "key.modulename" : "Commandant", + "key.name" : "OrderedSet", + "key.namelength" : 10, + "key.nameoffset" : 443, + "key.offset" : 433, + "key.parsed_declaration" : "extension OrderedSet: Collection", + "key.parsed_scope.end" : 45, + "key.parsed_scope.start" : 21, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "subscript(position: Int<\/Type>) -> T<\/Type> { get }<\/Declaration>", + "key.bodylength" : 28, + "key.bodyoffset" : 500, + "key.column" : 2, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Accesses the element at the specified position.\n\nThe following example accesses an element of an array through its\nsubscript to print its value:\n\n var streets = [\"Adams\", \"Bryant\", \"Channing\", \"Douglas\", \"Evarts\"]\n print(streets[1])\n \/\/ Prints \"Bryant\"\n\nYou can subscript a collection with any valid index other than the\ncollection's end index. The end index refers to the position one past\nthe last element of a collection, so it doesn't correspond with an\nelement.\n\n- Parameter position: The position of the element to access. `position`\n must be a valid index of the collection that is not equal to the\n `endIndex` property.\n\n- Complexity: O(1)", + "key.doc.declaration" : "subscript(position: Self.Index) -> Self.Element { get }", + "key.doc.discussion" : [ + { + "Para" : "The following example accesses an element of an array through its subscript to print its value:" + }, + { + "CodeListing" : "" + }, + { + "Para" : "You can subscript a collection with any valid index other than the collection’s end index. The end index refers to the position one past the last element of a collection, so it doesn’t correspond with an element." + }, + { + "Complexity" : "" + }, + { + "Note" : "" + } + ], + "key.doc.full_as_xml" : "subscript(_:)<\/Name>s:Sly7ElementQz5IndexQzcip<\/USR>subscript(position: Self.Index) -> Self.Element { get }<\/Declaration>Accesses the element at the specified position.<\/Para><\/Abstract>position<\/Name>in<\/Direction>The position of the element to access. position<\/codeVoice> must be a valid index of the collection that is not equal to the endIndex<\/codeVoice> property.<\/Para><\/Discussion><\/Parameter><\/Parameters>The following example accesses an element of an array through its subscript to print its value:<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>You can subscript a collection with any valid index other than the collection’s end index. The end index refers to the position one past the last element of a collection, so it doesn’t correspond with an element.<\/Para>O(1)<\/Para><\/Complexity>This documentation comment was inherited from Collection<\/codeVoice>.<\/Para><\/Note><\/Discussion><\/CommentParts><\/Other>", + "key.doc.name" : "subscript(_:)", + "key.doc.parameters" : [ + { + "discussion" : [ + { + "Para" : "The position of the element to access. `position` must be a valid index of the collection that is not equal to the `endIndex` property." + } + ], + "name" : "position" + } + ], + "key.doc.type" : "Other", + "key.filepath" : "", + "key.fully_annotated_decl" : "subscript<\/syntaxtype.keyword>(position<\/decl.var.parameter.name>: Int<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>) -> T<\/ref.generic_type_param><\/decl.function.returntype> { get<\/syntaxtype.keyword> }<\/decl.function.subscript>", + "key.kind" : "source.lang.swift.decl.function.subscript", + "key.length" : 60, + "key.line" : 22, + "key.modulename" : "Commandant", + "key.name" : "subscript(_:)", + "key.namelength" : 24, + "key.nameoffset" : 469, + "key.offset" : 469, + "key.overrides" : [ + { + "key.usr" : "s:Sly7ElementQz5IndexQzcip" + } + ], + "key.parsed_declaration" : "subscript(position: Int) -> T", + "key.parsed_scope.end" : 24, + "key.parsed_scope.start" : 22, + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : " (Int) -> T", + "key.typeusr" : "$syxSicD", + "key.usr" : "s:Sly7ElementQz5IndexQzcip" + }, + { + "key.annotated_decl" : "var count: Int<\/Type> { get }<\/Declaration>", + "key.bodylength" : 24, + "key.bodyoffset" : 548, + "key.column" : 6, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "The number of elements in the collection.\n\nTo check whether a collection is empty, use its `isEmpty` property\ninstead of comparing `count` to zero. Unless the collection guarantees\nrandom-access performance, calculating `count` can be an O(*n*)\noperation.\n\n- Complexity: O(1) if the collection conforms to\n `RandomAccessCollection`; otherwise, O(*n*), where *n* is the length\n of the collection.", + "key.doc.declaration" : "var count: Int { get }", + "key.doc.discussion" : [ + { + "Para" : "To check whether a collection is empty, use its `isEmpty` property instead of comparing `count` to zero. Unless the collection guarantees random-access performance, calculating `count` can be an O() operation." + }, + { + "Complexity" : "" + }, + { + "Note" : "" + } + ], + "key.doc.full_as_xml" : "count<\/Name>s:Sl5countSivp<\/USR>var count: Int { get }<\/Declaration>The number of elements in the collection.<\/Para><\/Abstract>To check whether a collection is empty, use its isEmpty<\/codeVoice> property instead of comparing count<\/codeVoice> to zero. Unless the collection guarantees random-access performance, calculating count<\/codeVoice> can be an O(n<\/emphasis>) operation.<\/Para>O(1) if the collection conforms to RandomAccessCollection<\/codeVoice>; otherwise, O(n<\/emphasis>), where n<\/emphasis> is the length of the collection.<\/Para><\/Complexity>This documentation comment was inherited from Collection<\/codeVoice>.<\/Para><\/Note><\/Discussion><\/CommentParts><\/Other>", + "key.doc.name" : "count", + "key.doc.type" : "Other", + "key.filepath" : "", + "key.fully_annotated_decl" : "var<\/syntaxtype.keyword> count<\/decl.name>: Int<\/ref.struct><\/decl.var.type> { get<\/syntaxtype.keyword> }<\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 41, + "key.line" : 26, + "key.modulename" : "Commandant", + "key.name" : "count", + "key.namelength" : 5, + "key.nameoffset" : 536, + "key.offset" : 532, + "key.overrides" : [ + { + "key.usr" : "s:Sl5countSivp" + } + ], + "key.parsed_declaration" : "var count: Int", + "key.parsed_scope.end" : 28, + "key.parsed_scope.start" : 26, + "key.reusingastcontext" : false, + "key.typename" : "Int", + "key.typeusr" : "$sSiD", + "key.usr" : "s:Sl5countSivp" + }, + { + "key.annotated_decl" : "var isEmpty: Bool<\/Type> { get }<\/Declaration>", + "key.bodylength" : 26, + "key.bodyoffset" : 595, + "key.column" : 6, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A Boolean value indicating whether the collection is empty.\n\nWhen you need to check whether your collection is empty, use the\n`isEmpty` property instead of checking that the `count` property is\nequal to zero. For collections that don't conform to\n`RandomAccessCollection`, accessing the `count` property iterates\nthrough the elements of the collection.\n\n let horseName = \"Silver\"\n if horseName.isEmpty {\n print(\"My horse has no name.\")\n } else {\n print(\"Hi ho, \\(horseName)!\")\n }\n \/\/ Prints \"Hi ho, Silver!\"\n\n- Complexity: O(1)", + "key.doc.declaration" : "var isEmpty: Bool { get }", + "key.doc.discussion" : [ + { + "Para" : "When you need to check whether your collection is empty, use the `isEmpty` property instead of checking that the `count` property is equal to zero. For collections that don’t conform to `RandomAccessCollection`, accessing the `count` property iterates through the elements of the collection." + }, + { + "CodeListing" : "" + }, + { + "Complexity" : "" + }, + { + "Note" : "" + } + ], + "key.doc.full_as_xml" : "isEmpty<\/Name>s:Sl7isEmptySbvp<\/USR>var isEmpty: Bool { get }<\/Declaration>A Boolean value indicating whether the collection is empty.<\/Para><\/Abstract>When you need to check whether your collection is empty, use the isEmpty<\/codeVoice> property instead of checking that the count<\/codeVoice> property is equal to zero. For collections that don’t conform to RandomAccessCollection<\/codeVoice>, accessing the count<\/codeVoice> property iterates through the elements of the collection.<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>O(1)<\/Para><\/Complexity>This documentation comment was inherited from Collection<\/codeVoice>.<\/Para><\/Note><\/Discussion><\/CommentParts><\/Other>", + "key.doc.name" : "isEmpty", + "key.doc.type" : "Other", + "key.filepath" : "", + "key.fully_annotated_decl" : "var<\/syntaxtype.keyword> isEmpty<\/decl.name>: Bool<\/ref.struct><\/decl.var.type> { get<\/syntaxtype.keyword> }<\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 46, + "key.line" : 30, + "key.modulename" : "Commandant", + "key.name" : "isEmpty", + "key.namelength" : 7, + "key.nameoffset" : 580, + "key.offset" : 576, + "key.overrides" : [ + { + "key.usr" : "s:Sl7isEmptySbvp" + } + ], + "key.parsed_declaration" : "var isEmpty: Bool", + "key.parsed_scope.end" : 32, + "key.parsed_scope.start" : 30, + "key.reusingastcontext" : false, + "key.typename" : "Bool", + "key.typeusr" : "$sSbD", + "key.usr" : "s:Sl7isEmptySbvp" + }, + { + "key.annotated_decl" : "var startIndex: Int<\/Type> { get }<\/Declaration>", + "key.bodylength" : 29, + "key.bodyoffset" : 646, + "key.column" : 6, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "The position of the first element in a nonempty collection.\n\nIf the collection is empty, `startIndex` is equal to `endIndex`.", + "key.doc.declaration" : "var startIndex: Self.Index { get }", + "key.doc.discussion" : [ + { + "Para" : "If the collection is empty, `startIndex` is equal to `endIndex`." + }, + { + "Note" : "" + } + ], + "key.doc.full_as_xml" : "startIndex<\/Name>s:Sl10startIndex0B0Qzvp<\/USR>var startIndex: Self.Index { get }<\/Declaration>The position of the first element in a nonempty collection.<\/Para><\/Abstract>If the collection is empty, startIndex<\/codeVoice> is equal to endIndex<\/codeVoice>.<\/Para>This documentation comment was inherited from Collection<\/codeVoice>.<\/Para><\/Note><\/Discussion><\/CommentParts><\/Other>", + "key.doc.name" : "startIndex", + "key.doc.type" : "Other", + "key.filepath" : "", + "key.fully_annotated_decl" : "var<\/syntaxtype.keyword> startIndex<\/decl.name>: Int<\/ref.struct><\/decl.var.type> { get<\/syntaxtype.keyword> }<\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 51, + "key.line" : 34, + "key.modulename" : "Commandant", + "key.name" : "startIndex", + "key.namelength" : 10, + "key.nameoffset" : 629, + "key.offset" : 625, + "key.overrides" : [ + { + "key.usr" : "s:Sl10startIndex0B0Qzvp" + } + ], + "key.parsed_declaration" : "var startIndex: Int", + "key.parsed_scope.end" : 36, + "key.parsed_scope.start" : 34, + "key.reusingastcontext" : false, + "key.typename" : "Int", + "key.typeusr" : "$sSiD", + "key.usr" : "s:Sl10startIndex0B0Qzvp" + }, + { + "key.annotated_decl" : "var endIndex: Int<\/Type> { get }<\/Declaration>", + "key.bodylength" : 27, + "key.bodyoffset" : 698, + "key.column" : 6, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "The collection's \"past the end\" position---that is, the position one\ngreater than the last valid subscript argument.\n\nWhen you need a range that includes the last element of a collection, use\nthe half-open range operator (`..<`) with `endIndex`. The `..<` operator\ncreates a range that doesn't include the upper bound, so it's always\nsafe to use with `endIndex`. For example:\n\n let numbers = [10, 20, 30, 40, 50]\n if let index = numbers.firstIndex(of: 30) {\n print(numbers[index ..< numbers.endIndex])\n }\n \/\/ Prints \"[30, 40, 50]\"\n\nIf the collection is empty, `endIndex` is equal to `startIndex`.", + "key.doc.declaration" : "var endIndex: Self.Index { get }", + "key.doc.discussion" : [ + { + "Para" : "When you need a range that includes the last element of a collection, use the half-open range operator (`..<`) with `endIndex`. The `..<` operator creates a range that doesn’t include the upper bound, so it’s always safe to use with `endIndex`. For example:" + }, + { + "CodeListing" : "" + }, + { + "Para" : "If the collection is empty, `endIndex` is equal to `startIndex`." + }, + { + "Note" : "" + } + ], + "key.doc.full_as_xml" : "endIndex<\/Name>s:Sl8endIndex0B0Qzvp<\/USR>var endIndex: Self.Index { get }<\/Declaration>The collection’s “past the end” position—that is, the position one greater than the last valid subscript argument.<\/Para><\/Abstract>When you need a range that includes the last element of a collection, use the half-open range operator (..<<\/codeVoice>) with endIndex<\/codeVoice>. The ..<<\/codeVoice> operator creates a range that doesn’t include the upper bound, so it’s always safe to use with endIndex<\/codeVoice>. For example:<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>If the collection is empty, endIndex<\/codeVoice> is equal to startIndex<\/codeVoice>.<\/Para>This documentation comment was inherited from Collection<\/codeVoice>.<\/Para><\/Note><\/Discussion><\/CommentParts><\/Other>", + "key.doc.name" : "endIndex", + "key.doc.type" : "Other", + "key.filepath" : "", + "key.fully_annotated_decl" : "var<\/syntaxtype.keyword> endIndex<\/decl.name>: Int<\/ref.struct><\/decl.var.type> { get<\/syntaxtype.keyword> }<\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 47, + "key.line" : 38, + "key.modulename" : "Commandant", + "key.name" : "endIndex", + "key.namelength" : 8, + "key.nameoffset" : 683, + "key.offset" : 679, + "key.overrides" : [ + { + "key.usr" : "s:Sl8endIndex0B0Qzvp" + } + ], + "key.parsed_declaration" : "var endIndex: Int", + "key.parsed_scope.end" : 40, + "key.parsed_scope.start" : 38, + "key.reusingastcontext" : false, + "key.typename" : "Int", + "key.typeusr" : "$sSiD", + "key.usr" : "s:Sl8endIndex0B0Qzvp" + }, + { + "key.annotated_decl" : "func index(after i: Int<\/Type>) -> Int<\/Type><\/Declaration>", + "key.bodylength" : 34, + "key.bodyoffset" : 762, + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Returns the position immediately after the given index.\n\nThe successor of an index must be well defined. For an index `i` into a\ncollection `c`, calling `c.index(after: i)` returns the same index every\ntime.\n\n- Parameter i: A valid index of the collection. `i` must be less than\n `endIndex`.\n- Returns: The index value immediately after `i`.", + "key.doc.declaration" : "func index(after i: Self.Index) -> Self.Index", + "key.doc.discussion" : [ + { + "Para" : "The successor of an index must be well defined. For an index `i` into a collection `c`, calling `c.index(after: i)` returns the same index every time." + }, + { + "Note" : "" + } + ], + "key.doc.full_as_xml" : "index(after:)<\/Name>s:Sl5index5after5IndexQzAD_tF<\/USR>func index(after i: Self.Index) -> Self.Index<\/Declaration>Returns the position immediately after the given index.<\/Para><\/Abstract>i<\/Name>in<\/Direction>A valid index of the collection. i<\/codeVoice> must be less than endIndex<\/codeVoice>.<\/Para><\/Discussion><\/Parameter><\/Parameters>The index value immediately after i<\/codeVoice>.<\/Para><\/ResultDiscussion>The successor of an index must be well defined. For an index i<\/codeVoice> into a collection c<\/codeVoice>, calling c.index(after: i)<\/codeVoice> returns the same index every time.<\/Para>This documentation comment was inherited from Collection<\/codeVoice>.<\/Para><\/Note><\/Discussion><\/CommentParts><\/Function>", + "key.doc.name" : "index(after:)", + "key.doc.parameters" : [ + { + "discussion" : [ + { + "Para" : "A valid index of the collection. `i` must be less than `endIndex`." + } + ], + "name" : "i" + } + ], + "key.doc.result_discussion" : [ + { + "Para" : "The index value immediately after `i`." + } + ], + "key.doc.type" : "Function", + "key.filepath" : "", + "key.fully_annotated_decl" : "func<\/syntaxtype.keyword> index<\/decl.name>(after<\/decl.var.parameter.argument_label> i<\/decl.var.parameter.name>: Int<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>) -> Int<\/ref.struct><\/decl.function.returntype><\/decl.function.method.instance>", + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 68, + "key.line" : 42, + "key.modulename" : "Commandant", + "key.name" : "index(after:)", + "key.namelength" : 19, + "key.nameoffset" : 734, + "key.offset" : 729, + "key.overrides" : [ + { + "key.usr" : "s:Sl5index5after5IndexQzAD_tF" + } + ], + "key.parsed_declaration" : "func index(after i: Int) -> Int", + "key.parsed_scope.end" : 44, + "key.parsed_scope.start" : 42, + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : " (OrderedSet) -> (Int) -> Int", + "key.typeusr" : "$s5afterS2i_tcD", + "key.usr" : "s:Sl5index5after5IndexQzAD_tF" + } + ], + "key.typename" : "OrderedSet.Type", + "key.typeusr" : "$s10Commandant10OrderedSetVyxGmD", + "key.usr" : "s:10Commandant10OrderedSetV" + } + ] + } +}, { + "\/Sources\/Commandant\/Result+Additions.swift" : { + "key.diagnostic_stage" : "source.diagnostic.stage.swift.parse", + "key.length" : 421, + "key.offset" : 0, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "@frozen enum Result<Success, Failure> where Failure<\/Type> : Error<\/Type>, Success<\/Type> : ~Copyable<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.internal", + "key.length" : 8, + "key.offset" : 148 + } + ], + "key.bodylength" : 244, + "key.bodyoffset" : 175, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A value that represents either a success or a failure, including an\nassociated value in each case.", + "key.doc.declaration" : "@frozen enum Result where Failure : Error, Success : ~Copyable", + "key.doc.full_as_xml" : "Result<\/Name>s:s6ResultO<\/USR>@frozen enum Result<Success, Failure> where Failure : Error, Success : ~Copyable<\/Declaration>A value that represents either a success or a failure, including an associated value in each case.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.name" : "Result", + "key.doc.type" : "Other", + "key.fully_annotated_decl" : "@frozen<\/syntaxtype.attribute.name><\/syntaxtype.attribute.builtin> enum<\/syntaxtype.keyword> Result<\/decl.name><Success<\/decl.generic_type_param.name><\/decl.generic_type_param>, Failure<\/decl.generic_type_param.name><\/decl.generic_type_param>> where<\/syntaxtype.keyword> Failure<\/ref.generic_type_param> : Error<\/ref.protocol><\/decl.generic_type_requirement>, Success<\/ref.generic_type_param> : <\/decl.generic_type_requirement>~Copyable<\/decl.enum>", + "key.groupname" : "Result", + "key.is_system" : true, + "key.kind" : "source.lang.swift.decl.extension", + "key.length" : 263, + "key.modulename" : "Swift", + "key.name" : "Result", + "key.namelength" : 6, + "key.nameoffset" : 167, + "key.offset" : 157, + "key.parsed_declaration" : "internal extension Result", + "key.parsed_scope.end" : 27, + "key.parsed_scope.start" : 9, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "var value: Success<\/Type>? { get }<\/Declaration>", + "key.bodylength" : 97, + "key.bodyoffset" : 198, + "key.column" : 6, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "var<\/syntaxtype.keyword> value<\/decl.name>: Success<\/ref.generic_type_param>?<\/decl.var.type> { get<\/syntaxtype.keyword> }<\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 119, + "key.line" : 10, + "key.modulename" : "Commandant", + "key.name" : "value", + "key.namelength" : 5, + "key.nameoffset" : 181, + "key.offset" : 177, + "key.parsed_declaration" : "var value: Success?", + "key.parsed_scope.end" : 17, + "key.parsed_scope.start" : 10, + "key.reusingastcontext" : false, + "key.typename" : "Success?", + "key.typeusr" : "$sxSgD", + "key.usr" : "s:s6ResultO10CommandantE5valuexSgvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "var error: Failure<\/Type>? { get }<\/Declaration>", + "key.bodylength" : 97, + "key.bodyoffset" : 320, + "key.column" : 6, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "var<\/syntaxtype.keyword> error<\/decl.name>: Failure<\/ref.generic_type_param>?<\/decl.var.type> { get<\/syntaxtype.keyword> }<\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 119, + "key.line" : 19, + "key.modulename" : "Commandant", + "key.name" : "error", + "key.namelength" : 5, + "key.nameoffset" : 303, + "key.offset" : 299, + "key.parsed_declaration" : "var error: Failure?", + "key.parsed_scope.end" : 26, + "key.parsed_scope.start" : 19, + "key.reusingastcontext" : false, + "key.typename" : "Failure?", + "key.typeusr" : "$sq_SgD", + "key.usr" : "s:s6ResultO10CommandantE5errorq_Sgvp" + } + ], + "key.typename" : "Result.Type", + "key.typeusr" : "$ss6ResultOyxq_GmD", + "key.usr" : "s:s6ResultO" + } + ] + } +}, { + "\/Sources\/Commandant\/Switch.swift" : { + "key.diagnostic_stage" : "source.diagnostic.stage.swift.parse", + "key.length" : 2007, + "key.offset" : 0, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public struct Switch<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 375 + } + ], + "key.bodylength" : 724, + "key.bodyoffset" : 397, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Describes a parameterless command line flag that defaults to false and can only\nbe switched on. Canonical examples include `--force` and `--recurse`.\n\nFor a boolean toggle that can be enabled and disabled use `Option`.", + "key.doc.column" : 15, + "key.doc.comment" : "Describes a parameterless command line flag that defaults to false and can only\nbe switched on. Canonical examples include `--force` and `--recurse`.\n\nFor a boolean toggle that can be enabled and disabled use `Option`.", + "key.doc.declaration" : "public struct Switch", + "key.doc.discussion" : [ + { + "Para" : "For a boolean toggle that can be enabled and disabled use `Option`." + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Switch.swift", + "key.doc.full_as_xml" : "Switch<\/Name>s:10Commandant6SwitchV<\/USR>public struct Switch<\/Declaration>Describes a parameterless command line flag that defaults to false and can only be switched on. Canonical examples include --force<\/codeVoice> and --recurse<\/codeVoice>.<\/Para><\/Abstract>For a boolean toggle that can be enabled and disabled use Option<Bool><\/codeVoice>.<\/Para><\/Discussion><\/CommentParts><\/Class>", + "key.doc.line" : 13, + "key.doc.name" : "Switch", + "key.doc.type" : "Class", + "key.doclength" : 240, + "key.docoffset" : 135, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> struct<\/syntaxtype.keyword> Switch<\/decl.name><\/decl.struct>", + "key.kind" : "source.lang.swift.decl.struct", + "key.length" : 740, + "key.line" : 13, + "key.modulename" : "Commandant", + "key.name" : "Switch", + "key.namelength" : 6, + "key.nameoffset" : 389, + "key.offset" : 382, + "key.parsed_declaration" : "public struct Switch", + "key.parsed_scope.end" : 34, + "key.parsed_scope.start" : 13, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public let key: String<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 515 + } + ], + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "The key that enables this switch. For example, a key of `verbose` would be\nused for a `--verbose` option.", + "key.doc.column" : 13, + "key.doc.comment" : "The key that enables this switch. For example, a key of `verbose` would be\nused for a `--verbose` option.", + "key.doc.declaration" : "public let key: String", + "key.doc.file" : "\/private\/Sources\/Commandant\/Switch.swift", + "key.doc.full_as_xml" : "key<\/Name>s:10Commandant6SwitchV3keySSvp<\/USR>public let key: String<\/Declaration>The key that enables this switch. For example, a key of verbose<\/codeVoice> would be used for a --verbose<\/codeVoice> option.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 16, + "key.doc.name" : "key", + "key.doc.type" : "Other", + "key.doclength" : 115, + "key.docoffset" : 399, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> let<\/syntaxtype.keyword> key<\/decl.name>: String<\/ref.struct><\/decl.var.type><\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 15, + "key.line" : 16, + "key.modulename" : "Commandant", + "key.name" : "key", + "key.namelength" : 3, + "key.nameoffset" : 526, + "key.offset" : 522, + "key.parsed_declaration" : "public let key: String", + "key.parsed_scope.end" : 16, + "key.parsed_scope.start" : 16, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant6SwitchV3keySSvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public let flag: Character<\/Type>?<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 828 + } + ], + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Optional single letter flag that enables this switch. For example, `-v` would\nbe used as a shorthand for `--verbose`.\n\nMultiple flags can be grouped together as a single argument and will split\nwhen parsing (e.g. `rm -rf` treats 'r' and 'f' as inidividual flags).", + "key.doc.column" : 13, + "key.doc.comment" : "Optional single letter flag that enables this switch. For example, `-v` would\nbe used as a shorthand for `--verbose`.\n\nMultiple flags can be grouped together as a single argument and will split\nwhen parsing (e.g. `rm -rf` treats 'r' and 'f' as inidividual flags).", + "key.doc.declaration" : "public let flag: Character?", + "key.doc.discussion" : [ + { + "Para" : "Multiple flags can be grouped together as a single argument and will split when parsing (e.g. `rm -rf` treats ‘r’ and ‘f’ as inidividual flags)." + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Switch.swift", + "key.doc.full_as_xml" : "flag<\/Name>s:10Commandant6SwitchV4flagSJSgvp<\/USR>public let flag: Character?<\/Declaration>Optional single letter flag that enables this switch. For example, -v<\/codeVoice> would be used as a shorthand for --verbose<\/codeVoice>.<\/Para><\/Abstract>Multiple flags can be grouped together as a single argument and will split when parsing (e.g. rm -rf<\/codeVoice> treats ‘r’ and ‘f’ as inidividual flags).<\/Para><\/Discussion><\/CommentParts><\/Other>", + "key.doc.line" : 23, + "key.doc.name" : "flag", + "key.doc.type" : "Other", + "key.doclength" : 287, + "key.docoffset" : 540, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> let<\/syntaxtype.keyword> flag<\/decl.name>: Character<\/ref.struct>?<\/decl.var.type><\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 20, + "key.line" : 23, + "key.modulename" : "Commandant", + "key.name" : "flag", + "key.namelength" : 4, + "key.nameoffset" : 839, + "key.offset" : 835, + "key.parsed_declaration" : "public let flag: Character?", + "key.parsed_scope.end" : 23, + "key.parsed_scope.start" : 23, + "key.reusingastcontext" : false, + "key.typename" : "Character?", + "key.typeusr" : "$sSJSgD", + "key.usr" : "s:10Commandant6SwitchV4flagSJSgvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public let usage: String<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 968 + } + ], + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A human-readable string describing the purpose of this option. This will\nbe shown in help messages.", + "key.doc.column" : 13, + "key.doc.comment" : "A human-readable string describing the purpose of this option. This will\nbe shown in help messages.", + "key.doc.declaration" : "public let usage: String", + "key.doc.file" : "\/private\/Sources\/Commandant\/Switch.swift", + "key.doc.full_as_xml" : "usage<\/Name>s:10Commandant6SwitchV5usageSSvp<\/USR>public let usage: String<\/Declaration>A human-readable string describing the purpose of this option. This will be shown in help messages.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 27, + "key.doc.name" : "usage", + "key.doc.type" : "Other", + "key.doclength" : 109, + "key.docoffset" : 858, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> let<\/syntaxtype.keyword> usage<\/decl.name>: String<\/ref.struct><\/decl.var.type><\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 17, + "key.line" : 27, + "key.modulename" : "Commandant", + "key.name" : "usage", + "key.namelength" : 5, + "key.nameoffset" : 979, + "key.offset" : 975, + "key.parsed_declaration" : "public let usage: String", + "key.parsed_scope.end" : 27, + "key.parsed_scope.start" : 27, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant6SwitchV5usageSSvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public init(flag: Character<\/Type>? = nil, key: String<\/Type>, usage: String<\/Type>)<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 995 + } + ], + "key.bodylength" : 59, + "key.bodyoffset" : 1060, + "key.column" : 9, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> init<\/syntaxtype.keyword>(flag<\/decl.var.parameter.argument_label>: Character<\/ref.struct>?<\/decl.var.parameter.type> = nil<\/decl.var.parameter>, key<\/decl.var.parameter.argument_label>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>, usage<\/decl.var.parameter.argument_label>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>)<\/decl.function.constructor>", + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 118, + "key.line" : 29, + "key.modulename" : "Commandant", + "key.name" : "init(flag:key:usage:)", + "key.namelength" : 56, + "key.nameoffset" : 1002, + "key.offset" : 1002, + "key.parsed_declaration" : "public init(flag: Character? = nil, key: String, usage: String)", + "key.parsed_scope.end" : 33, + "key.parsed_scope.start" : 29, + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : "(Switch.Type) -> (Character?, String, String) -> Switch", + "key.typeusr" : "$s4flag3key5usage10Commandant6SwitchVSJSg_S2StcD", + "key.usr" : "s:10Commandant6SwitchV4flag3key5usageACSJSg_S2Stcfc" + } + ], + "key.typename" : "Switch.Type", + "key.typeusr" : "$s10Commandant6SwitchVmD", + "key.usr" : "s:10Commandant6SwitchV" + }, + { + "key.annotated_decl" : "public struct Switch<\/Declaration>", + "key.bodylength" : 140, + "key.bodyoffset" : 1167, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Describes a parameterless command line flag that defaults to false and can only\nbe switched on. Canonical examples include `--force` and `--recurse`.\n\nFor a boolean toggle that can be enabled and disabled use `Option`.", + "key.doc.column" : 15, + "key.doc.declaration" : "public struct Switch", + "key.doc.discussion" : [ + { + "Para" : "For a boolean toggle that can be enabled and disabled use `Option`." + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Switch.swift", + "key.doc.full_as_xml" : "Switch<\/Name>s:10Commandant6SwitchV<\/USR>public struct Switch<\/Declaration>Describes a parameterless command line flag that defaults to false and can only be switched on. Canonical examples include --force<\/codeVoice> and --recurse<\/codeVoice>.<\/Para><\/Abstract>For a boolean toggle that can be enabled and disabled use Option<Bool><\/codeVoice>.<\/Para><\/Discussion><\/CommentParts><\/Class>", + "key.doc.line" : 13, + "key.doc.name" : "Switch", + "key.doc.type" : "Class", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 23, + "key.offset" : 1142 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> struct<\/syntaxtype.keyword> Switch<\/decl.name><\/decl.struct>", + "key.inheritedtypes" : [ + { + "key.name" : "CustomStringConvertible" + } + ], + "key.kind" : "source.lang.swift.decl.extension", + "key.length" : 184, + "key.line" : 13, + "key.modulename" : "Commandant", + "key.name" : "Switch", + "key.namelength" : 6, + "key.nameoffset" : 1134, + "key.offset" : 1124, + "key.parsed_declaration" : "extension Switch: CustomStringConvertible", + "key.parsed_scope.end" : 44, + "key.parsed_scope.start" : 36, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public var description: String<\/Type> { get }<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 1169 + } + ], + "key.bodylength" : 104, + "key.bodyoffset" : 1201, + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A textual representation of this instance.\n\nCalling this property directly is discouraged. Instead, convert an\ninstance of any type to a string by using the `String(describing:)`\ninitializer. This initializer works with any type, and uses the custom\n`description` property for types that conform to\n`CustomStringConvertible`:\n\n struct Point: CustomStringConvertible {\n let x: Int, y: Int\n\n var description: String {\n return \"(\\(x), \\(y))\"\n }\n }\n\n let p = Point(x: 21, y: 30)\n let s = String(describing: p)\n print(s)\n \/\/ Prints \"(21, 30)\"\n\nThe conversion of `p` to a string in the assignment to `s` uses the\n`Point` type's `description` property.", + "key.doc.declaration" : "var description: String { get }", + "key.doc.discussion" : [ + { + "Para" : "Calling this property directly is discouraged. Instead, convert an instance of any type to a string by using the `String(describing:)` initializer. This initializer works with any type, and uses the custom `description` property for types that conform to `CustomStringConvertible`:" + }, + { + "CodeListing" : "" + }, + { + "Para" : "The conversion of `p` to a string in the assignment to `s` uses the `Point` type’s `description` property." + }, + { + "Note" : "" + } + ], + "key.doc.full_as_xml" : "description<\/Name>s:s23CustomStringConvertibleP11descriptionSSvp<\/USR>var description: String { get }<\/Declaration>A textual representation of this instance.<\/Para><\/Abstract>Calling this property directly is discouraged. Instead, convert an instance of any type to a string by using the String(describing:)<\/codeVoice> initializer. This initializer works with any type, and uses the custom description<\/codeVoice> property for types that conform to CustomStringConvertible<\/codeVoice>:<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>The conversion of p<\/codeVoice> to a string in the assignment to s<\/codeVoice> uses the Point<\/codeVoice> type’s description<\/codeVoice> property.<\/Para>This documentation comment was inherited from CustomStringConvertible<\/codeVoice>.<\/Para><\/Note><\/Discussion><\/CommentParts><\/Other>", + "key.doc.name" : "description", + "key.doc.type" : "Other", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> var<\/syntaxtype.keyword> description<\/decl.name>: String<\/ref.struct><\/decl.var.type> { get<\/syntaxtype.keyword> }<\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 130, + "key.line" : 37, + "key.modulename" : "Commandant", + "key.name" : "description", + "key.namelength" : 11, + "key.nameoffset" : 1180, + "key.offset" : 1176, + "key.overrides" : [ + { + "key.usr" : "s:s23CustomStringConvertibleP11descriptionSSvp" + } + ], + "key.parsed_declaration" : "public var description: String", + "key.parsed_scope.end" : 43, + "key.parsed_scope.start" : 37, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:s23CustomStringConvertibleP11descriptionSSvp" + }, + { + "key.annotated_decl" : "var options: String<\/Type><\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "var<\/syntaxtype.keyword> options<\/decl.name>: String<\/ref.struct><\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 24, + "key.line" : 38, + "key.modulename" : "Commandant", + "key.name" : "options", + "key.namelength" : 7, + "key.nameoffset" : 1208, + "key.offset" : 1204, + "key.parsed_declaration" : "var options = \"--\\(key)\"", + "key.parsed_scope.end" : 38, + "key.parsed_scope.start" : 38, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant6SwitchV11descriptionSSvg7optionsL_SSvp" + } + ], + "key.typename" : "Switch.Type", + "key.typeusr" : "$s10Commandant6SwitchVmD", + "key.usr" : "s:10Commandant6SwitchV" + }, + { + "key.kind" : "source.lang.swift.syntaxtype.comment.mark", + "key.length" : 17, + "key.name" : "MARK: - Operators", + "key.offset" : 1313 + }, + { + "key.annotated_decl" : "public enum CommandMode<\/Declaration>", + "key.bodylength" : 650, + "key.bodyoffset" : 1355, + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Describes the \"mode\" in which a command should run.", + "key.doc.column" : 13, + "key.doc.declaration" : "public enum CommandMode", + "key.doc.file" : "\/private\/Sources\/Commandant\/Command.swift", + "key.doc.full_as_xml" : "CommandMode<\/Name>s:10Commandant11CommandModeO<\/USR>public enum CommandMode<\/Declaration>Describes the “mode” in which a command should run.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 68, + "key.doc.name" : "CommandMode", + "key.doc.type" : "Other", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> enum<\/syntaxtype.keyword> CommandMode<\/decl.name><\/decl.enum>", + "key.kind" : "source.lang.swift.decl.extension", + "key.length" : 674, + "key.line" : 68, + "key.modulename" : "Commandant", + "key.name" : "CommandMode", + "key.namelength" : 11, + "key.nameoffset" : 1342, + "key.offset" : 1332, + "key.parsed_declaration" : "extension CommandMode", + "key.parsed_scope.end" : 67, + "key.parsed_scope.start" : 48, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public static func <| <ClientError>(mode: CommandMode<\/Type>, option: Switch<\/Type>) -> Result<\/Type><Bool<\/Type>, CommandantError<\/Type><ClientError<\/Type>>><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 1551 + } + ], + "key.bodylength" : 333, + "key.bodyoffset" : 1670, + "key.column" : 21, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Evaluates the given boolean switch in the given mode.\n\nIf parsing command line arguments, and no value was specified on the command\nline, the option's `defaultValue` is used.", + "key.doc.column" : 21, + "key.doc.comment" : "Evaluates the given boolean switch in the given mode.\n\nIf parsing command line arguments, and no value was specified on the command\nline, the option's `defaultValue` is used.", + "key.doc.declaration" : "public static func <| (mode: CommandMode, option: Switch) -> Result>", + "key.doc.discussion" : [ + { + "Para" : "If parsing command line arguments, and no value was specified on the command line, the option’s `defaultValue` is used." + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Switch.swift", + "key.doc.full_as_xml" : "<|(_:_:)<\/Name>s:10Commandant11CommandModeO2looiys6ResultOySbAA0A5ErrorOyxGGAC_AA6SwitchVtlFZ<\/USR>public static func <| <ClientError>(mode: CommandMode, option: Switch) -> Result<Bool, CommandantError<ClientError>><\/Declaration>Evaluates the given boolean switch in the given mode.<\/Para><\/Abstract>If parsing command line arguments, and no value was specified on the command line, the option’s defaultValue<\/codeVoice> is used.<\/Para><\/Discussion><\/CommentParts><\/Function>", + "key.doc.line" : 53, + "key.doc.name" : "<|(_:_:)", + "key.doc.type" : "Function", + "key.doclength" : 193, + "key.docoffset" : 1357, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> static<\/syntaxtype.keyword> func<\/syntaxtype.keyword> <| <\/decl.name><ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>>(mode<\/decl.var.parameter.name>: CommandMode<\/ref.enum><\/decl.var.parameter.type><\/decl.var.parameter>, option<\/decl.var.parameter.name>: Switch<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>) -> Result<\/ref.enum><Bool<\/ref.struct>, CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>>><\/decl.function.returntype><\/decl.function.operator.infix>", + "key.kind" : "source.lang.swift.decl.function.method.static", + "key.length" : 446, + "key.line" : 53, + "key.modulename" : "Commandant", + "key.name" : "<|(_:_:)", + "key.namelength" : 52, + "key.nameoffset" : 1570, + "key.offset" : 1558, + "key.parsed_declaration" : "public static func <| (mode: CommandMode, option: Switch) -> Result>", + "key.parsed_scope.end" : 66, + "key.parsed_scope.start" : 53, + "key.related_decls" : [ + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Argument<T>) -> Result<T, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Argument<[T]>) -> Result<[T], CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<T>) -> Result<T, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<T?>) -> Result<T?, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<[T]>) -> Result<[T], CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<[T]?>) -> Result<[T]?, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <ClientError>(_: CommandMode, _: Option<Bool>) -> Result<Bool, CommandantError<ClientError>><\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "ClientError<\/Declaration>", + "key.column" : 25, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 53, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 1574, + "key.offset" : 1574, + "key.parsed_declaration" : "public static func <| (CommandMode.Type) -> (CommandMode, Switch) -> Result>", + "key.typeusr" : "$sys6ResultOySb10Commandant0B5ErrorOyxGGAC11CommandModeO_AC6SwitchVtcluD", + "key.usr" : "s:10Commandant11CommandModeO2looiys6ResultOySbAA0A5ErrorOyxGGAC_AA6SwitchVtlFZ" + } + ], + "key.typename" : "CommandMode.Type", + "key.typeusr" : "$s10Commandant11CommandModeOmD", + "key.usr" : "s:10Commandant11CommandModeO" + } + ] + } +}] \ No newline at end of file diff --git a/Tests/SourceKittenFrameworkTests/Fixtures/CommandantSPM@swift-6.0.json b/Tests/SourceKittenFrameworkTests/Fixtures/CommandantSPM@swift-6.0.json new file mode 100644 index 00000000..f2adfdeb --- /dev/null +++ b/Tests/SourceKittenFrameworkTests/Fixtures/CommandantSPM@swift-6.0.json @@ -0,0 +1,9220 @@ +[{ + "\/Sources\/Commandant\/Argument.swift" : { + "key.diagnostic_stage" : "source.diagnostic.stage.swift.parse", + "key.length" : 3858, + "key.offset" : 0, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public struct Argument<T><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 204 + } + ], + "key.bodylength" : 1029, + "key.bodyoffset" : 231, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Describes an argument that can be provided on the command line.", + "key.doc.column" : 15, + "key.doc.comment" : "Describes an argument that can be provided on the command line.", + "key.doc.declaration" : "public struct Argument", + "key.doc.file" : "\/private\/Sources\/Commandant\/Argument.swift", + "key.doc.full_as_xml" : "Argument<\/Name>s:10Commandant8ArgumentV<\/USR>public struct Argument<T><\/Declaration>Describes an argument that can be provided on the command line.<\/Para><\/Abstract><\/CommentParts><\/Class>", + "key.doc.line" : 10, + "key.doc.name" : "Argument", + "key.doc.type" : "Class", + "key.doclength" : 68, + "key.docoffset" : 136, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> struct<\/syntaxtype.keyword> Argument<\/decl.name><T<\/decl.generic_type_param.name><\/decl.generic_type_param>><\/decl.struct>", + "key.kind" : "source.lang.swift.decl.struct", + "key.length" : 1050, + "key.line" : 10, + "key.modulename" : "Commandant", + "key.name" : "Argument", + "key.namelength" : 8, + "key.nameoffset" : 218, + "key.offset" : 211, + "key.parsed_declaration" : "public struct Argument", + "key.parsed_scope.end" : 36, + "key.parsed_scope.start" : 10, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "T<\/Declaration>", + "key.column" : 24, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "T<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 1, + "key.line" : 10, + "key.modulename" : "Commandant", + "key.name" : "T", + "key.namelength" : 1, + "key.nameoffset" : 227, + "key.offset" : 227, + "key.parsed_declaration" : "public struct Argumentpublic let defaultValue: T<\/Type>?<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 443 + } + ], + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "The default value for this argument. This is the value that will be used\nif the argument is never explicitly specified on the command line.\n\nIf this is nil, this argument is always required.", + "key.doc.column" : 13, + "key.doc.comment" : "The default value for this argument. This is the value that will be used\nif the argument is never explicitly specified on the command line.\n\nIf this is nil, this argument is always required.", + "key.doc.declaration" : "public let defaultValue: T?", + "key.doc.discussion" : [ + { + "Para" : "If this is nil, this argument is always required." + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Argument.swift", + "key.doc.full_as_xml" : "defaultValue<\/Name>s:10Commandant8ArgumentV12defaultValuexSgvp<\/USR>public let defaultValue: T?<\/Declaration>The default value for this argument. This is the value that will be used if the argument is never explicitly specified on the command line.<\/Para><\/Abstract>If this is nil, this argument is always required.<\/Para><\/Discussion><\/CommentParts><\/Other>", + "key.doc.line" : 15, + "key.doc.name" : "defaultValue", + "key.doc.type" : "Other", + "key.doclength" : 209, + "key.docoffset" : 233, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> let<\/syntaxtype.keyword> defaultValue<\/decl.name>: T<\/ref.generic_type_param>?<\/decl.var.type><\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 20, + "key.line" : 15, + "key.modulename" : "Commandant", + "key.name" : "defaultValue", + "key.namelength" : 12, + "key.nameoffset" : 454, + "key.offset" : 450, + "key.parsed_declaration" : "public let defaultValue: T?", + "key.parsed_scope.end" : 15, + "key.parsed_scope.start" : 15, + "key.reusingastcontext" : false, + "key.typename" : "T?", + "key.typeusr" : "$sxSgD", + "key.usr" : "s:10Commandant8ArgumentV12defaultValuexSgvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public let usage: String<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 585 + } + ], + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A human-readable string describing the purpose of this argument. This will\nbe shown in help messages.", + "key.doc.column" : 13, + "key.doc.comment" : "A human-readable string describing the purpose of this argument. This will\nbe shown in help messages.", + "key.doc.declaration" : "public let usage: String", + "key.doc.file" : "\/private\/Sources\/Commandant\/Argument.swift", + "key.doc.full_as_xml" : "usage<\/Name>s:10Commandant8ArgumentV5usageSSvp<\/USR>public let usage: String<\/Declaration>A human-readable string describing the purpose of this argument. This will be shown in help messages.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 19, + "key.doc.name" : "usage", + "key.doc.type" : "Other", + "key.doclength" : 111, + "key.docoffset" : 473, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> let<\/syntaxtype.keyword> usage<\/decl.name>: String<\/ref.struct><\/decl.var.type><\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 17, + "key.line" : 19, + "key.modulename" : "Commandant", + "key.name" : "usage", + "key.namelength" : 5, + "key.nameoffset" : 596, + "key.offset" : 592, + "key.parsed_declaration" : "public let usage: String", + "key.parsed_scope.end" : 19, + "key.parsed_scope.start" : 19, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant8ArgumentV5usageSSvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public let usageParameter: String<\/Type>?<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 804 + } + ], + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A human-readable string that describes this argument as a paramater shown\nin the list of possible parameters in help messages (e.g. for \"paths\", the\nuser would see ).", + "key.doc.column" : 13, + "key.doc.comment" : "A human-readable string that describes this argument as a paramater shown\nin the list of possible parameters in help messages (e.g. for \"paths\", the\nuser would see ).", + "key.doc.declaration" : "public let usageParameter: String?", + "key.doc.file" : "\/private\/Sources\/Commandant\/Argument.swift", + "key.doc.full_as_xml" : "usageParameter<\/Name>s:10Commandant8ArgumentV14usageParameterSSSgvp<\/USR>public let usageParameter: String?<\/Declaration>A human-readable string that describes this argument as a paramater shown in the list of possible parameters in help messages (e.g. for “paths”, the user would see <paths…>).<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 24, + "key.doc.name" : "usageParameter", + "key.doc.type" : "Other", + "key.doclength" : 191, + "key.docoffset" : 612, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> let<\/syntaxtype.keyword> usageParameter<\/decl.name>: String<\/ref.struct>?<\/decl.var.type><\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 27, + "key.line" : 24, + "key.modulename" : "Commandant", + "key.name" : "usageParameter", + "key.namelength" : 14, + "key.nameoffset" : 815, + "key.offset" : 811, + "key.parsed_declaration" : "public let usageParameter: String?", + "key.parsed_scope.end" : 24, + "key.parsed_scope.start" : 24, + "key.reusingastcontext" : false, + "key.typename" : "String?", + "key.typeusr" : "$sSSSgD", + "key.usr" : "s:10Commandant8ArgumentV14usageParameterSSSgvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public init(defaultValue: T<\/Type>? = nil, usage: String<\/Type>, usageParameter: String<\/Type>? = nil)<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 841 + } + ], + "key.bodylength" : 97, + "key.bodyoffset" : 924, + "key.column" : 9, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> init<\/syntaxtype.keyword>(defaultValue<\/decl.var.parameter.argument_label>: T<\/ref.generic_type_param>?<\/decl.var.parameter.type> = nil<\/decl.var.parameter>, usage<\/decl.var.parameter.argument_label>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>, usageParameter<\/decl.var.parameter.argument_label>: String<\/ref.struct>?<\/decl.var.parameter.type> = nil<\/decl.var.parameter>)<\/decl.function.constructor>", + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 174, + "key.line" : 26, + "key.modulename" : "Commandant", + "key.name" : "init(defaultValue:usage:usageParameter:)", + "key.namelength" : 74, + "key.nameoffset" : 848, + "key.offset" : 848, + "key.parsed_declaration" : "public init(defaultValue: T? = nil, usage: String, usageParameter: String? = nil)", + "key.parsed_scope.end" : 30, + "key.parsed_scope.start" : 26, + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : " (Argument.Type) -> (T?, String, String?) -> Argument", + "key.typeusr" : "$s12defaultValue5usage0C9Parameter10Commandant8ArgumentVyxGxSg_S2SSgtcD", + "key.usr" : "s:10Commandant8ArgumentV12defaultValue5usage0E9ParameterACyxGxSg_S2SSgtcfc" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.fileprivate", + "key.annotated_decl" : "fileprivate func invalidUsageError<ClientError>(_ value: String<\/Type>) -> CommandantError<\/Type><ClientError<\/Type>><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.fileprivate", + "key.length" : 11, + "key.offset" : 1025 + } + ], + "key.bodylength" : 135, + "key.bodyoffset" : 1123, + "key.column" : 19, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "fileprivate<\/syntaxtype.keyword> func<\/syntaxtype.keyword> invalidUsageError<\/decl.name><ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>>(_<\/decl.var.parameter.argument_label> value<\/decl.var.parameter.name>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>) -> CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>><\/decl.function.returntype><\/decl.function.method.instance>", + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 222, + "key.line" : 32, + "key.modulename" : "Commandant", + "key.name" : "invalidUsageError(_:)", + "key.namelength" : 47, + "key.nameoffset" : 1042, + "key.offset" : 1037, + "key.parsed_declaration" : "fileprivate func invalidUsageError(_ value: String) -> CommandantError", + "key.parsed_scope.end" : 35, + "key.parsed_scope.start" : 32, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "ClientError<\/Declaration>", + "key.column" : 37, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 32, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 1060, + "key.offset" : 1060, + "key.parsed_declaration" : "fileprivate func invalidUsageErrorlet description: String<\/Type><\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "let<\/syntaxtype.keyword> description<\/decl.name>: String<\/ref.struct><\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 83, + "key.line" : 33, + "key.modulename" : "Commandant", + "key.name" : "description", + "key.namelength" : 11, + "key.nameoffset" : 1130, + "key.offset" : 1126, + "key.parsed_declaration" : "let description = \"Invalid value for '\\(self.usageParameterDescription)': \\(value)\"", + "key.parsed_scope.end" : 33, + "key.parsed_scope.start" : 33, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant8ArgumentV17invalidUsageError33_8CAE711C2CD19D07FEBBE5F857AB09FDLLyAA0aE0Oyqd__GSSlF11descriptionL_SSvp" + } + ], + "key.typename" : " (Argument) -> (String) -> CommandantError", + "key.typeusr" : "$sy10Commandant0A5ErrorOyqd__GSScluD", + "key.usr" : "s:10Commandant8ArgumentV17invalidUsageError33_8CAE711C2CD19D07FEBBE5F857AB09FDLLyAA0aE0Oyqd__GSSlF" + } + ], + "key.typename" : "Argument.Type", + "key.typeusr" : "$s10Commandant8ArgumentVyxGmD", + "key.usr" : "s:10Commandant8ArgumentV" + }, + { + "key.annotated_decl" : "public struct Argument<T><\/Declaration>", + "key.bodylength" : 251, + "key.bodyoffset" : 1283, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Describes an argument that can be provided on the command line.", + "key.doc.column" : 15, + "key.doc.declaration" : "public struct Argument", + "key.doc.file" : "\/private\/Sources\/Commandant\/Argument.swift", + "key.doc.full_as_xml" : "Argument<\/Name>s:10Commandant8ArgumentV<\/USR>public struct Argument<T><\/Declaration>Describes an argument that can be provided on the command line.<\/Para><\/Abstract><\/CommentParts><\/Class>", + "key.doc.line" : 10, + "key.doc.name" : "Argument", + "key.doc.type" : "Class", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> struct<\/syntaxtype.keyword> Argument<\/decl.name><T<\/decl.generic_type_param.name><\/decl.generic_type_param>><\/decl.struct>", + "key.kind" : "source.lang.swift.decl.extension", + "key.length" : 272, + "key.line" : 10, + "key.modulename" : "Commandant", + "key.name" : "Argument", + "key.namelength" : 8, + "key.nameoffset" : 1273, + "key.offset" : 1263, + "key.parsed_declaration" : "extension Argument", + "key.parsed_scope.end" : 44, + "key.parsed_scope.start" : 38, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "internal var usageParameterDescription: String<\/Type> { get }<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.internal", + "key.length" : 8, + "key.offset" : 1422 + } + ], + "key.bodylength" : 62, + "key.bodyoffset" : 1470, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A string describing this argument as a parameter in help messages. This falls back\nto `\"\\(self)\"` if `usageParameter` is `nil`", + "key.doc.column" : 15, + "key.doc.comment" : "A string describing this argument as a parameter in help messages. This falls back\nto `\"\\(self)\"` if `usageParameter` is `nil`", + "key.doc.declaration" : "internal var usageParameterDescription: String { get }", + "key.doc.file" : "\/private\/Sources\/Commandant\/Argument.swift", + "key.doc.full_as_xml" : "usageParameterDescription<\/Name>s:10Commandant8ArgumentV25usageParameterDescriptionSSvp<\/USR>internal var usageParameterDescription: String { get }<\/Declaration>A string describing this argument as a parameter in help messages. This falls back to "\\(self)"<\/codeVoice> if usageParameter<\/codeVoice> is nil<\/codeVoice><\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 41, + "key.doc.name" : "usageParameterDescription", + "key.doc.type" : "Other", + "key.doclength" : 136, + "key.docoffset" : 1285, + "key.filepath" : "", + "key.fully_annotated_decl" : "internal<\/syntaxtype.keyword> var<\/syntaxtype.keyword> usageParameterDescription<\/decl.name>: String<\/ref.struct><\/decl.var.type> { get<\/syntaxtype.keyword> }<\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 102, + "key.line" : 41, + "key.modulename" : "Commandant", + "key.name" : "usageParameterDescription", + "key.namelength" : 25, + "key.nameoffset" : 1435, + "key.offset" : 1431, + "key.parsed_declaration" : "internal var usageParameterDescription: String", + "key.parsed_scope.end" : 43, + "key.parsed_scope.start" : 41, + "key.related_decls" : [ + { + "key.annotated_decl" : "usageParameterDescription<\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant8ArgumentV25usageParameterDescriptionSSvp" + } + ], + "key.typename" : "Argument.Type", + "key.typeusr" : "$s10Commandant8ArgumentVyxGmD", + "key.usr" : "s:10Commandant8ArgumentV" + }, + { + "key.annotated_decl" : "public struct Argument<T><\/Declaration>", + "key.bodylength" : 254, + "key.bodyoffset" : 1575, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Describes an argument that can be provided on the command line.", + "key.doc.column" : 15, + "key.doc.declaration" : "public struct Argument", + "key.doc.file" : "\/private\/Sources\/Commandant\/Argument.swift", + "key.doc.full_as_xml" : "Argument<\/Name>s:10Commandant8ArgumentV<\/USR>public struct Argument<T><\/Declaration>Describes an argument that can be provided on the command line.<\/Para><\/Abstract><\/CommentParts><\/Class>", + "key.doc.line" : 10, + "key.doc.name" : "Argument", + "key.doc.type" : "Class", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> struct<\/syntaxtype.keyword> Argument<\/decl.name><T<\/decl.generic_type_param.name><\/decl.generic_type_param>><\/decl.struct>", + "key.kind" : "source.lang.swift.decl.extension", + "key.length" : 293, + "key.line" : 10, + "key.modulename" : "Commandant", + "key.name" : "Argument", + "key.namelength" : 8, + "key.nameoffset" : 1547, + "key.offset" : 1537, + "key.parsed_declaration" : "extension Argument where T: Sequence", + "key.parsed_scope.end" : 52, + "key.parsed_scope.start" : 46, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "internal var usageParameterDescription: String<\/Type> { get }<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.internal", + "key.length" : 8, + "key.offset" : 1714 + } + ], + "key.bodylength" : 65, + "key.bodyoffset" : 1762, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A string describing this argument as a parameter in help messages. This falls back\nto `\"\\(self)\"` if `usageParameter` is `nil`", + "key.doc.column" : 15, + "key.doc.comment" : "A string describing this argument as a parameter in help messages. This falls back\nto `\"\\(self)\"` if `usageParameter` is `nil`", + "key.doc.declaration" : "internal var usageParameterDescription: String { get }", + "key.doc.file" : "\/private\/Sources\/Commandant\/Argument.swift", + "key.doc.full_as_xml" : "usageParameterDescription<\/Name>s:10Commandant8ArgumentVAASTRzlE25usageParameterDescriptionSSvp<\/USR>internal var usageParameterDescription: String { get }<\/Declaration>A string describing this argument as a parameter in help messages. This falls back to "\\(self)"<\/codeVoice> if usageParameter<\/codeVoice> is nil<\/codeVoice><\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 49, + "key.doc.name" : "usageParameterDescription", + "key.doc.type" : "Other", + "key.doclength" : 136, + "key.docoffset" : 1577, + "key.filepath" : "", + "key.fully_annotated_decl" : "internal<\/syntaxtype.keyword> var<\/syntaxtype.keyword> usageParameterDescription<\/decl.name>: String<\/ref.struct><\/decl.var.type> { get<\/syntaxtype.keyword> }<\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 105, + "key.line" : 49, + "key.modulename" : "Commandant", + "key.name" : "usageParameterDescription", + "key.namelength" : 25, + "key.nameoffset" : 1727, + "key.offset" : 1723, + "key.parsed_declaration" : "internal var usageParameterDescription: String", + "key.parsed_scope.end" : 51, + "key.parsed_scope.start" : 49, + "key.related_decls" : [ + { + "key.annotated_decl" : "usageParameterDescription<\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant8ArgumentVAASTRzlE25usageParameterDescriptionSSvp" + } + ], + "key.typename" : "Argument.Type", + "key.typeusr" : "$s10Commandant8ArgumentVyxGmD", + "key.usr" : "s:10Commandant8ArgumentV" + }, + { + "key.kind" : "source.lang.swift.syntaxtype.comment.mark", + "key.length" : 17, + "key.name" : "MARK: - Operators", + "key.offset" : 1835 + }, + { + "key.annotated_decl" : "public enum CommandMode<\/Declaration>", + "key.bodylength" : 1979, + "key.bodyoffset" : 1877, + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Describes the \"mode\" in which a command should run.", + "key.doc.column" : 13, + "key.doc.declaration" : "public enum CommandMode", + "key.doc.file" : "\/private\/Sources\/Commandant\/Command.swift", + "key.doc.full_as_xml" : "CommandMode<\/Name>s:10Commandant11CommandModeO<\/USR>public enum CommandMode<\/Declaration>Describes the “mode” in which a command should run.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 68, + "key.doc.name" : "CommandMode", + "key.doc.type" : "Other", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> enum<\/syntaxtype.keyword> CommandMode<\/decl.name><\/decl.enum>", + "key.kind" : "source.lang.swift.decl.extension", + "key.length" : 2003, + "key.line" : 68, + "key.modulename" : "Commandant", + "key.name" : "CommandMode", + "key.namelength" : 11, + "key.nameoffset" : 1864, + "key.offset" : 1854, + "key.parsed_declaration" : "extension CommandMode", + "key.parsed_scope.end" : 120, + "key.parsed_scope.start" : 56, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public static func <| <T, ClientError>(mode: CommandMode<\/Type>, argument: Argument<\/Type><T<\/Type>>) -> Result<\/Type><T<\/Type>, CommandantError<\/Type><ClientError<\/Type>>> where T<\/Type> : ArgumentProtocol<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 2069 + } + ], + "key.bodylength" : 518, + "key.bodyoffset" : 2212, + "key.column" : 21, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Evaluates the given argument in the given mode.\n\nIf parsing command line arguments, and no value was specified on the command\nline, the argument's `defaultValue` is used.", + "key.doc.column" : 21, + "key.doc.comment" : "Evaluates the given argument in the given mode.\n\nIf parsing command line arguments, and no value was specified on the command\nline, the argument's `defaultValue` is used.", + "key.doc.declaration" : "public static func <| (mode: CommandMode, argument: Argument) -> Result> where T : Commandant.ArgumentProtocol", + "key.doc.discussion" : [ + { + "Para" : "If parsing command line arguments, and no value was specified on the command line, the argument’s `defaultValue` is used." + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Argument.swift", + "key.doc.full_as_xml" : "<|(_:_:)<\/Name>s:10Commandant11CommandModeO2looiys6ResultOyxAA0A5ErrorOyq_GGAC_AA8ArgumentVyxGtAA0G8ProtocolRzr0_lFZ<\/USR>public static func <| <T, ClientError>(mode: CommandMode, argument: Argument<T>) -> Result<T, CommandantError<ClientError>> where T : Commandant.ArgumentProtocol<\/Declaration>Evaluates the given argument in the given mode.<\/Para><\/Abstract>If parsing command line arguments, and no value was specified on the command line, the argument’s defaultValue<\/codeVoice> is used.<\/Para><\/Discussion><\/CommentParts><\/Function>", + "key.doc.line" : 61, + "key.doc.name" : "<|(_:_:)", + "key.doc.type" : "Function", + "key.doclength" : 189, + "key.docoffset" : 1879, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> static<\/syntaxtype.keyword> func<\/syntaxtype.keyword> <| <\/decl.name><T<\/decl.generic_type_param.name><\/decl.generic_type_param>, ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>>(mode<\/decl.var.parameter.name>: CommandMode<\/ref.enum><\/decl.var.parameter.type><\/decl.var.parameter>, argument<\/decl.var.parameter.name>: Argument<\/ref.struct><T<\/ref.generic_type_param>><\/decl.var.parameter.type><\/decl.var.parameter>) -> Result<\/ref.enum><T<\/ref.generic_type_param>, CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>>><\/decl.function.returntype> where<\/syntaxtype.keyword> T<\/ref.generic_type_param> : ArgumentProtocol<\/ref.protocol><\/decl.generic_type_requirement><\/decl.function.operator.infix>", + "key.kind" : "source.lang.swift.decl.function.method.static", + "key.length" : 655, + "key.line" : 61, + "key.modulename" : "Commandant", + "key.name" : "<|(_:_:)", + "key.namelength" : 79, + "key.nameoffset" : 2088, + "key.offset" : 2076, + "key.parsed_declaration" : "public static func <| (mode: CommandMode, argument: Argument) -> Result>", + "key.parsed_scope.end" : 81, + "key.parsed_scope.start" : 61, + "key.related_decls" : [ + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Argument<[T]>) -> Result<[T], CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<T>) -> Result<T, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<T?>) -> Result<T?, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<[T]>) -> Result<[T], CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<[T]?>) -> Result<[T]?, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <ClientError>(_: CommandMode, _: Option<Bool>) -> Result<Bool, CommandantError<ClientError>><\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <ClientError>(_: CommandMode, _: Switch) -> Result<Bool, CommandantError<ClientError>><\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "T : ArgumentProtocol<\/Type><\/Declaration>", + "key.column" : 25, + "key.decl_lang" : "source.lang.swift", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 16, + "key.offset" : 2095 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "T<\/decl.generic_type_param.name> : ArgumentProtocol<\/ref.protocol><\/decl.generic_type_param.constraint><\/decl.generic_type_param>", + "key.inheritedtypes" : [ + { + "key.name" : "ArgumentProtocol" + } + ], + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 19, + "key.line" : 61, + "key.modulename" : "Commandant", + "key.name" : "T", + "key.namelength" : 1, + "key.nameoffset" : 2092, + "key.offset" : 2092, + "key.parsed_declaration" : "public static func <| ClientError<\/Declaration>", + "key.column" : 46, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 61, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 2113, + "key.offset" : 2113, + "key.parsed_declaration" : "public static func <| (CommandMode.Type) -> (CommandMode, Argument) -> Result>", + "key.typeusr" : "$sys6ResultOyx10Commandant0B5ErrorOyq_GGAC11CommandModeO_AC8ArgumentVyxGtcAC0F8ProtocolRzr0_luD", + "key.usr" : "s:10Commandant11CommandModeO2looiys6ResultOyxAA0A5ErrorOyq_GGAC_AA8ArgumentVyxGtAA0G8ProtocolRzr0_lFZ" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public static func <| <T, ClientError>(mode: CommandMode<\/Type>, argument: Argument<\/Type><[T<\/Type>]>) -> Result<\/Type><[T<\/Type>], CommandantError<\/Type><ClientError<\/Type>>> where T<\/Type> : ArgumentProtocol<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 2929 + } + ], + "key.bodylength" : 778, + "key.bodyoffset" : 3076, + "key.column" : 21, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Evaluates the given argument list in the given mode.\n\nIf parsing command line arguments, and no value was specified on the command\nline, the argument's `defaultValue` is used.", + "key.doc.column" : 21, + "key.doc.comment" : "Evaluates the given argument list in the given mode.\n\nIf parsing command line arguments, and no value was specified on the command\nline, the argument's `defaultValue` is used.", + "key.doc.declaration" : "public static func <| (mode: CommandMode, argument: Argument<[T]>) -> Result<[T], CommandantError> where T : Commandant.ArgumentProtocol", + "key.doc.discussion" : [ + { + "Para" : "If parsing command line arguments, and no value was specified on the command line, the argument’s `defaultValue` is used." + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Argument.swift", + "key.doc.full_as_xml" : "<|(_:_:)<\/Name>s:10Commandant11CommandModeO2looiys6ResultOySayxGAA0A5ErrorOyq_GGAC_AA8ArgumentVyAGGtAA0G8ProtocolRzr0_lFZ<\/USR>public static func <| <T, ClientError>(mode: CommandMode, argument: Argument<[T]>) -> Result<[T], CommandantError<ClientError>> where T : Commandant.ArgumentProtocol<\/Declaration>Evaluates the given argument list in the given mode.<\/Para><\/Abstract>If parsing command line arguments, and no value was specified on the command line, the argument’s defaultValue<\/codeVoice> is used.<\/Para><\/Discussion><\/CommentParts><\/Function>", + "key.doc.line" : 87, + "key.doc.name" : "<|(_:_:)", + "key.doc.type" : "Function", + "key.doclength" : 194, + "key.docoffset" : 2734, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> static<\/syntaxtype.keyword> func<\/syntaxtype.keyword> <| <\/decl.name><T<\/decl.generic_type_param.name><\/decl.generic_type_param>, ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>>(mode<\/decl.var.parameter.name>: CommandMode<\/ref.enum><\/decl.var.parameter.type><\/decl.var.parameter>, argument<\/decl.var.parameter.name>: Argument<\/ref.struct><[T<\/ref.generic_type_param>]><\/decl.var.parameter.type><\/decl.var.parameter>) -> Result<\/ref.enum><[T<\/ref.generic_type_param>], CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>>><\/decl.function.returntype> where<\/syntaxtype.keyword> T<\/ref.generic_type_param> : ArgumentProtocol<\/ref.protocol><\/decl.generic_type_requirement><\/decl.function.operator.infix>", + "key.kind" : "source.lang.swift.decl.function.method.static", + "key.length" : 919, + "key.line" : 87, + "key.modulename" : "Commandant", + "key.name" : "<|(_:_:)", + "key.namelength" : 81, + "key.nameoffset" : 2948, + "key.offset" : 2936, + "key.parsed_declaration" : "public static func <| (mode: CommandMode, argument: Argument<[T]>) -> Result<[T], CommandantError>", + "key.parsed_scope.end" : 119, + "key.parsed_scope.start" : 87, + "key.related_decls" : [ + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Argument<T>) -> Result<T, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<T>) -> Result<T, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<T?>) -> Result<T?, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<[T]>) -> Result<[T], CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<[T]?>) -> Result<[T]?, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <ClientError>(_: CommandMode, _: Option<Bool>) -> Result<Bool, CommandantError<ClientError>><\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <ClientError>(_: CommandMode, _: Switch) -> Result<Bool, CommandantError<ClientError>><\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "T : ArgumentProtocol<\/Type><\/Declaration>", + "key.column" : 25, + "key.decl_lang" : "source.lang.swift", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 16, + "key.offset" : 2955 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "T<\/decl.generic_type_param.name> : ArgumentProtocol<\/ref.protocol><\/decl.generic_type_param.constraint><\/decl.generic_type_param>", + "key.inheritedtypes" : [ + { + "key.name" : "ArgumentProtocol" + } + ], + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 19, + "key.line" : 87, + "key.modulename" : "Commandant", + "key.name" : "T", + "key.namelength" : 1, + "key.nameoffset" : 2952, + "key.offset" : 2952, + "key.parsed_declaration" : "public static func <| ClientError<\/Declaration>", + "key.column" : 46, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 87, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 2973, + "key.offset" : 2973, + "key.parsed_declaration" : "public static func <| (CommandMode.Type) -> (CommandMode, Argument<[T]>) -> Result<[T], CommandantError>", + "key.typeusr" : "$sys6ResultOySayxG10Commandant0B5ErrorOyq_GGAD11CommandModeO_AD8ArgumentVyACGtcAD0F8ProtocolRzr0_luD", + "key.usr" : "s:10Commandant11CommandModeO2looiys6ResultOySayxGAA0A5ErrorOyq_GGAC_AA8ArgumentVyAGGtAA0G8ProtocolRzr0_lFZ" + } + ], + "key.typename" : "CommandMode.Type", + "key.typeusr" : "$s10Commandant11CommandModeOmD", + "key.usr" : "s:10Commandant11CommandModeO" + } + ] + } +}, { + "\/Sources\/Commandant\/ArgumentParser.swift" : { + "key.diagnostic_stage" : "source.diagnostic.stage.swift.parse", + "key.length" : 4637, + "key.offset" : 0, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.private", + "key.annotated_decl" : "private enum RawArgument : Equatable<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.private", + "key.length" : 7, + "key.offset" : 229 + } + ], + "key.bodylength" : 296, + "key.bodyoffset" : 266, + "key.column" : 14, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Represents an argument passed on the command line.", + "key.doc.column" : 14, + "key.doc.comment" : "Represents an argument passed on the command line.", + "key.doc.declaration" : "private enum RawArgument : Equatable", + "key.doc.file" : "\/private\/Sources\/Commandant\/ArgumentParser.swift", + "key.doc.full_as_xml" : "RawArgument<\/Name>s:10Commandant11RawArgument33_BA859BFBBE9DF3838A11641CB273713ELLO<\/USR>private enum RawArgument : Equatable<\/Declaration>Represents an argument passed on the command line.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 12, + "key.doc.name" : "RawArgument", + "key.doc.type" : "Other", + "key.doclength" : 55, + "key.docoffset" : 174, + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 9, + "key.offset" : 255 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "private<\/syntaxtype.keyword> enum<\/syntaxtype.keyword> RawArgument<\/decl.name> : Equatable<\/ref.protocol><\/decl.enum>", + "key.inheritedtypes" : [ + { + "key.name" : "Equatable" + } + ], + "key.kind" : "source.lang.swift.decl.enum", + "key.length" : 326, + "key.line" : 12, + "key.modulename" : "Commandant", + "key.name" : "RawArgument", + "key.namelength" : 11, + "key.nameoffset" : 242, + "key.offset" : 237, + "key.parsed_declaration" : "private enum RawArgument: Equatable", + "key.parsed_scope.end" : 22, + "key.parsed_scope.start" : 12, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.kind" : "source.lang.swift.decl.enumcase", + "key.length" : 16, + "key.offset" : 341, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "case key(String<\/Type>)<\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A key corresponding to an option (e.g., `verbose` for `--verbose`).", + "key.doc.column" : 7, + "key.doc.comment" : "A key corresponding to an option (e.g., `verbose` for `--verbose`).", + "key.doc.declaration" : "", + "key.doc.file" : "\/private\/Sources\/Commandant\/ArgumentParser.swift", + "key.doc.full_as_xml" : "key(_:)<\/Name>s:10Commandant11RawArgument33_BA859BFBBE9DF3838A11641CB273713ELLO3keyyADSScADmF<\/USR><\/Declaration>A key corresponding to an option (e.g., verbose<\/codeVoice> for --verbose<\/codeVoice>).<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 14, + "key.doc.name" : "key(_:)", + "key.doc.type" : "Other", + "key.doclength" : 72, + "key.docoffset" : 268, + "key.filepath" : "", + "key.fully_annotated_decl" : "case<\/syntaxtype.keyword> key<\/decl.name>(String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>)<\/decl.enumelement>", + "key.kind" : "source.lang.swift.decl.enumelement", + "key.length" : 11, + "key.line" : 14, + "key.modulename" : "Commandant", + "key.name" : "key(_:)", + "key.namelength" : 11, + "key.nameoffset" : 346, + "key.offset" : 346, + "key.parsed_declaration" : "case key(String)", + "key.parsed_scope.end" : 14, + "key.parsed_scope.start" : 14, + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : "(RawArgument.Type) -> (String) -> RawArgument", + "key.typeusr" : "$sy10Commandant11RawArgument33_BA859BFBBE9DF3838A11641CB273713ELLOSScADmcD", + "key.usr" : "s:10Commandant11RawArgument33_BA859BFBBE9DF3838A11641CB273713ELLO3keyyADSScADmF" + } + ] + }, + { + "key.kind" : "source.lang.swift.decl.enumcase", + "key.length" : 18, + "key.offset" : 448, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "case value(String<\/Type>)<\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A value, either associated with an option or passed as a positional\nargument.", + "key.doc.column" : 7, + "key.doc.comment" : "A value, either associated with an option or passed as a positional\nargument.", + "key.doc.declaration" : "", + "key.doc.file" : "\/private\/Sources\/Commandant\/ArgumentParser.swift", + "key.doc.full_as_xml" : "value(_:)<\/Name>s:10Commandant11RawArgument33_BA859BFBBE9DF3838A11641CB273713ELLO5valueyADSScADmF<\/USR><\/Declaration>A value, either associated with an option or passed as a positional argument.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 18, + "key.doc.name" : "value(_:)", + "key.doc.type" : "Other", + "key.doclength" : 87, + "key.docoffset" : 360, + "key.filepath" : "", + "key.fully_annotated_decl" : "case<\/syntaxtype.keyword> value<\/decl.name>(String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>)<\/decl.enumelement>", + "key.kind" : "source.lang.swift.decl.enumelement", + "key.length" : 13, + "key.line" : 18, + "key.modulename" : "Commandant", + "key.name" : "value(_:)", + "key.namelength" : 13, + "key.nameoffset" : 453, + "key.offset" : 453, + "key.parsed_declaration" : "case value(String)", + "key.parsed_scope.end" : 18, + "key.parsed_scope.start" : 18, + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : "(RawArgument.Type) -> (String) -> RawArgument", + "key.typeusr" : "$sy10Commandant11RawArgument33_BA859BFBBE9DF3838A11641CB273713ELLOSScADmcD", + "key.usr" : "s:10Commandant11RawArgument33_BA859BFBBE9DF3838A11641CB273713ELLO5valueyADSScADmF" + } + ] + }, + { + "key.kind" : "source.lang.swift.decl.enumcase", + "key.length" : 32, + "key.offset" : 529, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "case flag(OrderedSet<\/Type><Character<\/Type>>)<\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "One or more flag arguments (e.g 'r' and 'f' for `-rf`)", + "key.doc.column" : 7, + "key.doc.comment" : "One or more flag arguments (e.g 'r' and 'f' for `-rf`)", + "key.doc.declaration" : "", + "key.doc.file" : "\/private\/Sources\/Commandant\/ArgumentParser.swift", + "key.doc.full_as_xml" : "flag(_:)<\/Name>s:10Commandant11RawArgument33_BA859BFBBE9DF3838A11641CB273713ELLO4flagyAdA10OrderedSetVySJGcADmF<\/USR><\/Declaration>One or more flag arguments (e.g ‘r’ and ‘f’ for -rf<\/codeVoice>)<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 21, + "key.doc.name" : "flag(_:)", + "key.doc.type" : "Other", + "key.doclength" : 59, + "key.docoffset" : 469, + "key.filepath" : "", + "key.fully_annotated_decl" : "case<\/syntaxtype.keyword> flag<\/decl.name>(OrderedSet<\/ref.struct><Character<\/ref.struct>><\/decl.var.parameter.type><\/decl.var.parameter>)<\/decl.enumelement>", + "key.kind" : "source.lang.swift.decl.enumelement", + "key.length" : 27, + "key.line" : 21, + "key.modulename" : "Commandant", + "key.name" : "flag(_:)", + "key.namelength" : 27, + "key.nameoffset" : 534, + "key.offset" : 534, + "key.parsed_declaration" : "case flag(OrderedSet)", + "key.parsed_scope.end" : 21, + "key.parsed_scope.start" : 21, + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : "(RawArgument.Type) -> (OrderedSet) -> RawArgument", + "key.typeusr" : "$sy10Commandant11RawArgument33_BA859BFBBE9DF3838A11641CB273713ELLOAA10OrderedSetVySJGcADmcD", + "key.usr" : "s:10Commandant11RawArgument33_BA859BFBBE9DF3838A11641CB273713ELLO4flagyAdA10OrderedSetVySJGcADmF" + } + ] + } + ], + "key.typename" : "RawArgument.Type", + "key.typeusr" : "$s10Commandant11RawArgument33_BA859BFBBE9DF3838A11641CB273713ELLOmD", + "key.usr" : "s:10Commandant11RawArgument33_BA859BFBBE9DF3838A11641CB273713ELLO" + }, + { + "key.annotated_decl" : "private enum RawArgument : Equatable<\/Type><\/Declaration>", + "key.bodylength" : 214, + "key.bodyoffset" : 613, + "key.column" : 14, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Represents an argument passed on the command line.", + "key.doc.column" : 14, + "key.doc.declaration" : "private enum RawArgument : Equatable", + "key.doc.file" : "\/private\/Sources\/Commandant\/ArgumentParser.swift", + "key.doc.full_as_xml" : "RawArgument<\/Name>s:10Commandant11RawArgument33_BA859BFBBE9DF3838A11641CB273713ELLO<\/USR>private enum RawArgument : Equatable<\/Declaration>Represents an argument passed on the command line.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 12, + "key.doc.name" : "RawArgument", + "key.doc.type" : "Other", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 23, + "key.offset" : 588 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "private<\/syntaxtype.keyword> enum<\/syntaxtype.keyword> RawArgument<\/decl.name> : Equatable<\/ref.protocol><\/decl.enum>", + "key.inheritedtypes" : [ + { + "key.name" : "CustomStringConvertible" + } + ], + "key.kind" : "source.lang.swift.decl.extension", + "key.length" : 263, + "key.line" : 12, + "key.modulename" : "Commandant", + "key.name" : "RawArgument", + "key.namelength" : 11, + "key.nameoffset" : 575, + "key.offset" : 565, + "key.parsed_declaration" : "extension RawArgument: CustomStringConvertible", + "key.parsed_scope.end" : 37, + "key.parsed_scope.start" : 24, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.fileprivate", + "key.annotated_decl" : "fileprivate var description: String<\/Type> { get }<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.fileprivate", + "key.length" : 11, + "key.offset" : 615 + } + ], + "key.bodylength" : 173, + "key.bodyoffset" : 652, + "key.column" : 18, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A textual representation of this instance.\n\nCalling this property directly is discouraged. Instead, convert an\ninstance of any type to a string by using the `String(describing:)`\ninitializer. This initializer works with any type, and uses the custom\n`description` property for types that conform to\n`CustomStringConvertible`:\n\n struct Point: CustomStringConvertible {\n let x: Int, y: Int\n\n var description: String {\n return \"(\\(x), \\(y))\"\n }\n }\n\n let p = Point(x: 21, y: 30)\n let s = String(describing: p)\n print(s)\n \/\/ Prints \"(21, 30)\"\n\nThe conversion of `p` to a string in the assignment to `s` uses the\n`Point` type's `description` property.", + "key.doc.declaration" : "var description: String { get }", + "key.doc.discussion" : [ + { + "Para" : "Calling this property directly is discouraged. Instead, convert an instance of any type to a string by using the `String(describing:)` initializer. This initializer works with any type, and uses the custom `description` property for types that conform to `CustomStringConvertible`:" + }, + { + "CodeListing" : "" + }, + { + "Para" : "The conversion of `p` to a string in the assignment to `s` uses the `Point` type’s `description` property." + }, + { + "Note" : "" + } + ], + "key.doc.full_as_xml" : "description<\/Name>s:s23CustomStringConvertibleP11descriptionSSvp<\/USR>var description: String { get }<\/Declaration>A textual representation of this instance.<\/Para><\/Abstract>Calling this property directly is discouraged. Instead, convert an instance of any type to a string by using the String(describing:)<\/codeVoice> initializer. This initializer works with any type, and uses the custom description<\/codeVoice> property for types that conform to CustomStringConvertible<\/codeVoice>:<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>The conversion of p<\/codeVoice> to a string in the assignment to s<\/codeVoice> uses the Point<\/codeVoice> type’s description<\/codeVoice> property.<\/Para>This documentation comment was inherited from CustomStringConvertible<\/codeVoice>.<\/Para><\/Note><\/Discussion><\/CommentParts><\/Other>", + "key.doc.name" : "description", + "key.doc.type" : "Other", + "key.filepath" : "", + "key.fully_annotated_decl" : "fileprivate<\/syntaxtype.keyword> var<\/syntaxtype.keyword> description<\/decl.name>: String<\/ref.struct><\/decl.var.type> { get<\/syntaxtype.keyword> }<\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 199, + "key.line" : 25, + "key.modulename" : "Commandant", + "key.name" : "description", + "key.namelength" : 11, + "key.nameoffset" : 631, + "key.offset" : 627, + "key.overrides" : [ + { + "key.usr" : "s:s23CustomStringConvertibleP11descriptionSSvp" + } + ], + "key.parsed_declaration" : "fileprivate var description: String", + "key.parsed_scope.end" : 36, + "key.parsed_scope.start" : 25, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:s23CustomStringConvertibleP11descriptionSSvp" + } + ], + "key.typename" : "RawArgument.Type", + "key.typeusr" : "$s10Commandant11RawArgument33_BA859BFBBE9DF3838A11641CB273713ELLOmD", + "key.usr" : "s:10Commandant11RawArgument33_BA859BFBBE9DF3838A11641CB273713ELLO" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public final class ArgumentParser<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.final", + "key.length" : 5, + "key.offset" : 896 + }, + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 889 + } + ], + "key.bodylength" : 3711, + "key.bodyoffset" : 924, + "key.column" : 20, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Destructively parses a list of command-line arguments.", + "key.doc.column" : 20, + "key.doc.comment" : "Destructively parses a list of command-line arguments.", + "key.doc.declaration" : "public final class ArgumentParser", + "key.doc.file" : "\/private\/Sources\/Commandant\/ArgumentParser.swift", + "key.doc.full_as_xml" : "ArgumentParser<\/Name>s:10Commandant14ArgumentParserC<\/USR>public final class ArgumentParser<\/Declaration>Destructively parses a list of command-line arguments.<\/Para><\/Abstract><\/CommentParts><\/Class>", + "key.doc.line" : 40, + "key.doc.name" : "ArgumentParser", + "key.doc.type" : "Class", + "key.doclength" : 59, + "key.docoffset" : 830, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> final<\/syntaxtype.keyword> class<\/syntaxtype.keyword> ArgumentParser<\/decl.name><\/decl.class>", + "key.kind" : "source.lang.swift.decl.class", + "key.length" : 3734, + "key.line" : 40, + "key.modulename" : "Commandant", + "key.name" : "ArgumentParser", + "key.namelength" : 14, + "key.nameoffset" : 908, + "key.offset" : 902, + "key.parsed_declaration" : "public final class ArgumentParser", + "key.parsed_scope.end" : 175, + "key.parsed_scope.start" : 40, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.private", + "key.annotated_decl" : "private var rawArguments: [RawArgument<\/Type>]<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.private", + "key.length" : 7, + "key.offset" : 991 + } + ], + "key.column" : 14, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "The remaining arguments to be extracted, in their raw form.", + "key.doc.column" : 14, + "key.doc.comment" : "The remaining arguments to be extracted, in their raw form.", + "key.doc.declaration" : "private var rawArguments: [RawArgument]", + "key.doc.file" : "\/private\/Sources\/Commandant\/ArgumentParser.swift", + "key.doc.full_as_xml" : "rawArguments<\/Name>s:10Commandant14ArgumentParserC12rawArguments33_BA859BFBBE9DF3838A11641CB273713ELLSayAA03RawB0AELLOGvp<\/USR>private var rawArguments: [RawArgument]<\/Declaration>The remaining arguments to be extracted, in their raw form.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 42, + "key.doc.name" : "rawArguments", + "key.doc.type" : "Other", + "key.doclength" : 64, + "key.docoffset" : 926, + "key.filepath" : "", + "key.fully_annotated_decl" : "private<\/syntaxtype.keyword> var<\/syntaxtype.keyword> rawArguments<\/decl.name>: [RawArgument<\/ref.enum>]<\/decl.var.type><\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 36, + "key.line" : 42, + "key.modulename" : "Commandant", + "key.name" : "rawArguments", + "key.namelength" : 12, + "key.nameoffset" : 1003, + "key.offset" : 999, + "key.parsed_declaration" : "private var rawArguments: [RawArgument] = []", + "key.parsed_scope.end" : 42, + "key.parsed_scope.start" : 42, + "key.reusingastcontext" : false, + "key.setter_accessibility" : "source.lang.swift.accessibility.private", + "key.typename" : "[RawArgument]", + "key.typeusr" : "$sSay10Commandant11RawArgument33_BA859BFBBE9DF3838A11641CB273713ELLOGD", + "key.usr" : "s:10Commandant14ArgumentParserC12rawArguments33_BA859BFBBE9DF3838A11641CB273713ELLSayAA03RawB0AELLOGvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public init(_ arguments: [String<\/Type>])<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 1115 + } + ], + "key.bodylength" : 741, + "key.bodyoffset" : 1151, + "key.column" : 9, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Initializes the generator from a simple list of command-line arguments.", + "key.doc.column" : 9, + "key.doc.comment" : "Initializes the generator from a simple list of command-line arguments.", + "key.doc.declaration" : "public init(_ arguments: [String])", + "key.doc.file" : "\/private\/Sources\/Commandant\/ArgumentParser.swift", + "key.doc.full_as_xml" : "init(_:)<\/Name>s:10Commandant14ArgumentParserCyACSaySSGcfc<\/USR>public init(_ arguments: [String])<\/Declaration>Initializes the generator from a simple list of command-line arguments.<\/Para><\/Abstract><\/CommentParts><\/Function>", + "key.doc.line" : 45, + "key.doc.name" : "init(_:)", + "key.doc.type" : "Function", + "key.doclength" : 76, + "key.docoffset" : 1038, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> init<\/syntaxtype.keyword>(_<\/decl.var.parameter.argument_label> arguments<\/decl.var.parameter.name>: [String<\/ref.struct>]<\/decl.var.parameter.type><\/decl.var.parameter>)<\/decl.function.constructor>", + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 771, + "key.line" : 45, + "key.modulename" : "Commandant", + "key.name" : "init(_:)", + "key.namelength" : 27, + "key.nameoffset" : 1122, + "key.offset" : 1122, + "key.parsed_declaration" : "public init(_ arguments: [String])", + "key.parsed_scope.end" : 70, + "key.parsed_scope.start" : 45, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "let params: [Array<\/Type><String<\/Type>>.SubSequence<\/Type>]<\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "let<\/syntaxtype.keyword> params<\/decl.name>: [Array<\/ref.struct><String<\/ref.struct>>.SubSequence<\/ref.typealias>]<\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 91, + "key.line" : 47, + "key.modulename" : "Commandant", + "key.name" : "params", + "key.namelength" : 6, + "key.nameoffset" : 1218, + "key.offset" : 1214, + "key.parsed_declaration" : "let params = arguments.split(maxSplits: 1, omittingEmptySubsequences: false) { $0 == \"--\" }", + "key.parsed_scope.end" : 47, + "key.parsed_scope.start" : 47, + "key.reusingastcontext" : false, + "key.typename" : "[ArraySlice]", + "key.typeusr" : "$sSays10ArraySliceVySSGGD", + "key.usr" : "s:10Commandant14ArgumentParserCyACSaySSGcfc6paramsL_Says10ArraySliceVySSGGvp" + }, + { + "key.annotated_decl" : "let options: Array<\/Type><String<\/Type>>.SubSequence<\/Type><\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "let<\/syntaxtype.keyword> options<\/decl.name>: Array<\/ref.struct><String<\/ref.struct>>.SubSequence<\/ref.typealias><\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 27, + "key.line" : 50, + "key.modulename" : "Commandant", + "key.name" : "options", + "key.namelength" : 7, + "key.nameoffset" : 1356, + "key.offset" : 1352, + "key.parsed_declaration" : "let options = params.first!", + "key.parsed_scope.end" : 50, + "key.parsed_scope.start" : 50, + "key.reusingastcontext" : false, + "key.typename" : "ArraySlice", + "key.typeusr" : "$ss10ArraySliceVySSGD", + "key.usr" : "s:10Commandant14ArgumentParserCyACSaySSGcfc7optionsL_s10ArraySliceVySSGvp" + } + ], + "key.typename" : "(ArgumentParser.Type) -> ([String]) -> ArgumentParser", + "key.typeusr" : "$sy10Commandant14ArgumentParserCSaySSGcD", + "key.usr" : "s:10Commandant14ArgumentParserCyACSaySSGcfc" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "internal var remainingArguments: [String<\/Type>]? { get }<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.internal", + "key.length" : 8, + "key.offset" : 1934 + } + ], + "key.bodylength" : 76, + "key.bodyoffset" : 1978, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Returns the remaining arguments.", + "key.doc.column" : 15, + "key.doc.comment" : "Returns the remaining arguments.", + "key.doc.declaration" : "internal var remainingArguments: [String]? { get }", + "key.doc.file" : "\/private\/Sources\/Commandant\/ArgumentParser.swift", + "key.doc.full_as_xml" : "remainingArguments<\/Name>s:10Commandant14ArgumentParserC18remainingArgumentsSaySSGSgvp<\/USR>internal var remainingArguments: [String]? { get }<\/Declaration>Returns the remaining arguments.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 73, + "key.doc.name" : "remainingArguments", + "key.doc.type" : "Other", + "key.doclength" : 37, + "key.docoffset" : 1896, + "key.filepath" : "", + "key.fully_annotated_decl" : "internal<\/syntaxtype.keyword> var<\/syntaxtype.keyword> remainingArguments<\/decl.name>: [String<\/ref.struct>]?<\/decl.var.type> { get<\/syntaxtype.keyword> }<\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 112, + "key.line" : 73, + "key.modulename" : "Commandant", + "key.name" : "remainingArguments", + "key.namelength" : 18, + "key.nameoffset" : 1947, + "key.offset" : 1943, + "key.parsed_declaration" : "internal var remainingArguments: [String]?", + "key.parsed_scope.end" : 75, + "key.parsed_scope.start" : 73, + "key.reusingastcontext" : false, + "key.typename" : "[String]?", + "key.typeusr" : "$sSaySSGSgD", + "key.usr" : "s:10Commandant14ArgumentParserC18remainingArgumentsSaySSGSgvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "internal func consumeBoolean(forKey key: String<\/Type>) -> Bool<\/Type>?<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.internal", + "key.length" : 8, + "key.offset" : 2264 + } + ], + "key.bodylength" : 281, + "key.bodyoffset" : 2323, + "key.column" : 16, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Returns whether the given key was enabled or disabled, or nil if it\nwas not given at all.\n\nIf the key is found, it is then removed from the list of arguments\nremaining to be parsed.", + "key.doc.column" : 16, + "key.doc.comment" : "Returns whether the given key was enabled or disabled, or nil if it\nwas not given at all.\n\nIf the key is found, it is then removed from the list of arguments\nremaining to be parsed.", + "key.doc.declaration" : "internal func consumeBoolean(forKey key: String) -> Bool?", + "key.doc.discussion" : [ + { + "Para" : "If the key is found, it is then removed from the list of arguments remaining to be parsed." + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/ArgumentParser.swift", + "key.doc.full_as_xml" : "consumeBoolean(forKey:)<\/Name>s:10Commandant14ArgumentParserC14consumeBoolean6forKeySbSgSS_tF<\/USR>internal func consumeBoolean(forKey key: String) -> Bool?<\/Declaration>Returns whether the given key was enabled or disabled, or nil if it was not given at all.<\/Para><\/Abstract>If the key is found, it is then removed from the list of arguments remaining to be parsed.<\/Para><\/Discussion><\/CommentParts><\/Function>", + "key.doc.line" : 82, + "key.doc.name" : "consumeBoolean(forKey:)", + "key.doc.type" : "Function", + "key.doclength" : 205, + "key.docoffset" : 2058, + "key.filepath" : "", + "key.fully_annotated_decl" : "internal<\/syntaxtype.keyword> func<\/syntaxtype.keyword> consumeBoolean<\/decl.name>(forKey<\/decl.var.parameter.argument_label> key<\/decl.var.parameter.name>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>) -> Bool<\/ref.struct>?<\/decl.function.returntype><\/decl.function.method.instance>", + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 332, + "key.line" : 82, + "key.modulename" : "Commandant", + "key.name" : "consumeBoolean(forKey:)", + "key.namelength" : 34, + "key.nameoffset" : 2278, + "key.offset" : 2273, + "key.parsed_declaration" : "internal func consumeBoolean(forKey key: String) -> Bool?", + "key.parsed_scope.end" : 98, + "key.parsed_scope.start" : 82, + "key.related_decls" : [ + { + "key.annotated_decl" : "consumeBoolean(flag:)<\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "let oldArguments: [RawArgument<\/Type>]<\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "let<\/syntaxtype.keyword> oldArguments<\/decl.name>: [RawArgument<\/ref.enum>]<\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 31, + "key.line" : 83, + "key.modulename" : "Commandant", + "key.name" : "oldArguments", + "key.namelength" : 12, + "key.nameoffset" : 2330, + "key.offset" : 2326, + "key.parsed_declaration" : "let oldArguments = rawArguments", + "key.parsed_scope.end" : 83, + "key.parsed_scope.start" : 83, + "key.reusingastcontext" : false, + "key.typename" : "[RawArgument]", + "key.typeusr" : "$sSay10Commandant11RawArgument33_BA859BFBBE9DF3838A11641CB273713ELLOGD", + "key.usr" : "s:10Commandant14ArgumentParserC14consumeBoolean6forKeySbSgSS_tF12oldArgumentsL_SayAA03RawB033_BA859BFBBE9DF3838A11641CB273713ELLOGvp" + }, + { + "key.annotated_decl" : "var result: Bool<\/Type>?<\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "var<\/syntaxtype.keyword> result<\/decl.name>: Bool<\/ref.struct>?<\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 17, + "key.line" : 86, + "key.modulename" : "Commandant", + "key.name" : "result", + "key.namelength" : 6, + "key.nameoffset" : 2392, + "key.offset" : 2388, + "key.parsed_declaration" : "var result: Bool?", + "key.parsed_scope.end" : 86, + "key.parsed_scope.start" : 86, + "key.reusingastcontext" : false, + "key.typename" : "Bool?", + "key.typeusr" : "$sSbSgD", + "key.usr" : "s:10Commandant14ArgumentParserC14consumeBoolean6forKeySbSgSS_tF6resultL_AFvp" + } + ], + "key.typename" : "(ArgumentParser) -> (String) -> Bool?", + "key.typeusr" : "$s6forKeySbSgSS_tcD", + "key.usr" : "s:10Commandant14ArgumentParserC14consumeBoolean6forKeySbSgSS_tF" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "internal func consumeValue(forKey key: String<\/Type>) -> Result<\/Type><String<\/Type>?, CommandantError<\/Type><Never<\/Type>>><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.internal", + "key.length" : 8, + "key.offset" : 2908 + } + ], + "key.bodylength" : 503, + "key.bodyoffset" : 2999, + "key.column" : 16, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Returns the value associated with the given flag, or nil if the flag was\nnot specified. If the key is presented, but no value was given, an error\nis returned.\n\nIf a value is found, the key and the value are both removed from the\nlist of arguments remaining to be parsed.", + "key.doc.column" : 16, + "key.doc.comment" : "Returns the value associated with the given flag, or nil if the flag was\nnot specified. If the key is presented, but no value was given, an error\nis returned.\n\nIf a value is found, the key and the value are both removed from the\nlist of arguments remaining to be parsed.", + "key.doc.declaration" : "internal func consumeValue(forKey key: String) -> Result>", + "key.doc.discussion" : [ + { + "Para" : "If a value is found, the key and the value are both removed from the list of arguments remaining to be parsed." + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/ArgumentParser.swift", + "key.doc.full_as_xml" : "consumeValue(forKey:)<\/Name>s:10Commandant14ArgumentParserC12consumeValue6forKeys6ResultOySSSgAA0A5ErrorOys5NeverOGGSS_tF<\/USR>internal func consumeValue(forKey key: String) -> Result<String?, CommandantError<Never>><\/Declaration>Returns the value associated with the given flag, or nil if the flag was not specified. If the key is presented, but no value was given, an error is returned.<\/Para><\/Abstract>If a value is found, the key and the value are both removed from the list of arguments remaining to be parsed.<\/Para><\/Discussion><\/CommentParts><\/Function>", + "key.doc.line" : 106, + "key.doc.name" : "consumeValue(forKey:)", + "key.doc.type" : "Function", + "key.doclength" : 299, + "key.docoffset" : 2608, + "key.filepath" : "", + "key.fully_annotated_decl" : "internal<\/syntaxtype.keyword> func<\/syntaxtype.keyword> consumeValue<\/decl.name>(forKey<\/decl.var.parameter.argument_label> key<\/decl.var.parameter.name>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>) -> Result<\/ref.enum><String<\/ref.struct>?, CommandantError<\/ref.enum><Never<\/ref.enum>>><\/decl.function.returntype><\/decl.function.method.instance>", + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 586, + "key.line" : 106, + "key.modulename" : "Commandant", + "key.name" : "consumeValue(forKey:)", + "key.namelength" : 32, + "key.nameoffset" : 2922, + "key.offset" : 2917, + "key.parsed_declaration" : "internal func consumeValue(forKey key: String) -> Result>", + "key.parsed_scope.end" : 131, + "key.parsed_scope.start" : 106, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "let oldArguments: [RawArgument<\/Type>]<\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "let<\/syntaxtype.keyword> oldArguments<\/decl.name>: [RawArgument<\/ref.enum>]<\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 31, + "key.line" : 107, + "key.modulename" : "Commandant", + "key.name" : "oldArguments", + "key.namelength" : 12, + "key.nameoffset" : 3006, + "key.offset" : 3002, + "key.parsed_declaration" : "let oldArguments = rawArguments", + "key.parsed_scope.end" : 107, + "key.parsed_scope.start" : 107, + "key.reusingastcontext" : false, + "key.typename" : "[RawArgument]", + "key.typeusr" : "$sSay10Commandant11RawArgument33_BA859BFBBE9DF3838A11641CB273713ELLOGD", + "key.usr" : "s:10Commandant14ArgumentParserC12consumeValue6forKeys6ResultOySSSgAA0A5ErrorOys5NeverOGGSS_tF12oldArgumentsL_SayAA03RawB033_BA859BFBBE9DF3838A11641CB273713ELLOGvp" + }, + { + "key.annotated_decl" : "var foundValue: String<\/Type>?<\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "var<\/syntaxtype.keyword> foundValue<\/decl.name>: String<\/ref.struct>?<\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 23, + "key.line" : 110, + "key.modulename" : "Commandant", + "key.name" : "foundValue", + "key.namelength" : 10, + "key.nameoffset" : 3068, + "key.offset" : 3064, + "key.parsed_declaration" : "var foundValue: String?", + "key.parsed_scope.end" : 110, + "key.parsed_scope.start" : 110, + "key.reusingastcontext" : false, + "key.typename" : "String?", + "key.typeusr" : "$sSSSgD", + "key.usr" : "s:10Commandant14ArgumentParserC12consumeValue6forKeys6ResultOySSSgAA0A5ErrorOys5NeverOGGSS_tF05foundE0L_AHvp" + }, + { + "key.annotated_decl" : "var index: Int<\/Type><\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "var<\/syntaxtype.keyword> index<\/decl.name>: Int<\/ref.struct><\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 13, + "key.line" : 111, + "key.modulename" : "Commandant", + "key.name" : "index", + "key.namelength" : 5, + "key.nameoffset" : 3094, + "key.offset" : 3090, + "key.parsed_declaration" : "var index = 0", + "key.parsed_scope.end" : 111, + "key.parsed_scope.start" : 111, + "key.related_decls" : [ + { + "key.annotated_decl" : "index(_:_:)<\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.typename" : "Int", + "key.typeusr" : "$sSiD", + "key.usr" : "s:10Commandant14ArgumentParserC12consumeValue6forKeys6ResultOySSSgAA0A5ErrorOys5NeverOGGSS_tF5indexL_Sivp" + } + ], + "key.typename" : "(ArgumentParser) -> (String) -> Result>", + "key.typeusr" : "$s6forKeys6ResultOySSSg10Commandant0D5ErrorOys5NeverOGGSS_tcD", + "key.usr" : "s:10Commandant14ArgumentParserC12consumeValue6forKeys6ResultOySSSgAA0A5ErrorOys5NeverOGGSS_tF" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "internal func consumePositionalArgument() -> String<\/Type>?<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.internal", + "key.length" : 8, + "key.offset" : 3634 + } + ], + "key.bodylength" : 164, + "key.bodyoffset" : 3688, + "key.column" : 16, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Returns the next positional argument that hasn't yet been returned, or\nnil if there are no more positional arguments.", + "key.doc.column" : 16, + "key.doc.comment" : "Returns the next positional argument that hasn't yet been returned, or\nnil if there are no more positional arguments.", + "key.doc.declaration" : "internal func consumePositionalArgument() -> String?", + "key.doc.file" : "\/private\/Sources\/Commandant\/ArgumentParser.swift", + "key.doc.full_as_xml" : "consumePositionalArgument()<\/Name>s:10Commandant14ArgumentParserC017consumePositionalB0SSSgyF<\/USR>internal func consumePositionalArgument() -> String?<\/Declaration>Returns the next positional argument that hasn’t yet been returned, or nil if there are no more positional arguments.<\/Para><\/Abstract><\/CommentParts><\/Function>", + "key.doc.line" : 135, + "key.doc.name" : "consumePositionalArgument()", + "key.doc.type" : "Function", + "key.doclength" : 127, + "key.docoffset" : 3506, + "key.filepath" : "", + "key.fully_annotated_decl" : "internal<\/syntaxtype.keyword> func<\/syntaxtype.keyword> consumePositionalArgument<\/decl.name>() -> String<\/ref.struct>?<\/decl.function.returntype><\/decl.function.method.instance>", + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 210, + "key.line" : 135, + "key.modulename" : "Commandant", + "key.name" : "consumePositionalArgument()", + "key.namelength" : 27, + "key.nameoffset" : 3648, + "key.offset" : 3643, + "key.parsed_declaration" : "internal func consumePositionalArgument() -> String?", + "key.parsed_scope.end" : 144, + "key.parsed_scope.start" : 135, + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : "(ArgumentParser) -> () -> String?", + "key.typeusr" : "$sSSSgycD", + "key.usr" : "s:10Commandant14ArgumentParserC017consumePositionalB0SSSgyF" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "internal func consume(key: String<\/Type>) -> Bool<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.internal", + "key.length" : 8, + "key.offset" : 3963 + } + ], + "key.bodylength" : 143, + "key.bodyoffset" : 4007, + "key.column" : 16, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Returns whether the given key was specified and removes it from the\nlist of arguments remaining.", + "key.doc.column" : 16, + "key.doc.comment" : "Returns whether the given key was specified and removes it from the\nlist of arguments remaining.", + "key.doc.declaration" : "internal func consume(key: String) -> Bool", + "key.doc.file" : "\/private\/Sources\/Commandant\/ArgumentParser.swift", + "key.doc.full_as_xml" : "consume(key:)<\/Name>s:10Commandant14ArgumentParserC7consume3keySbSS_tF<\/USR>internal func consume(key: String) -> Bool<\/Declaration>Returns whether the given key was specified and removes it from the list of arguments remaining.<\/Para><\/Abstract><\/CommentParts><\/Function>", + "key.doc.line" : 148, + "key.doc.name" : "consume(key:)", + "key.doc.type" : "Function", + "key.doclength" : 106, + "key.docoffset" : 3856, + "key.filepath" : "", + "key.fully_annotated_decl" : "internal<\/syntaxtype.keyword> func<\/syntaxtype.keyword> consume<\/decl.name>(key<\/decl.var.parameter.argument_label>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>) -> Bool<\/ref.struct><\/decl.function.returntype><\/decl.function.method.instance>", + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 179, + "key.line" : 148, + "key.modulename" : "Commandant", + "key.name" : "consume(key:)", + "key.namelength" : 20, + "key.nameoffset" : 3977, + "key.offset" : 3972, + "key.parsed_declaration" : "internal func consume(key: String) -> Bool", + "key.parsed_scope.end" : 153, + "key.parsed_scope.start" : 148, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "let oldArguments: [RawArgument<\/Type>]<\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "let<\/syntaxtype.keyword> oldArguments<\/decl.name>: [RawArgument<\/ref.enum>]<\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 31, + "key.line" : 149, + "key.modulename" : "Commandant", + "key.name" : "oldArguments", + "key.namelength" : 12, + "key.nameoffset" : 4014, + "key.offset" : 4010, + "key.parsed_declaration" : "let oldArguments = rawArguments", + "key.parsed_scope.end" : 149, + "key.parsed_scope.start" : 149, + "key.reusingastcontext" : false, + "key.typename" : "[RawArgument]", + "key.typeusr" : "$sSay10Commandant11RawArgument33_BA859BFBBE9DF3838A11641CB273713ELLOGD", + "key.usr" : "s:10Commandant14ArgumentParserC7consume3keySbSS_tF12oldArgumentsL_SayAA03RawB033_BA859BFBBE9DF3838A11641CB273713ELLOGvp" + } + ], + "key.typename" : "(ArgumentParser) -> (String) -> Bool", + "key.typeusr" : "$s3keySbSS_tcD", + "key.usr" : "s:10Commandant14ArgumentParserC7consume3keySbSS_tF" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "internal func consumeBoolean(flag: Character<\/Type>) -> Bool<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.internal", + "key.length" : 8, + "key.offset" : 4262 + } + ], + "key.bodylength" : 316, + "key.bodyoffset" : 4317, + "key.column" : 16, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Returns whether the given flag was specified and removes it from the\nlist of arguments remaining.", + "key.doc.column" : 16, + "key.doc.comment" : "Returns whether the given flag was specified and removes it from the\nlist of arguments remaining.", + "key.doc.declaration" : "internal func consumeBoolean(flag: Character) -> Bool", + "key.doc.file" : "\/private\/Sources\/Commandant\/ArgumentParser.swift", + "key.doc.full_as_xml" : "consumeBoolean(flag:)<\/Name>s:10Commandant14ArgumentParserC14consumeBoolean4flagSbSJ_tF<\/USR>internal func consumeBoolean(flag: Character) -> Bool<\/Declaration>Returns whether the given flag was specified and removes it from the list of arguments remaining.<\/Para><\/Abstract><\/CommentParts><\/Function>", + "key.doc.line" : 157, + "key.doc.name" : "consumeBoolean(flag:)", + "key.doc.type" : "Function", + "key.doclength" : 107, + "key.docoffset" : 4154, + "key.filepath" : "", + "key.fully_annotated_decl" : "internal<\/syntaxtype.keyword> func<\/syntaxtype.keyword> consumeBoolean<\/decl.name>(flag<\/decl.var.parameter.argument_label>: Character<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>) -> Bool<\/ref.struct><\/decl.function.returntype><\/decl.function.method.instance>", + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 363, + "key.line" : 157, + "key.modulename" : "Commandant", + "key.name" : "consumeBoolean(flag:)", + "key.namelength" : 31, + "key.nameoffset" : 4276, + "key.offset" : 4271, + "key.parsed_declaration" : "internal func consumeBoolean(flag: Character) -> Bool", + "key.parsed_scope.end" : 174, + "key.parsed_scope.start" : 157, + "key.related_decls" : [ + { + "key.annotated_decl" : "consumeBoolean(forKey:)<\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : "(ArgumentParser) -> (Character) -> Bool", + "key.typeusr" : "$s4flagSbSJ_tcD", + "key.usr" : "s:10Commandant14ArgumentParserC14consumeBoolean4flagSbSJ_tF" + } + ], + "key.typename" : "ArgumentParser.Type", + "key.typeusr" : "$s10Commandant14ArgumentParserCmD", + "key.usr" : "s:10Commandant14ArgumentParserC" + } + ] + } +}, { + "\/Sources\/Commandant\/ArgumentProtocol.swift" : { + "key.diagnostic_stage" : "source.diagnostic.stage.swift.parse", + "key.length" : 1141, + "key.offset" : 0, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public protocol ArgumentProtocol<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 219 + } + ], + "key.bodylength" : 189, + "key.bodyoffset" : 253, + "key.column" : 17, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Represents a value that can be converted from a command-line argument.", + "key.doc.column" : 17, + "key.doc.comment" : "Represents a value that can be converted from a command-line argument.", + "key.doc.declaration" : "public protocol ArgumentProtocol", + "key.doc.file" : "\/private\/Sources\/Commandant\/ArgumentProtocol.swift", + "key.doc.full_as_xml" : "ArgumentProtocol<\/Name>s:10Commandant16ArgumentProtocolP<\/USR>public protocol ArgumentProtocol<\/Declaration>Represents a value that can be converted from a command-line argument.<\/Para><\/Abstract><\/CommentParts><\/Class>", + "key.doc.line" : 10, + "key.doc.name" : "ArgumentProtocol", + "key.doc.type" : "Class", + "key.doclength" : 75, + "key.docoffset" : 144, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> protocol<\/syntaxtype.keyword> ArgumentProtocol<\/decl.name><\/decl.protocol>", + "key.kind" : "source.lang.swift.decl.protocol", + "key.length" : 217, + "key.line" : 10, + "key.modulename" : "Commandant", + "key.name" : "ArgumentProtocol", + "key.namelength" : 16, + "key.nameoffset" : 235, + "key.offset" : 226, + "key.parsed_declaration" : "public protocol ArgumentProtocol", + "key.parsed_scope.end" : 16, + "key.parsed_scope.start" : 10, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "static var name: String<\/Type> { get }<\/Declaration>", + "key.bodylength" : 5, + "key.bodyoffset" : 322, + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A human-readable name for this type.", + "key.doc.column" : 13, + "key.doc.comment" : "A human-readable name for this type.", + "key.doc.declaration" : "static var name: String { get }", + "key.doc.file" : "\/private\/Sources\/Commandant\/ArgumentProtocol.swift", + "key.doc.full_as_xml" : "name<\/Name>s:10Commandant16ArgumentProtocolP4nameSSvpZ<\/USR>static var name: String { get }<\/Declaration>A human-readable name for this type.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 12, + "key.doc.name" : "name", + "key.doc.type" : "Other", + "key.doclength" : 41, + "key.docoffset" : 255, + "key.filepath" : "", + "key.fully_annotated_decl" : "static<\/syntaxtype.keyword> var<\/syntaxtype.keyword> name<\/decl.name>: String<\/ref.struct><\/decl.var.type> { get<\/syntaxtype.keyword> }<\/decl.var.static>", + "key.is_dynamic" : true, + "key.kind" : "source.lang.swift.decl.var.static", + "key.length" : 31, + "key.line" : 12, + "key.modulename" : "Commandant", + "key.name" : "name", + "key.namelength" : 4, + "key.nameoffset" : 308, + "key.offset" : 297, + "key.parsed_declaration" : "static var name: String", + "key.parsed_scope.end" : 12, + "key.parsed_scope.start" : 12, + "key.receivers" : [ + { + "key.usr" : "s:10Commandant16ArgumentProtocolP" + } + ], + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant16ArgumentProtocolP4nameSSvpZ" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "static func from(string: String<\/Type>) -> Self<\/Type>?<\/Declaration>", + "key.column" : 14, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Attempts to parse a value from the given command-line argument.", + "key.doc.column" : 14, + "key.doc.comment" : "Attempts to parse a value from the given command-line argument.", + "key.doc.declaration" : "static func from(string: String) -> Self?", + "key.doc.file" : "\/private\/Sources\/Commandant\/ArgumentProtocol.swift", + "key.doc.full_as_xml" : "from(string:)<\/Name>s:10Commandant16ArgumentProtocolP4from6stringxSgSS_tFZ<\/USR>static func from(string: String) -> Self?<\/Declaration>Attempts to parse a value from the given command-line argument.<\/Para><\/Abstract><\/CommentParts><\/Function>", + "key.doc.line" : 15, + "key.doc.name" : "from(string:)", + "key.doc.type" : "Function", + "key.doclength" : 68, + "key.docoffset" : 331, + "key.filepath" : "", + "key.fully_annotated_decl" : "static<\/syntaxtype.keyword> func<\/syntaxtype.keyword> from<\/decl.name>(string<\/decl.var.parameter.argument_label>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>) -> Self<\/ref.generic_type_param>?<\/decl.function.returntype><\/decl.function.method.static>", + "key.is_dynamic" : true, + "key.kind" : "source.lang.swift.decl.function.method.static", + "key.length" : 41, + "key.line" : 15, + "key.modulename" : "Commandant", + "key.name" : "from(string:)", + "key.namelength" : 20, + "key.nameoffset" : 412, + "key.offset" : 400, + "key.parsed_declaration" : "static func from(string: String) -> Self?", + "key.parsed_scope.end" : 15, + "key.parsed_scope.start" : 15, + "key.receivers" : [ + { + "key.usr" : "s:10Commandant16ArgumentProtocolP" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : " (Self.Type) -> (String) -> Self?", + "key.typeusr" : "$s6stringxSgSS_tcD", + "key.usr" : "s:10Commandant16ArgumentProtocolP4from6stringxSgSS_tFZ" + } + ], + "key.typename" : "ArgumentProtocol.Type", + "key.typeusr" : "$s10Commandant16ArgumentProtocol_pmD", + "key.usr" : "s:10Commandant16ArgumentProtocolP" + }, + { + "key.annotated_decl" : "@frozen struct Int : FixedWidthInteger<\/Type>, SignedInteger<\/Type>, _ExpressibleByBuiltinIntegerLiteral<\/Type><\/Declaration>", + "key.bodylength" : 113, + "key.bodyoffset" : 478, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A signed integer value type.\n\nOn 32-bit platforms, `Int` is the same size as `Int32`, and\non 64-bit platforms, `Int` is the same size as `Int64`.", + "key.doc.declaration" : "@frozen struct Int : FixedWidthInteger, SignedInteger, _ExpressibleByBuiltinIntegerLiteral", + "key.doc.discussion" : [ + { + "Para" : "On 32-bit platforms, `Int` is the same size as `Int32`, and on 64-bit platforms, `Int` is the same size as `Int64`." + } + ], + "key.doc.full_as_xml" : "Int<\/Name>s:Si<\/USR>@frozen struct Int : FixedWidthInteger, SignedInteger, _ExpressibleByBuiltinIntegerLiteral<\/Declaration>A signed integer value type.<\/Para><\/Abstract>On 32-bit platforms, Int<\/codeVoice> is the same size as Int32<\/codeVoice>, and on 64-bit platforms, Int<\/codeVoice> is the same size as Int64<\/codeVoice>.<\/Para><\/Discussion><\/CommentParts><\/Class>", + "key.doc.name" : "Int", + "key.doc.type" : "Class", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 16, + "key.offset" : 460 + } + ], + "key.fully_annotated_decl" : "@frozen<\/syntaxtype.attribute.name><\/syntaxtype.attribute.builtin> struct<\/syntaxtype.keyword> Int<\/decl.name> : FixedWidthInteger<\/ref.protocol>, SignedInteger<\/ref.protocol>, _ExpressibleByBuiltinIntegerLiteral<\/ref.protocol><\/decl.struct>", + "key.groupname" : "Math\/Integers", + "key.inheritedtypes" : [ + { + "key.name" : "ArgumentProtocol" + } + ], + "key.is_system" : true, + "key.kind" : "source.lang.swift.decl.extension", + "key.length" : 147, + "key.modulename" : "Swift", + "key.name" : "Int", + "key.namelength" : 3, + "key.nameoffset" : 455, + "key.offset" : 445, + "key.parsed_declaration" : "extension Int: ArgumentProtocol", + "key.parsed_scope.end" : 24, + "key.parsed_scope.start" : 18, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public static let name: String<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 480 + } + ], + "key.column" : 20, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A human-readable name for this type.", + "key.doc.column" : 13, + "key.doc.declaration" : "static var name: String { get }", + "key.doc.discussion" : [ + { + "Note" : "" + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/ArgumentProtocol.swift", + "key.doc.full_as_xml" : "name<\/Name>s:10Commandant16ArgumentProtocolP4nameSSvpZ<\/USR>static var name: String { get }<\/Declaration>A human-readable name for this type.<\/Para><\/Abstract>This documentation comment was inherited from ArgumentProtocol<\/codeVoice>.<\/Para><\/Note><\/Discussion><\/CommentParts><\/Other>", + "key.doc.line" : 12, + "key.doc.name" : "name", + "key.doc.type" : "Other", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> static<\/syntaxtype.keyword> let<\/syntaxtype.keyword> name<\/decl.name>: String<\/ref.struct><\/decl.var.type><\/decl.var.static>", + "key.kind" : "source.lang.swift.decl.var.static", + "key.length" : 27, + "key.line" : 19, + "key.modulename" : "Commandant", + "key.name" : "name", + "key.namelength" : 4, + "key.nameoffset" : 498, + "key.offset" : 487, + "key.overrides" : [ + { + "key.usr" : "s:10Commandant16ArgumentProtocolP4nameSSvpZ" + } + ], + "key.parsed_declaration" : "public static let name = \"integer\"", + "key.parsed_scope.end" : 19, + "key.parsed_scope.start" : 19, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant16ArgumentProtocolP4nameSSvpZ" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public static func from(string: String<\/Type>) -> Int<\/Type>?<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 517 + } + ], + "key.bodylength" : 23, + "key.bodyoffset" : 566, + "key.column" : 21, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Attempts to parse a value from the given command-line argument.", + "key.doc.column" : 14, + "key.doc.declaration" : "static func from(string: String) -> Self?", + "key.doc.discussion" : [ + { + "Note" : "" + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/ArgumentProtocol.swift", + "key.doc.full_as_xml" : "from(string:)<\/Name>s:10Commandant16ArgumentProtocolP4from6stringxSgSS_tFZ<\/USR>static func from(string: String) -> Self?<\/Declaration>Attempts to parse a value from the given command-line argument.<\/Para><\/Abstract>This documentation comment was inherited from ArgumentProtocol<\/codeVoice>.<\/Para><\/Note><\/Discussion><\/CommentParts><\/Function>", + "key.doc.line" : 15, + "key.doc.name" : "from(string:)", + "key.doc.type" : "Function", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> static<\/syntaxtype.keyword> func<\/syntaxtype.keyword> from<\/decl.name>(string<\/decl.var.parameter.argument_label>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>) -> Int<\/ref.struct>?<\/decl.function.returntype><\/decl.function.method.static>", + "key.kind" : "source.lang.swift.decl.function.method.static", + "key.length" : 66, + "key.line" : 21, + "key.modulename" : "Commandant", + "key.name" : "from(string:)", + "key.namelength" : 20, + "key.nameoffset" : 536, + "key.offset" : 524, + "key.overrides" : [ + { + "key.usr" : "s:10Commandant16ArgumentProtocolP4from6stringxSgSS_tFZ" + } + ], + "key.parsed_declaration" : "public static func from(string: String) -> Int?", + "key.parsed_scope.end" : 23, + "key.parsed_scope.start" : 21, + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : "(Int.Type) -> (String) -> Int?", + "key.typeusr" : "$s6stringSiSgSS_tcD", + "key.usr" : "s:10Commandant16ArgumentProtocolP4from6stringxSgSS_tFZ" + } + ], + "key.typename" : "Int.Type", + "key.typeusr" : "$sSimD", + "key.usr" : "s:Si" + }, + { + "key.annotated_decl" : "@frozen @_eagerMove struct String<\/Declaration>", + "key.bodylength" : 110, + "key.bodyoffset" : 630, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A Unicode string value that is a collection of characters.\n\nA string is a series of characters, such as `\"Swift\"`, that forms a\ncollection. Strings in Swift are Unicode correct and locale insensitive,\nand are designed to be efficient. The `String` type bridges with the\nObjective-C class `NSString` and offers interoperability with C functions\nthat works with strings.\n\nYou can create new strings using string literals or string interpolations.\nA *string literal* is a series of characters enclosed in quotes.\n\n let greeting = \"Welcome!\"\n\n*String interpolations* are string literals that evaluate any included\nexpressions and convert the results to string form. String interpolations\ngive you an easy way to build a string from multiple pieces. Wrap each\nexpression in a string interpolation in parentheses, prefixed by a\nbackslash.\n\n let name = \"Rosa\"\n let personalizedGreeting = \"Welcome, \\(name)!\"\n \/\/ personalizedGreeting == \"Welcome, Rosa!\"\n\n let price = 2\n let number = 3\n let cookiePrice = \"\\(number) cookies: $\\(price * number).\"\n \/\/ cookiePrice == \"3 cookies: $6.\"\n\nCombine strings using the concatenation operator (`+`).\n\n let longerGreeting = greeting + \" We're glad you're here!\"\n \/\/ longerGreeting == \"Welcome! We're glad you're here!\"\n\nMultiline string literals are enclosed in three double quotation marks\n(`\"\"\"`), with each delimiter on its own line. Indentation is stripped from\neach line of a multiline string literal to match the indentation of the\nclosing delimiter.\n\n let banner = \"\"\"\n __,\n ( o \/) _\/_\n `. , , , , \/\/ \/\n (___)(_(_\/_(_ \/\/_ (__\n \/)\n (\/\n \"\"\"\n\nModifying and Comparing Strings\n===============================\n\nStrings always have value semantics. Modifying a copy of a string leaves\nthe original unaffected.\n\n var otherGreeting = greeting\n otherGreeting += \" Have a nice time!\"\n \/\/ otherGreeting == \"Welcome! Have a nice time!\"\n\n print(greeting)\n \/\/ Prints \"Welcome!\"\n\nComparing strings for equality using the equal-to operator (`==`) or a\nrelational operator (like `<` or `>=`) is always performed using Unicode\ncanonical representation. As a result, different representations of a\nstring compare as being equal.\n\n let cafe1 = \"Cafe\\u{301}\"\n let cafe2 = \"Café\"\n print(cafe1 == cafe2)\n \/\/ Prints \"true\"\n\nThe Unicode scalar value `\"\\u{301}\"` modifies the preceding character to\ninclude an accent, so `\"e\\u{301}\"` has the same canonical representation\nas the single Unicode scalar value `\"é\"`.\n\nBasic string operations are not sensitive to locale settings, ensuring that\nstring comparisons and other operations always have a single, stable\nresult, allowing strings to be used as keys in `Dictionary` instances and\nfor other purposes.\n\nAccessing String Elements\n=========================\n\nA string is a collection of *extended grapheme clusters*, which approximate\nhuman-readable characters. Many individual characters, such as \"é\", \"김\",\nand \"🇮🇳\", can be made up of multiple Unicode scalar values. These scalar\nvalues are combined by Unicode's boundary algorithms into extended\ngrapheme clusters, represented by the Swift `Character` type. Each element\nof a string is represented by a `Character` instance.\n\nFor example, to retrieve the first word of a longer string, you can search\nfor a space and then create a substring from a prefix of the string up to\nthat point:\n\n let name = \"Marie Curie\"\n let firstSpace = name.firstIndex(of: \" \") ?? name.endIndex\n let firstName = name[..=`) is always performed using Unicode canonical representation. As a result, different representations of a string compare as being equal." + }, + { + "CodeListing" : "" + }, + { + "Para" : "The Unicode scalar value `\"\\u{301}\"` modifies the preceding character to include an accent, so `\"e\\u{301}\"` has the same canonical representation as the single Unicode scalar value `\"é\"`." + }, + { + "Para" : "Basic string operations are not sensitive to locale settings, ensuring that string comparisons and other operations always have a single, stable result, allowing strings to be used as keys in `Dictionary` instances and for other purposes." + }, + { + "Para" : "A string is a collection of , which approximate human-readable characters. Many individual characters, such as “é”, “김”, and “🇮🇳”, can be made up of multiple Unicode scalar values. These scalar values are combined by Unicode’s boundary algorithms into extended grapheme clusters, represented by the Swift `Character` type. Each element of a string is represented by a `Character` instance." + }, + { + "Para" : "For example, to retrieve the first word of a longer string, you can search for a space and then create a substring from a prefix of the string up to that point:" + }, + { + "CodeListing" : "" + }, + { + "Para" : "The `firstName` constant is an instance of the `Substring` type—a type that represents substrings of a string while sharing the original string’s storage. Substrings present the same interface as strings." + }, + { + "CodeListing" : "" + }, + { + "Para" : "If you need to access the contents of a string as encoded in different Unicode encodings, use one of the string’s `unicodeScalars`, `utf16`, or `utf8` properties. Each property provides access to a view of the string as a series of code units, each encoded in a different Unicode encoding." + }, + { + "Para" : "To demonstrate the different views available for every string, the following examples use this `String` instance:" + }, + { + "CodeListing" : "" + }, + { + "Para" : "The `cafe` string is a collection of the nine characters that are visible when the string is displayed." + }, + { + "CodeListing" : "" + }, + { + "Para" : "A string’s `unicodeScalars` property is a collection of Unicode scalar values, the 21-bit codes that are the basic unit of Unicode. Each scalar value is represented by a `Unicode.Scalar` instance and is equivalent to a UTF-32 code unit." + }, + { + "CodeListing" : "" + }, + { + "Para" : "The `unicodeScalars` view’s elements comprise each Unicode scalar value in the `cafe` string. In particular, because `cafe` was declared using the decomposed form of the `\"é\"` character, `unicodeScalars` contains the scalar values for both the letter `\"e\"` (101) and the accent character `\"´\"` (769)." + }, + { + "Para" : "A string’s `utf16` property is a collection of UTF-16 code units, the 16-bit encoding form of the string’s Unicode scalar values. Each code unit is stored as a `UInt16` instance." + }, + { + "CodeListing" : "" + }, + { + "Para" : "The elements of the `utf16` view are the code units for the string when encoded in UTF-16. These elements match those accessed through indexed `NSString` APIs." + }, + { + "CodeListing" : "" + }, + { + "Para" : "A string’s `utf8` property is a collection of UTF-8 code units, the 8-bit encoding form of the string’s Unicode scalar values. Each code unit is stored as a `UInt8` instance." + }, + { + "CodeListing" : "" + }, + { + "Para" : "The elements of the `utf8` view are the code units for the string when encoded in UTF-8. This representation matches the one used when `String` instances are passed to C APIs." + }, + { + "CodeListing" : "" + }, + { + "Para" : "When you need to know the length of a string, you must first consider what you’ll use the length for. Are you measuring the number of characters that will be displayed on the screen, or are you measuring the amount of storage needed for the string in a particular encoding? A single string can have greatly differing lengths when measured by its different views." + }, + { + "Para" : "For example, an ASCII character like the capital letter is represented by a single element in each of its four views. The Unicode scalar value of is `65`, which is small enough to fit in a single code unit in both UTF-16 and UTF-8." + }, + { + "CodeListing" : "" + }, + { + "Para" : "On the other hand, an emoji flag character is constructed from a pair of Unicode scalar values, like `\"\\u{1F1F5}\"` and `\"\\u{1F1F7}\"`. Each of these scalar values, in turn, is too large to fit into a single UTF-16 or UTF-8 code unit. As a result, each view of the string `\"🇵🇷\"` reports a different length." + }, + { + "CodeListing" : "" + }, + { + "Para" : "To check whether a string is empty, use its `isEmpty` property instead of comparing the length of one of the views to `0`. Unlike with `isEmpty`, calculating a view’s `count` property requires iterating through the elements of the string." + }, + { + "Para" : "To find individual elements of a string, use the appropriate view for your task. For example, to retrieve the first word of a longer string, you can search the string for a space and then create a new string from a prefix of the string up to that point." + }, + { + "CodeListing" : "" + }, + { + "Para" : "Strings and their views share indices, so you can access the UTF-8 view of the `name` string using the same `firstSpace` index." + }, + { + "CodeListing" : "" + }, + { + "Para" : "Note that an index into one view may not have an exact corresponding position in another view. For example, the `flag` string declared above comprises a single character, but is composed of eight code units when encoded as UTF-8. The following code creates constants for the first and second positions in the `flag.utf8` view. Accessing the `utf8` view with these indices yields the first and second code UTF-8 units." + }, + { + "CodeListing" : "" + }, + { + "Para" : "When used to access the elements of the `flag` string itself, however, the `secondCodeUnit` index does not correspond to the position of a specific character. Instead of only accessing the specific UTF-8 code unit, that index is treated as the position of the character at the index’s encoded offset. In the case of `secondCodeUnit`, that character is still the flag itself." + }, + { + "CodeListing" : "" + }, + { + "Para" : "If you need to validate that an index from one string’s view corresponds with an exact position in another view, use the index’s `samePosition(in:)` method or the `init(_:within:)` initializer." + }, + { + "CodeListing" : "" + }, + { + "Para" : "Although strings in Swift have value semantics, strings use a copy-on-write strategy to store their data in a buffer. This buffer can then be shared by different copies of a string. A string’s data is only copied lazily, upon mutation, when more than one string instance is using the same buffer. Therefore, the first in any sequence of mutating operations may cost O() time and space." + }, + { + "Para" : "When a string’s contiguous storage fills up, a new buffer must be allocated and data must be moved to the new storage. String buffers use an exponential growth strategy that makes appending to a string a constant time operation when averaged over many append operations." + }, + { + "Para" : "Any `String` instance can be bridged to `NSString` using the type-cast operator (`as`), and any `String` instance that originates in Objective-C may use an `NSString` instance as its storage. Because any arbitrary subclass of `NSString` can become a `String` instance, there are no guarantees about representation or efficiency when a `String` instance is backed by `NSString` storage. Because `NSString` is immutable, it is just as though the storage was shared by a copy. The first in any sequence of mutating operations causes elements to be copied into unique, contiguous storage which may cost O() time and space, where is the length of the string’s encoded representation (or more, if the underlying `NSString` has unusual performance characteristics)." + }, + { + "Para" : "For more information about the Unicode terms used in this discussion, see the . In particular, this discussion mentions , , and ." + } + ], + "key.doc.full_as_xml" : "String<\/Name>s:SS<\/USR>@frozen struct String<\/Declaration>A Unicode string value that is a collection of characters.<\/Para><\/Abstract>A string is a series of characters, such as "Swift"<\/codeVoice>, that forms a collection. Strings in Swift are Unicode correct and locale insensitive, and are designed to be efficient. The String<\/codeVoice> type bridges with the Objective-C class NSString<\/codeVoice> and offers interoperability with C functions that works with strings.<\/Para>You can create new strings using string literals or string interpolations. A string literal<\/emphasis> is a series of characters enclosed in quotes.<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>String interpolations<\/emphasis> are string literals that evaluate any included expressions and convert the results to string form. String interpolations give you an easy way to build a string from multiple pieces. Wrap each expression in a string interpolation in parentheses, prefixed by a backslash.<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>Combine strings using the concatenation operator (+<\/codeVoice>).<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>Multiline string literals are enclosed in three double quotation marks ("""<\/codeVoice>), with each delimiter on its own line. Indentation is stripped from each line of a multiline string literal to match the indentation of the closing delimiter.<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>]]><\/rawHTML>Modifying and Comparing Strings]]><\/rawHTML>Strings always have value semantics. Modifying a copy of a string leaves the original unaffected.<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>Comparing strings for equality using the equal-to operator (==<\/codeVoice>) or a relational operator (like <<\/codeVoice> or >=<\/codeVoice>) is always performed using Unicode canonical representation. As a result, different representations of a string compare as being equal.<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>The Unicode scalar value "\\u{301}"<\/codeVoice> modifies the preceding character to include an accent, so "e\\u{301}"<\/codeVoice> has the same canonical representation as the single Unicode scalar value "é"<\/codeVoice>.<\/Para>Basic string operations are not sensitive to locale settings, ensuring that string comparisons and other operations always have a single, stable result, allowing strings to be used as keys in Dictionary<\/codeVoice> instances and for other purposes.<\/Para>]]><\/rawHTML>Accessing String Elements]]><\/rawHTML>A string is a collection of extended grapheme clusters<\/emphasis>, which approximate human-readable characters. Many individual characters, such as “é”, “김”, and “🇮🇳”, can be made up of multiple Unicode scalar values. These scalar values are combined by Unicode’s boundary algorithms into extended grapheme clusters, represented by the Swift Character<\/codeVoice> type. Each element of a string is represented by a Character<\/codeVoice> instance.<\/Para>For example, to retrieve the first word of a longer string, you can search for a space and then create a substring from a prefix of the string up to that point:<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>The firstName<\/codeVoice> constant is an instance of the Substring<\/codeVoice> type—a type that represents substrings of a string while sharing the original string’s storage. Substrings present the same interface as strings.<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>]]><\/rawHTML>Accessing a String’s Unicode Representation]]><\/rawHTML>If you need to access the contents of a string as encoded in different Unicode encodings, use one of the string’s unicodeScalars<\/codeVoice>, utf16<\/codeVoice>, or utf8<\/codeVoice> properties. Each property provides access to a view of the string as a series of code units, each encoded in a different Unicode encoding.<\/Para>To demonstrate the different views available for every string, the following examples use this String<\/codeVoice> instance:<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>The cafe<\/codeVoice> string is a collection of the nine characters that are visible when the string is displayed.<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>]]><\/rawHTML>Unicode Scalar View]]><\/rawHTML>A string’s unicodeScalars<\/codeVoice> property is a collection of Unicode scalar values, the 21-bit codes that are the basic unit of Unicode. Each scalar value is represented by a Unicode.Scalar<\/codeVoice> instance and is equivalent to a UTF-32 code unit.<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>The unicodeScalars<\/codeVoice> view’s elements comprise each Unicode scalar value in the cafe<\/codeVoice> string. In particular, because cafe<\/codeVoice> was declared using the decomposed form of the "é"<\/codeVoice> character, unicodeScalars<\/codeVoice> contains the scalar values for both the letter "e"<\/codeVoice> (101) and the accent character "´"<\/codeVoice> (769).<\/Para>]]><\/rawHTML>UTF-16 View]]><\/rawHTML>A string’s utf16<\/codeVoice> property is a collection of UTF-16 code units, the 16-bit encoding form of the string’s Unicode scalar values. Each code unit is stored as a UInt16<\/codeVoice> instance.<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>The elements of the utf16<\/codeVoice> view are the code units for the string when encoded in UTF-16. These elements match those accessed through indexed NSString<\/codeVoice> APIs.<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>]]><\/rawHTML>UTF-8 View]]><\/rawHTML>A string’s utf8<\/codeVoice> property is a collection of UTF-8 code units, the 8-bit encoding form of the string’s Unicode scalar values. Each code unit is stored as a UInt8<\/codeVoice> instance.<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>The elements of the utf8<\/codeVoice> view are the code units for the string when encoded in UTF-8. This representation matches the one used when String<\/codeVoice> instances are passed to C APIs.<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>]]><\/rawHTML>Measuring the Length of a String]]><\/rawHTML>When you need to know the length of a string, you must first consider what you’ll use the length for. Are you measuring the number of characters that will be displayed on the screen, or are you measuring the amount of storage needed for the string in a particular encoding? A single string can have greatly differing lengths when measured by its different views.<\/Para>For example, an ASCII character like the capital letter A<\/emphasis> is represented by a single element in each of its four views. The Unicode scalar value of A<\/emphasis> is 65<\/codeVoice>, which is small enough to fit in a single code unit in both UTF-16 and UTF-8.<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>On the other hand, an emoji flag character is constructed from a pair of Unicode scalar values, like "\\u{1F1F5}"<\/codeVoice> and "\\u{1F1F7}"<\/codeVoice>. Each of these scalar values, in turn, is too large to fit into a single UTF-16 or UTF-8 code unit. As a result, each view of the string "🇵🇷"<\/codeVoice> reports a different length.<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>To check whether a string is empty, use its isEmpty<\/codeVoice> property instead of comparing the length of one of the views to 0<\/codeVoice>. Unlike with isEmpty<\/codeVoice>, calculating a view’s count<\/codeVoice> property requires iterating through the elements of the string.<\/Para>]]><\/rawHTML>Accessing String View Elements]]><\/rawHTML>To find individual elements of a string, use the appropriate view for your task. For example, to retrieve the first word of a longer string, you can search the string for a space and then create a new string from a prefix of the string up to that point.<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>Strings and their views share indices, so you can access the UTF-8 view of the name<\/codeVoice> string using the same firstSpace<\/codeVoice> index.<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>Note that an index into one view may not have an exact corresponding position in another view. For example, the flag<\/codeVoice> string declared above comprises a single character, but is composed of eight code units when encoded as UTF-8. The following code creates constants for the first and second positions in the flag.utf8<\/codeVoice> view. Accessing the utf8<\/codeVoice> view with these indices yields the first and second code UTF-8 units.<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>When used to access the elements of the flag<\/codeVoice> string itself, however, the secondCodeUnit<\/codeVoice> index does not correspond to the position of a specific character. Instead of only accessing the specific UTF-8 code unit, that index is treated as the position of the character at the index’s encoded offset. In the case of secondCodeUnit<\/codeVoice>, that character is still the flag itself.<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>If you need to validate that an index from one string’s view corresponds with an exact position in another view, use the index’s samePosition(in:)<\/codeVoice> method or the init(_:within:)<\/codeVoice> initializer.<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>]]><\/rawHTML>Performance Optimizations]]><\/rawHTML>Although strings in Swift have value semantics, strings use a copy-on-write strategy to store their data in a buffer. This buffer can then be shared by different copies of a string. A string’s data is only copied lazily, upon mutation, when more than one string instance is using the same buffer. Therefore, the first in any sequence of mutating operations may cost O(n<\/emphasis>) time and space.<\/Para>When a string’s contiguous storage fills up, a new buffer must be allocated and data must be moved to the new storage. String buffers use an exponential growth strategy that makes appending to a string a constant time operation when averaged over many append operations.<\/Para>]]><\/rawHTML>Bridging Between String and NSString]]><\/rawHTML>Any String<\/codeVoice> instance can be bridged to NSString<\/codeVoice> using the type-cast operator (as<\/codeVoice>), and any String<\/codeVoice> instance that originates in Objective-C may use an NSString<\/codeVoice> instance as its storage. Because any arbitrary subclass of NSString<\/codeVoice> can become a String<\/codeVoice> instance, there are no guarantees about representation or efficiency when a String<\/codeVoice> instance is backed by NSString<\/codeVoice> storage. Because NSString<\/codeVoice> is immutable, it is just as though the storage was shared by a copy. The first in any sequence of mutating operations causes elements to be copied into unique, contiguous storage which may cost O(n<\/emphasis>) time and space, where n<\/emphasis> is the length of the string’s encoded representation (or more, if the underlying NSString<\/codeVoice> has unusual performance characteristics).<\/Para>For more information about the Unicode terms used in this discussion, see the Unicode.org glossary<\/Link>. In particular, this discussion mentions extended grapheme clusters<\/Link>, Unicode scalar values<\/Link>, and canonical equivalence<\/Link>.<\/Para><\/Discussion><\/CommentParts><\/Class>", + "key.doc.name" : "String", + "key.doc.type" : "Class", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 16, + "key.offset" : 612 + } + ], + "key.fully_annotated_decl" : "@frozen<\/syntaxtype.attribute.name><\/syntaxtype.attribute.builtin> @_eagerMove<\/syntaxtype.attribute.name><\/syntaxtype.attribute.builtin> struct<\/syntaxtype.keyword> String<\/decl.name><\/decl.struct>", + "key.groupname" : "String", + "key.inheritedtypes" : [ + { + "key.name" : "ArgumentProtocol" + } + ], + "key.is_system" : true, + "key.kind" : "source.lang.swift.decl.extension", + "key.length" : 147, + "key.modulename" : "Swift", + "key.name" : "String", + "key.namelength" : 6, + "key.nameoffset" : 604, + "key.offset" : 594, + "key.parsed_declaration" : "extension String: ArgumentProtocol", + "key.parsed_scope.end" : 32, + "key.parsed_scope.start" : 26, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public static let name: String<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 632 + } + ], + "key.column" : 20, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A human-readable name for this type.", + "key.doc.column" : 13, + "key.doc.declaration" : "static var name: String { get }", + "key.doc.discussion" : [ + { + "Note" : "" + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/ArgumentProtocol.swift", + "key.doc.full_as_xml" : "name<\/Name>s:10Commandant16ArgumentProtocolP4nameSSvpZ<\/USR>static var name: String { get }<\/Declaration>A human-readable name for this type.<\/Para><\/Abstract>This documentation comment was inherited from ArgumentProtocol<\/codeVoice>.<\/Para><\/Note><\/Discussion><\/CommentParts><\/Other>", + "key.doc.line" : 12, + "key.doc.name" : "name", + "key.doc.type" : "Other", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> static<\/syntaxtype.keyword> let<\/syntaxtype.keyword> name<\/decl.name>: String<\/ref.struct><\/decl.var.type><\/decl.var.static>", + "key.kind" : "source.lang.swift.decl.var.static", + "key.length" : 26, + "key.line" : 27, + "key.modulename" : "Commandant", + "key.name" : "name", + "key.namelength" : 4, + "key.nameoffset" : 650, + "key.offset" : 639, + "key.overrides" : [ + { + "key.usr" : "s:10Commandant16ArgumentProtocolP4nameSSvpZ" + } + ], + "key.parsed_declaration" : "public static let name = \"string\"", + "key.parsed_scope.end" : 27, + "key.parsed_scope.start" : 27, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant16ArgumentProtocolP4nameSSvpZ" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public static func from(string: String<\/Type>) -> String<\/Type>?<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 668 + } + ], + "key.bodylength" : 18, + "key.bodyoffset" : 720, + "key.column" : 21, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Attempts to parse a value from the given command-line argument.", + "key.doc.column" : 14, + "key.doc.declaration" : "static func from(string: String) -> Self?", + "key.doc.discussion" : [ + { + "Note" : "" + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/ArgumentProtocol.swift", + "key.doc.full_as_xml" : "from(string:)<\/Name>s:10Commandant16ArgumentProtocolP4from6stringxSgSS_tFZ<\/USR>static func from(string: String) -> Self?<\/Declaration>Attempts to parse a value from the given command-line argument.<\/Para><\/Abstract>This documentation comment was inherited from ArgumentProtocol<\/codeVoice>.<\/Para><\/Note><\/Discussion><\/CommentParts><\/Function>", + "key.doc.line" : 15, + "key.doc.name" : "from(string:)", + "key.doc.type" : "Function", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> static<\/syntaxtype.keyword> func<\/syntaxtype.keyword> from<\/decl.name>(string<\/decl.var.parameter.argument_label>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>) -> String<\/ref.struct>?<\/decl.function.returntype><\/decl.function.method.static>", + "key.kind" : "source.lang.swift.decl.function.method.static", + "key.length" : 64, + "key.line" : 29, + "key.modulename" : "Commandant", + "key.name" : "from(string:)", + "key.namelength" : 20, + "key.nameoffset" : 687, + "key.offset" : 675, + "key.overrides" : [ + { + "key.usr" : "s:10Commandant16ArgumentProtocolP4from6stringxSgSS_tFZ" + } + ], + "key.parsed_declaration" : "public static func from(string: String) -> String?", + "key.parsed_scope.end" : 31, + "key.parsed_scope.start" : 29, + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : "(String.Type) -> (String) -> String?", + "key.typeusr" : "$s6stringSSSgSS_tcD", + "key.usr" : "s:10Commandant16ArgumentProtocolP4from6stringxSgSS_tFZ" + } + ], + "key.typename" : "String.Type", + "key.typeusr" : "$sSSmD", + "key.usr" : "s:SS" + }, + { + "key.annotated_decl" : "protocol RawRepresentable<RawValue<\/Type>><\/Declaration>", + "key.bodylength" : 112, + "key.bodyoffset" : 826, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A type that can be converted to and from an associated raw value.\n\nWith a `RawRepresentable` type, you can switch back and forth between a\ncustom type and an associated `RawValue` type without losing the value of\nthe original `RawRepresentable` type. Using the raw value of a conforming\ntype streamlines interoperation with Objective-C and legacy APIs and\nsimplifies conformance to other protocols, such as `Equatable`,\n`Comparable`, and `Hashable`.\n\nThe `RawRepresentable` protocol is seen mainly in two categories of types:\nenumerations with raw value types and option sets.\n\nEnumerations with Raw Values\n============================\n\nFor any enumeration with a string, integer, or floating-point raw type, the\nSwift compiler automatically adds `RawRepresentable` conformance. When\ndefining your own custom enumeration, you give it a raw type by specifying\nthe raw type as the first item in the enumeration's type inheritance list.\nYou can also use literals to specify values for one or more cases.\n\nFor example, the `Counter` enumeration defined here has an `Int` raw value\ntype and gives the first case a raw value of `1`:\n\n enum Counter: Int {\n case one = 1, two, three, four, five\n }\n\nYou can create a `Counter` instance from an integer value between 1 and 5\nby using the `init?(rawValue:)` initializer declared in the\n`RawRepresentable` protocol. This initializer is failable because although\nevery case of the `Counter` type has a corresponding `Int` value, there\nare many `Int` values that *don't* correspond to a case of `Counter`.\n\n for i in 3...6 {\n print(Counter(rawValue: i))\n }\n \/\/ Prints \"Optional(Counter.three)\"\n \/\/ Prints \"Optional(Counter.four)\"\n \/\/ Prints \"Optional(Counter.five)\"\n \/\/ Prints \"nil\"\n\nOption Sets\n===========\n\nOption sets all conform to `RawRepresentable` by inheritance using the\n`OptionSet` protocol. Whether using an option set or creating your own,\nyou use the raw value of an option set instance to store the instance's\nbitfield. The raw value must therefore be of a type that conforms to the\n`FixedWidthInteger` protocol, such as `UInt8` or `Int`. For example, the\n`Direction` type defines an option set for the four directions you can\nmove in a game.\n\n struct Directions: OptionSet {\n let rawValue: UInt8\n\n static let up = Directions(rawValue: 1 << 0)\n static let down = Directions(rawValue: 1 << 1)\n static let left = Directions(rawValue: 1 << 2)\n static let right = Directions(rawValue: 1 << 3)\n }\n\nUnlike enumerations, option sets provide a nonfailable `init(rawValue:)`\ninitializer to convert from a raw value, because option sets don't have an\nenumerated list of all possible cases. Option set values have\na one-to-one correspondence with their associated raw values.\n\nIn the case of the `Directions` option set, an instance can contain zero,\none, or more of the four defined directions. This example declares a\nconstant with three currently allowed moves. The raw value of the\n`allowedMoves` instance is the result of the bitwise OR of its three\nmembers' raw values:\n\n let allowedMoves: Directions = [.up, .down, .left]\n print(allowedMoves.rawValue)\n \/\/ Prints \"7\"\n\nOption sets use bitwise operations on their associated raw values to\nimplement their mathematical set operations. For example, the `contains()`\nmethod on `allowedMoves` performs a bitwise AND operation to check whether\nthe option set contains an element.\n\n print(allowedMoves.contains(.right))\n \/\/ Prints \"false\"\n print(allowedMoves.rawValue & Directions.right.rawValue)\n \/\/ Prints \"0\"", + "key.doc.declaration" : "protocol RawRepresentable", + "key.doc.discussion" : [ + { + "Para" : "With a `RawRepresentable` type, you can switch back and forth between a custom type and an associated `RawValue` type without losing the value of the original `RawRepresentable` type. Using the raw value of a conforming type streamlines interoperation with Objective-C and legacy APIs and simplifies conformance to other protocols, such as `Equatable`, `Comparable`, and `Hashable`." + }, + { + "Para" : "The `RawRepresentable` protocol is seen mainly in two categories of types: enumerations with raw value types and option sets." + }, + { + "Para" : "For any enumeration with a string, integer, or floating-point raw type, the Swift compiler automatically adds `RawRepresentable` conformance. When defining your own custom enumeration, you give it a raw type by specifying the raw type as the first item in the enumeration’s type inheritance list. You can also use literals to specify values for one or more cases." + }, + { + "Para" : "For example, the `Counter` enumeration defined here has an `Int` raw value type and gives the first case a raw value of `1`:" + }, + { + "CodeListing" : "" + }, + { + "Para" : "You can create a `Counter` instance from an integer value between 1 and 5 by using the `init?(rawValue:)` initializer declared in the `RawRepresentable` protocol. This initializer is failable because although every case of the `Counter` type has a corresponding `Int` value, there are many `Int` values that correspond to a case of `Counter`." + }, + { + "CodeListing" : "" + }, + { + "Para" : "Option sets all conform to `RawRepresentable` by inheritance using the `OptionSet` protocol. Whether using an option set or creating your own, you use the raw value of an option set instance to store the instance’s bitfield. The raw value must therefore be of a type that conforms to the `FixedWidthInteger` protocol, such as `UInt8` or `Int`. For example, the `Direction` type defines an option set for the four directions you can move in a game." + }, + { + "CodeListing" : "" + }, + { + "Para" : "Unlike enumerations, option sets provide a nonfailable `init(rawValue:)` initializer to convert from a raw value, because option sets don’t have an enumerated list of all possible cases. Option set values have a one-to-one correspondence with their associated raw values." + }, + { + "Para" : "In the case of the `Directions` option set, an instance can contain zero, one, or more of the four defined directions. This example declares a constant with three currently allowed moves. The raw value of the `allowedMoves` instance is the result of the bitwise OR of its three members’ raw values:" + }, + { + "CodeListing" : "" + }, + { + "Para" : "Option sets use bitwise operations on their associated raw values to implement their mathematical set operations. For example, the `contains()` method on `allowedMoves` performs a bitwise AND operation to check whether the option set contains an element." + }, + { + "CodeListing" : "" + } + ], + "key.doc.full_as_xml" : "RawRepresentable<\/Name>s:SY<\/USR>protocol RawRepresentable<RawValue><\/Declaration>A type that can be converted to and from an associated raw value.<\/Para><\/Abstract>With a RawRepresentable<\/codeVoice> type, you can switch back and forth between a custom type and an associated RawValue<\/codeVoice> type without losing the value of the original RawRepresentable<\/codeVoice> type. Using the raw value of a conforming type streamlines interoperation with Objective-C and legacy APIs and simplifies conformance to other protocols, such as Equatable<\/codeVoice>, Comparable<\/codeVoice>, and Hashable<\/codeVoice>.<\/Para>The RawRepresentable<\/codeVoice> protocol is seen mainly in two categories of types: enumerations with raw value types and option sets.<\/Para>]]><\/rawHTML>Enumerations with Raw Values]]><\/rawHTML>For any enumeration with a string, integer, or floating-point raw type, the Swift compiler automatically adds RawRepresentable<\/codeVoice> conformance. When defining your own custom enumeration, you give it a raw type by specifying the raw type as the first item in the enumeration’s type inheritance list. You can also use literals to specify values for one or more cases.<\/Para>For example, the Counter<\/codeVoice> enumeration defined here has an Int<\/codeVoice> raw value type and gives the first case a raw value of 1<\/codeVoice>:<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>You can create a Counter<\/codeVoice> instance from an integer value between 1 and 5 by using the init?(rawValue:)<\/codeVoice> initializer declared in the RawRepresentable<\/codeVoice> protocol. This initializer is failable because although every case of the Counter<\/codeVoice> type has a corresponding Int<\/codeVoice> value, there are many Int<\/codeVoice> values that don’t<\/emphasis> correspond to a case of Counter<\/codeVoice>.<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>]]><\/rawHTML>Option Sets]]><\/rawHTML>Option sets all conform to RawRepresentable<\/codeVoice> by inheritance using the OptionSet<\/codeVoice> protocol. Whether using an option set or creating your own, you use the raw value of an option set instance to store the instance’s bitfield. The raw value must therefore be of a type that conforms to the FixedWidthInteger<\/codeVoice> protocol, such as UInt8<\/codeVoice> or Int<\/codeVoice>. For example, the Direction<\/codeVoice> type defines an option set for the four directions you can move in a game.<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>Unlike enumerations, option sets provide a nonfailable init(rawValue:)<\/codeVoice> initializer to convert from a raw value, because option sets don’t have an enumerated list of all possible cases. Option set values have a one-to-one correspondence with their associated raw values.<\/Para>In the case of the Directions<\/codeVoice> option set, an instance can contain zero, one, or more of the four defined directions. This example declares a constant with three currently allowed moves. The raw value of the allowedMoves<\/codeVoice> instance is the result of the bitwise OR of its three members’ raw values:<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>Option sets use bitwise operations on their associated raw values to implement their mathematical set operations. For example, the contains()<\/codeVoice> method on allowedMoves<\/codeVoice> performs a bitwise AND operation to check whether the option set contains an element.<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing><\/Discussion><\/CommentParts><\/Class>", + "key.doc.name" : "RawRepresentable", + "key.doc.type" : "Class", + "key.fully_annotated_decl" : "protocol<\/syntaxtype.keyword> RawRepresentable<\/decl.name><RawValue<\/ref.associatedtype><\/decl.generic_type_param>><\/decl.protocol>", + "key.groupname" : "Protocols", + "key.is_system" : true, + "key.kind" : "source.lang.swift.decl.extension", + "key.length" : 196, + "key.modulename" : "Swift", + "key.name" : "RawRepresentable", + "key.namelength" : 16, + "key.nameoffset" : 753, + "key.offset" : 743, + "key.parsed_declaration" : "extension RawRepresentable where RawValue: StringProtocol, Self: ArgumentProtocol", + "key.parsed_scope.end" : 38, + "key.parsed_scope.start" : 34, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public static func from(string: String<\/Type>) -> Self<\/Type>?<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 828 + } + ], + "key.bodylength" : 58, + "key.bodyoffset" : 878, + "key.column" : 21, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> static<\/syntaxtype.keyword> func<\/syntaxtype.keyword> from<\/decl.name>(string<\/decl.var.parameter.argument_label>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>) -> Self<\/ref.generic_type_param>?<\/decl.function.returntype><\/decl.function.method.static>", + "key.is_dynamic" : true, + "key.kind" : "source.lang.swift.decl.function.method.static", + "key.length" : 102, + "key.line" : 35, + "key.modulename" : "Commandant", + "key.name" : "from(string:)", + "key.namelength" : 20, + "key.nameoffset" : 847, + "key.offset" : 835, + "key.parsed_declaration" : "public static func from(string: String) -> Self?", + "key.parsed_scope.end" : 37, + "key.parsed_scope.start" : 35, + "key.receivers" : [ + { + "key.usr" : "s:SY" + } + ], + "key.related_decls" : [ + { + "key.annotated_decl" : "from(string: String) -> Self?<\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : " (Self.Type) -> (String) -> Self?", + "key.typeusr" : "$s6stringxSgSS_tcD", + "key.usr" : "s:SY10CommandantAA16ArgumentProtocolRzSy8RawValueSYRpzrlE4from6stringxSgSS_tFZ" + } + ], + "key.typename" : "RawRepresentable.Type", + "key.typeusr" : "$sSY_pmD", + "key.usr" : "s:SY" + }, + { + "key.annotated_decl" : "protocol RawRepresentable<RawValue<\/Type>><\/Declaration>", + "key.bodylength" : 112, + "key.bodyoffset" : 1027, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A type that can be converted to and from an associated raw value.\n\nWith a `RawRepresentable` type, you can switch back and forth between a\ncustom type and an associated `RawValue` type without losing the value of\nthe original `RawRepresentable` type. Using the raw value of a conforming\ntype streamlines interoperation with Objective-C and legacy APIs and\nsimplifies conformance to other protocols, such as `Equatable`,\n`Comparable`, and `Hashable`.\n\nThe `RawRepresentable` protocol is seen mainly in two categories of types:\nenumerations with raw value types and option sets.\n\nEnumerations with Raw Values\n============================\n\nFor any enumeration with a string, integer, or floating-point raw type, the\nSwift compiler automatically adds `RawRepresentable` conformance. When\ndefining your own custom enumeration, you give it a raw type by specifying\nthe raw type as the first item in the enumeration's type inheritance list.\nYou can also use literals to specify values for one or more cases.\n\nFor example, the `Counter` enumeration defined here has an `Int` raw value\ntype and gives the first case a raw value of `1`:\n\n enum Counter: Int {\n case one = 1, two, three, four, five\n }\n\nYou can create a `Counter` instance from an integer value between 1 and 5\nby using the `init?(rawValue:)` initializer declared in the\n`RawRepresentable` protocol. This initializer is failable because although\nevery case of the `Counter` type has a corresponding `Int` value, there\nare many `Int` values that *don't* correspond to a case of `Counter`.\n\n for i in 3...6 {\n print(Counter(rawValue: i))\n }\n \/\/ Prints \"Optional(Counter.three)\"\n \/\/ Prints \"Optional(Counter.four)\"\n \/\/ Prints \"Optional(Counter.five)\"\n \/\/ Prints \"nil\"\n\nOption Sets\n===========\n\nOption sets all conform to `RawRepresentable` by inheritance using the\n`OptionSet` protocol. Whether using an option set or creating your own,\nyou use the raw value of an option set instance to store the instance's\nbitfield. The raw value must therefore be of a type that conforms to the\n`FixedWidthInteger` protocol, such as `UInt8` or `Int`. For example, the\n`Direction` type defines an option set for the four directions you can\nmove in a game.\n\n struct Directions: OptionSet {\n let rawValue: UInt8\n\n static let up = Directions(rawValue: 1 << 0)\n static let down = Directions(rawValue: 1 << 1)\n static let left = Directions(rawValue: 1 << 2)\n static let right = Directions(rawValue: 1 << 3)\n }\n\nUnlike enumerations, option sets provide a nonfailable `init(rawValue:)`\ninitializer to convert from a raw value, because option sets don't have an\nenumerated list of all possible cases. Option set values have\na one-to-one correspondence with their associated raw values.\n\nIn the case of the `Directions` option set, an instance can contain zero,\none, or more of the four defined directions. This example declares a\nconstant with three currently allowed moves. The raw value of the\n`allowedMoves` instance is the result of the bitwise OR of its three\nmembers' raw values:\n\n let allowedMoves: Directions = [.up, .down, .left]\n print(allowedMoves.rawValue)\n \/\/ Prints \"7\"\n\nOption sets use bitwise operations on their associated raw values to\nimplement their mathematical set operations. For example, the `contains()`\nmethod on `allowedMoves` performs a bitwise AND operation to check whether\nthe option set contains an element.\n\n print(allowedMoves.contains(.right))\n \/\/ Prints \"false\"\n print(allowedMoves.rawValue & Directions.right.rawValue)\n \/\/ Prints \"0\"", + "key.doc.declaration" : "protocol RawRepresentable", + "key.doc.discussion" : [ + { + "Para" : "With a `RawRepresentable` type, you can switch back and forth between a custom type and an associated `RawValue` type without losing the value of the original `RawRepresentable` type. Using the raw value of a conforming type streamlines interoperation with Objective-C and legacy APIs and simplifies conformance to other protocols, such as `Equatable`, `Comparable`, and `Hashable`." + }, + { + "Para" : "The `RawRepresentable` protocol is seen mainly in two categories of types: enumerations with raw value types and option sets." + }, + { + "Para" : "For any enumeration with a string, integer, or floating-point raw type, the Swift compiler automatically adds `RawRepresentable` conformance. When defining your own custom enumeration, you give it a raw type by specifying the raw type as the first item in the enumeration’s type inheritance list. You can also use literals to specify values for one or more cases." + }, + { + "Para" : "For example, the `Counter` enumeration defined here has an `Int` raw value type and gives the first case a raw value of `1`:" + }, + { + "CodeListing" : "" + }, + { + "Para" : "You can create a `Counter` instance from an integer value between 1 and 5 by using the `init?(rawValue:)` initializer declared in the `RawRepresentable` protocol. This initializer is failable because although every case of the `Counter` type has a corresponding `Int` value, there are many `Int` values that correspond to a case of `Counter`." + }, + { + "CodeListing" : "" + }, + { + "Para" : "Option sets all conform to `RawRepresentable` by inheritance using the `OptionSet` protocol. Whether using an option set or creating your own, you use the raw value of an option set instance to store the instance’s bitfield. The raw value must therefore be of a type that conforms to the `FixedWidthInteger` protocol, such as `UInt8` or `Int`. For example, the `Direction` type defines an option set for the four directions you can move in a game." + }, + { + "CodeListing" : "" + }, + { + "Para" : "Unlike enumerations, option sets provide a nonfailable `init(rawValue:)` initializer to convert from a raw value, because option sets don’t have an enumerated list of all possible cases. Option set values have a one-to-one correspondence with their associated raw values." + }, + { + "Para" : "In the case of the `Directions` option set, an instance can contain zero, one, or more of the four defined directions. This example declares a constant with three currently allowed moves. The raw value of the `allowedMoves` instance is the result of the bitwise OR of its three members’ raw values:" + }, + { + "CodeListing" : "" + }, + { + "Para" : "Option sets use bitwise operations on their associated raw values to implement their mathematical set operations. For example, the `contains()` method on `allowedMoves` performs a bitwise AND operation to check whether the option set contains an element." + }, + { + "CodeListing" : "" + } + ], + "key.doc.full_as_xml" : "RawRepresentable<\/Name>s:SY<\/USR>protocol RawRepresentable<RawValue><\/Declaration>A type that can be converted to and from an associated raw value.<\/Para><\/Abstract>With a RawRepresentable<\/codeVoice> type, you can switch back and forth between a custom type and an associated RawValue<\/codeVoice> type without losing the value of the original RawRepresentable<\/codeVoice> type. Using the raw value of a conforming type streamlines interoperation with Objective-C and legacy APIs and simplifies conformance to other protocols, such as Equatable<\/codeVoice>, Comparable<\/codeVoice>, and Hashable<\/codeVoice>.<\/Para>The RawRepresentable<\/codeVoice> protocol is seen mainly in two categories of types: enumerations with raw value types and option sets.<\/Para>]]><\/rawHTML>Enumerations with Raw Values]]><\/rawHTML>For any enumeration with a string, integer, or floating-point raw type, the Swift compiler automatically adds RawRepresentable<\/codeVoice> conformance. When defining your own custom enumeration, you give it a raw type by specifying the raw type as the first item in the enumeration’s type inheritance list. You can also use literals to specify values for one or more cases.<\/Para>For example, the Counter<\/codeVoice> enumeration defined here has an Int<\/codeVoice> raw value type and gives the first case a raw value of 1<\/codeVoice>:<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>You can create a Counter<\/codeVoice> instance from an integer value between 1 and 5 by using the init?(rawValue:)<\/codeVoice> initializer declared in the RawRepresentable<\/codeVoice> protocol. This initializer is failable because although every case of the Counter<\/codeVoice> type has a corresponding Int<\/codeVoice> value, there are many Int<\/codeVoice> values that don’t<\/emphasis> correspond to a case of Counter<\/codeVoice>.<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>]]><\/rawHTML>Option Sets]]><\/rawHTML>Option sets all conform to RawRepresentable<\/codeVoice> by inheritance using the OptionSet<\/codeVoice> protocol. Whether using an option set or creating your own, you use the raw value of an option set instance to store the instance’s bitfield. The raw value must therefore be of a type that conforms to the FixedWidthInteger<\/codeVoice> protocol, such as UInt8<\/codeVoice> or Int<\/codeVoice>. For example, the Direction<\/codeVoice> type defines an option set for the four directions you can move in a game.<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>Unlike enumerations, option sets provide a nonfailable init(rawValue:)<\/codeVoice> initializer to convert from a raw value, because option sets don’t have an enumerated list of all possible cases. Option set values have a one-to-one correspondence with their associated raw values.<\/Para>In the case of the Directions<\/codeVoice> option set, an instance can contain zero, one, or more of the four defined directions. This example declares a constant with three currently allowed moves. The raw value of the allowedMoves<\/codeVoice> instance is the result of the bitwise OR of its three members’ raw values:<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>Option sets use bitwise operations on their associated raw values to implement their mathematical set operations. For example, the contains()<\/codeVoice> method on allowedMoves<\/codeVoice> performs a bitwise AND operation to check whether the option set contains an element.<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing><\/Discussion><\/CommentParts><\/Class>", + "key.doc.name" : "RawRepresentable", + "key.doc.type" : "Class", + "key.fully_annotated_decl" : "protocol<\/syntaxtype.keyword> RawRepresentable<\/decl.name><RawValue<\/ref.associatedtype><\/decl.generic_type_param>><\/decl.protocol>", + "key.groupname" : "Protocols", + "key.is_system" : true, + "key.kind" : "source.lang.swift.decl.extension", + "key.length" : 199, + "key.modulename" : "Swift", + "key.name" : "RawRepresentable", + "key.namelength" : 16, + "key.nameoffset" : 951, + "key.offset" : 941, + "key.parsed_declaration" : "extension RawRepresentable where RawValue: FixedWidthInteger, Self: ArgumentProtocol", + "key.parsed_scope.end" : 44, + "key.parsed_scope.start" : 40, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public static func from(string: String<\/Type>) -> Self<\/Type>?<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 1029 + } + ], + "key.bodylength" : 58, + "key.bodyoffset" : 1079, + "key.column" : 21, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> static<\/syntaxtype.keyword> func<\/syntaxtype.keyword> from<\/decl.name>(string<\/decl.var.parameter.argument_label>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>) -> Self<\/ref.generic_type_param>?<\/decl.function.returntype><\/decl.function.method.static>", + "key.is_dynamic" : true, + "key.kind" : "source.lang.swift.decl.function.method.static", + "key.length" : 102, + "key.line" : 41, + "key.modulename" : "Commandant", + "key.name" : "from(string:)", + "key.namelength" : 20, + "key.nameoffset" : 1048, + "key.offset" : 1036, + "key.parsed_declaration" : "public static func from(string: String) -> Self?", + "key.parsed_scope.end" : 43, + "key.parsed_scope.start" : 41, + "key.receivers" : [ + { + "key.usr" : "s:SY" + } + ], + "key.related_decls" : [ + { + "key.annotated_decl" : "from(string: String) -> Self?<\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : " (Self.Type) -> (String) -> Self?", + "key.typeusr" : "$s6stringxSgSS_tcD", + "key.usr" : "s:SY10CommandantAA16ArgumentProtocolRzs17FixedWidthInteger8RawValueSYRpzrlE4from6stringxSgSS_tFZ" + } + ], + "key.typename" : "RawRepresentable.Type", + "key.typeusr" : "$sSY_pmD", + "key.usr" : "s:SY" + } + ] + } +}, { + "\/Sources\/Commandant\/Command.swift" : { + "key.diagnostic_stage" : "source.diagnostic.stage.swift.parse", + "key.length" : 7522, + "key.offset" : 0, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public protocol CommandProtocol<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 247 + } + ], + "key.bodylength" : 483, + "key.bodyoffset" : 280, + "key.column" : 17, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Represents a subcommand that can be executed with its own set of arguments.", + "key.doc.column" : 17, + "key.doc.comment" : "Represents a subcommand that can be executed with its own set of arguments.", + "key.doc.declaration" : "public protocol CommandProtocol", + "key.doc.file" : "\/private\/Sources\/Commandant\/Command.swift", + "key.doc.full_as_xml" : "CommandProtocol<\/Name>s:10Commandant15CommandProtocolP<\/USR>public protocol CommandProtocol<\/Declaration>Represents a subcommand that can be executed with its own set of arguments.<\/Para><\/Abstract><\/CommentParts><\/Class>", + "key.doc.line" : 12, + "key.doc.name" : "CommandProtocol", + "key.doc.type" : "Class", + "key.doclength" : 80, + "key.docoffset" : 167, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> protocol<\/syntaxtype.keyword> CommandProtocol<\/decl.name><\/decl.protocol>", + "key.kind" : "source.lang.swift.decl.protocol", + "key.length" : 510, + "key.line" : 12, + "key.modulename" : "Commandant", + "key.name" : "CommandProtocol", + "key.namelength" : 15, + "key.nameoffset" : 263, + "key.offset" : 254, + "key.parsed_declaration" : "public protocol CommandProtocol", + "key.parsed_scope.end" : 29, + "key.parsed_scope.start" : 12, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "associatedtype Options : OptionsProtocol<\/Type><\/Declaration>", + "key.column" : 17, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "The command's options type.", + "key.doc.column" : 17, + "key.doc.comment" : "The command's options type.", + "key.doc.declaration" : "associatedtype Options : Commandant.OptionsProtocol", + "key.doc.file" : "\/private\/Sources\/Commandant\/Command.swift", + "key.doc.full_as_xml" : "Options<\/Name>s:10Commandant15CommandProtocolP7OptionsQa<\/USR>associatedtype Options : Commandant.OptionsProtocol<\/Declaration>The command’s options type.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 15, + "key.doc.name" : "Options", + "key.doc.type" : "Other", + "key.doclength" : 32, + "key.docoffset" : 283, + "key.filepath" : "", + "key.fully_annotated_decl" : "associatedtype<\/syntaxtype.keyword> Options<\/decl.name> : OptionsProtocol<\/ref.protocol><\/decl.associatedtype>", + "key.is_dynamic" : true, + "key.kind" : "source.lang.swift.decl.associatedtype", + "key.length" : 39, + "key.line" : 15, + "key.modulename" : "Commandant", + "key.name" : "Options", + "key.namelength" : 7, + "key.nameoffset" : 331, + "key.offset" : 316, + "key.parsed_declaration" : "associatedtype Options: OptionsProtocol", + "key.parsed_scope.end" : 15, + "key.parsed_scope.start" : 15, + "key.receivers" : [ + { + "key.usr" : "s:10Commandant15CommandProtocolP" + } + ], + "key.reusingastcontext" : false, + "key.typename" : "Self.Options.Type", + "key.typeusr" : "$s7OptionsQzmD", + "key.usr" : "s:10Commandant15CommandProtocolP7OptionsQa" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "associatedtype ClientError where Self<\/Type>.ClientError<\/Type> == Self<\/Type>.Options<\/Type>.ClientError<\/Type><\/Declaration>", + "key.column" : 17, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "associatedtype<\/syntaxtype.keyword> ClientError<\/decl.name> where<\/syntaxtype.keyword> Self<\/ref.generic_type_param>.ClientError<\/ref.associatedtype> == Self<\/ref.generic_type_param>.Options<\/ref.associatedtype>.ClientError<\/ref.associatedtype><\/decl.generic_type_requirement><\/decl.associatedtype>", + "key.is_dynamic" : true, + "key.kind" : "source.lang.swift.decl.associatedtype", + "key.length" : 67, + "key.line" : 17, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 373, + "key.offset" : 358, + "key.parsed_declaration" : "associatedtype ClientError where ClientError == Options.ClientError", + "key.parsed_scope.end" : 17, + "key.parsed_scope.start" : 17, + "key.receivers" : [ + { + "key.usr" : "s:10Commandant15CommandProtocolP" + } + ], + "key.reusingastcontext" : false, + "key.typename" : "Self.ClientError.Type", + "key.typeusr" : "$s11ClientErrorQzmD", + "key.usr" : "s:10Commandant15CommandProtocolP11ClientErrorQa" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "var verb: String<\/Type> { get }<\/Declaration>", + "key.bodylength" : 5, + "key.bodyoffset" : 532, + "key.column" : 6, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "The action that users should specify to use this subcommand (e.g.,\n`help`).", + "key.doc.column" : 6, + "key.doc.comment" : "The action that users should specify to use this subcommand (e.g.,\n`help`).", + "key.doc.declaration" : "var verb: String { get }", + "key.doc.file" : "\/private\/Sources\/Commandant\/Command.swift", + "key.doc.full_as_xml" : "verb<\/Name>s:10Commandant15CommandProtocolP4verbSSvp<\/USR>var verb: String { get }<\/Declaration>The action that users should specify to use this subcommand (e.g., help<\/codeVoice>).<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 21, + "key.doc.name" : "verb", + "key.doc.type" : "Other", + "key.doclength" : 85, + "key.docoffset" : 428, + "key.filepath" : "", + "key.fully_annotated_decl" : "var<\/syntaxtype.keyword> verb<\/decl.name>: String<\/ref.struct><\/decl.var.type> { get<\/syntaxtype.keyword> }<\/decl.var.instance>", + "key.is_dynamic" : true, + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 24, + "key.line" : 21, + "key.modulename" : "Commandant", + "key.name" : "verb", + "key.namelength" : 4, + "key.nameoffset" : 518, + "key.offset" : 514, + "key.parsed_declaration" : "var verb: String", + "key.parsed_scope.end" : 21, + "key.parsed_scope.start" : 21, + "key.receivers" : [ + { + "key.usr" : "s:10Commandant15CommandProtocolP" + } + ], + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant15CommandProtocolP4verbSSvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "var function: String<\/Type> { get }<\/Declaration>", + "key.bodylength" : 5, + "key.bodyoffset" : 648, + "key.column" : 6, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A human-readable, high-level description of what this command is used\nfor.", + "key.doc.column" : 6, + "key.doc.comment" : "A human-readable, high-level description of what this command is used\nfor.", + "key.doc.declaration" : "var function: String { get }", + "key.doc.file" : "\/private\/Sources\/Commandant\/Command.swift", + "key.doc.full_as_xml" : "function<\/Name>s:10Commandant15CommandProtocolP8functionSSvp<\/USR>var function: String { get }<\/Declaration>A human-readable, high-level description of what this command is used for.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 25, + "key.doc.name" : "function", + "key.doc.type" : "Other", + "key.doclength" : 84, + "key.docoffset" : 541, + "key.filepath" : "", + "key.fully_annotated_decl" : "var<\/syntaxtype.keyword> function<\/decl.name>: String<\/ref.struct><\/decl.var.type> { get<\/syntaxtype.keyword> }<\/decl.var.instance>", + "key.is_dynamic" : true, + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 28, + "key.line" : 25, + "key.modulename" : "Commandant", + "key.name" : "function", + "key.namelength" : 8, + "key.nameoffset" : 630, + "key.offset" : 626, + "key.parsed_declaration" : "var function: String", + "key.parsed_scope.end" : 25, + "key.parsed_scope.start" : 25, + "key.receivers" : [ + { + "key.usr" : "s:10Commandant15CommandProtocolP" + } + ], + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant15CommandProtocolP8functionSSvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "func run(_ options: Options<\/Type>) -> Result<\/Type><(), ClientError<\/Type>><\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Runs this subcommand with the given options.", + "key.doc.column" : 7, + "key.doc.comment" : "Runs this subcommand with the given options.", + "key.doc.declaration" : "func run(_ options: Options) -> Result<(), ClientError>", + "key.doc.file" : "\/private\/Sources\/Commandant\/Command.swift", + "key.doc.full_as_xml" : "run(_:)<\/Name>s:10Commandant15CommandProtocolP3runys6ResultOyyt11ClientErrorQzG7OptionsQzF<\/USR>func run(_ options: Options) -> Result<(), ClientError><\/Declaration>Runs this subcommand with the given options.<\/Para><\/Abstract><\/CommentParts><\/Function>", + "key.doc.line" : 28, + "key.doc.name" : "run(_:)", + "key.doc.type" : "Function", + "key.doclength" : 49, + "key.docoffset" : 657, + "key.filepath" : "", + "key.fully_annotated_decl" : "func<\/syntaxtype.keyword> run<\/decl.name>(_<\/decl.var.parameter.argument_label> options<\/decl.var.parameter.name>: Options<\/ref.associatedtype><\/decl.var.parameter.type><\/decl.var.parameter>) -> Result<\/ref.enum><()<\/tuple>, ClientError<\/ref.associatedtype>><\/decl.function.returntype><\/decl.function.method.instance>", + "key.is_dynamic" : true, + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 55, + "key.line" : 28, + "key.modulename" : "Commandant", + "key.name" : "run(_:)", + "key.namelength" : 23, + "key.nameoffset" : 712, + "key.offset" : 707, + "key.parsed_declaration" : "func run(_ options: Options) -> Result<(), ClientError>", + "key.parsed_scope.end" : 28, + "key.parsed_scope.start" : 28, + "key.receivers" : [ + { + "key.usr" : "s:10Commandant15CommandProtocolP" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : " (Self) -> (Self.Options) -> Result<(), Self.ClientError>", + "key.typeusr" : "$sys6ResultOyyt11ClientErrorQzG7OptionsQzcD", + "key.usr" : "s:10Commandant15CommandProtocolP3runys6ResultOyyt11ClientErrorQzG7OptionsQzF" + } + ], + "key.typename" : "CommandProtocol.Type", + "key.typeusr" : "$s10Commandant15CommandProtocol_pmD", + "key.usr" : "s:10Commandant15CommandProtocolP" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public struct CommandWrapper<ClientError> where ClientError<\/Type> : Error<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 793 + } + ], + "key.bodylength" : 957, + "key.bodyoffset" : 843, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A type-erased command.", + "key.doc.column" : 15, + "key.doc.comment" : "A type-erased command.", + "key.doc.declaration" : "public struct CommandWrapper where ClientError : Error", + "key.doc.file" : "\/private\/Sources\/Commandant\/Command.swift", + "key.doc.full_as_xml" : "CommandWrapper<\/Name>s:10Commandant14CommandWrapperV<\/USR>public struct CommandWrapper<ClientError> where ClientError : Error<\/Declaration>A type-erased command.<\/Para><\/Abstract><\/CommentParts><\/Class>", + "key.doc.line" : 32, + "key.doc.name" : "CommandWrapper", + "key.doc.type" : "Class", + "key.doclength" : 27, + "key.docoffset" : 766, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> struct<\/syntaxtype.keyword> CommandWrapper<\/decl.name><ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>> where<\/syntaxtype.keyword> ClientError<\/ref.generic_type_param> : Error<\/ref.protocol><\/decl.generic_type_requirement><\/decl.struct>", + "key.kind" : "source.lang.swift.decl.struct", + "key.length" : 1001, + "key.line" : 32, + "key.modulename" : "Commandant", + "key.name" : "CommandWrapper", + "key.namelength" : 14, + "key.nameoffset" : 807, + "key.offset" : 800, + "key.parsed_declaration" : "public struct CommandWrapper", + "key.parsed_scope.end" : 65, + "key.parsed_scope.start" : 32, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "ClientError : Error<\/Type><\/Declaration>", + "key.column" : 30, + "key.decl_lang" : "source.lang.swift", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 5, + "key.offset" : 835 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name> : Error<\/ref.protocol><\/decl.generic_type_param.constraint><\/decl.generic_type_param>", + "key.inheritedtypes" : [ + { + "key.name" : "Error" + } + ], + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 18, + "key.line" : 32, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 822, + "key.offset" : 822, + "key.parsed_declaration" : "public struct CommandWrapperpublic let verb: String<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 845 + } + ], + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> let<\/syntaxtype.keyword> verb<\/decl.name>: String<\/ref.struct><\/decl.var.type><\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 16, + "key.line" : 33, + "key.modulename" : "Commandant", + "key.name" : "verb", + "key.namelength" : 4, + "key.nameoffset" : 856, + "key.offset" : 852, + "key.parsed_declaration" : "public let verb: String", + "key.parsed_scope.end" : 33, + "key.parsed_scope.start" : 33, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant14CommandWrapperV4verbSSvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public let function: String<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 870 + } + ], + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> let<\/syntaxtype.keyword> function<\/decl.name>: String<\/ref.struct><\/decl.var.type><\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 20, + "key.line" : 34, + "key.modulename" : "Commandant", + "key.name" : "function", + "key.namelength" : 8, + "key.nameoffset" : 881, + "key.offset" : 877, + "key.parsed_declaration" : "public let function: String", + "key.parsed_scope.end" : 34, + "key.parsed_scope.start" : 34, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant14CommandWrapperV8functionSSvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public let run: (ArgumentParser<\/Type>) -> Result<\/Type><(), CommandantError<\/Type><ClientError<\/Type>>><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 900 + } + ], + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> let<\/syntaxtype.keyword> run<\/decl.name>: (ArgumentParser<\/ref.class><\/decl.var.parameter.type><\/decl.var.parameter>) -> Result<\/ref.enum><()<\/tuple>, CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>>><\/decl.function.returntype><\/decl.var.type><\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 69, + "key.line" : 36, + "key.modulename" : "Commandant", + "key.name" : "run", + "key.namelength" : 3, + "key.nameoffset" : 911, + "key.offset" : 907, + "key.parsed_declaration" : "public let run: (ArgumentParser) -> Result<(), CommandantError>", + "key.parsed_scope.end" : 36, + "key.parsed_scope.start" : 36, + "key.reusingastcontext" : false, + "key.typename" : "(ArgumentParser) -> Result<(), CommandantError>", + "key.typeusr" : "$sys6ResultOyyt10Commandant0B5ErrorOyxGGAC14ArgumentParserCcD", + "key.usr" : "s:10Commandant14CommandWrapperV3runys6ResultOyytAA0A5ErrorOyxGGAA14ArgumentParserCcvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public let usage: () -> CommandantError<\/Type><ClientError<\/Type>>?<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 979 + } + ], + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> let<\/syntaxtype.keyword> usage<\/decl.name>: () -> CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>>?<\/decl.function.returntype><\/decl.var.type><\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 46, + "key.line" : 38, + "key.modulename" : "Commandant", + "key.name" : "usage", + "key.namelength" : 5, + "key.nameoffset" : 990, + "key.offset" : 986, + "key.parsed_declaration" : "public let usage: () -> CommandantError?", + "key.parsed_scope.end" : 38, + "key.parsed_scope.start" : 38, + "key.reusingastcontext" : false, + "key.typename" : "() -> CommandantError?", + "key.typeusr" : "$s10Commandant0A5ErrorOyxGSgycD", + "key.usr" : "s:10Commandant14CommandWrapperV5usageAA0A5ErrorOyxGSgycvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.fileprivate", + "key.annotated_decl" : "fileprivate init<C>(_ command: C<\/Type>) where ClientError<\/Type> == C<\/Type>.ClientError<\/Type>, C<\/Type> : CommandProtocol<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.fileprivate", + "key.length" : 11, + "key.offset" : 1078 + } + ], + "key.bodylength" : 633, + "key.bodyoffset" : 1165, + "key.column" : 14, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Creates a command that wraps another.", + "key.doc.column" : 14, + "key.doc.comment" : "Creates a command that wraps another.", + "key.doc.declaration" : "fileprivate init(_ command: C) where ClientError == C.ClientError, C : Commandant.CommandProtocol", + "key.doc.file" : "\/private\/Sources\/Commandant\/Command.swift", + "key.doc.full_as_xml" : "init(_:)<\/Name>s:10Commandant14CommandWrapperVyACyxGqd__c11ClientErrorQyd__RszAA0B8ProtocolRd__lu33_1DD6990CD6DFDE28F713A55F8EE2B70ELlfc<\/USR>fileprivate init<C>(_ command: C) where ClientError == C.ClientError, C : Commandant.CommandProtocol<\/Declaration>Creates a command that wraps another.<\/Para><\/Abstract><\/CommentParts><\/Function>", + "key.doc.line" : 41, + "key.doc.name" : "init(_:)", + "key.doc.type" : "Function", + "key.doclength" : 42, + "key.docoffset" : 1035, + "key.filepath" : "", + "key.fully_annotated_decl" : "fileprivate<\/syntaxtype.keyword> init<\/syntaxtype.keyword><C<\/decl.generic_type_param.name><\/decl.generic_type_param>>(_<\/decl.var.parameter.argument_label> command<\/decl.var.parameter.name>: C<\/ref.generic_type_param><\/decl.var.parameter.type><\/decl.var.parameter>) where<\/syntaxtype.keyword> ClientError<\/ref.generic_type_param> == C<\/ref.generic_type_param>.ClientError<\/ref.associatedtype><\/decl.generic_type_requirement>, C<\/ref.generic_type_param> : CommandProtocol<\/ref.protocol><\/decl.generic_type_requirement><\/decl.function.constructor>", + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 709, + "key.line" : 41, + "key.modulename" : "Commandant", + "key.name" : "init(_:)", + "key.namelength" : 38, + "key.nameoffset" : 1090, + "key.offset" : 1090, + "key.parsed_declaration" : "fileprivate init(_ command: C) where C.ClientError == ClientError", + "key.parsed_scope.end" : 64, + "key.parsed_scope.start" : 41, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "C : CommandProtocol<\/Type><\/Declaration>", + "key.column" : 19, + "key.decl_lang" : "source.lang.swift", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 15, + "key.offset" : 1098 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "C<\/decl.generic_type_param.name> : CommandProtocol<\/ref.protocol><\/decl.generic_type_param.constraint><\/decl.generic_type_param>", + "key.inheritedtypes" : [ + { + "key.name" : "CommandProtocol" + } + ], + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 18, + "key.line" : 41, + "key.modulename" : "Commandant", + "key.name" : "C", + "key.namelength" : 1, + "key.nameoffset" : 1095, + "key.offset" : 1095, + "key.parsed_declaration" : "fileprivate init (CommandWrapper.Type) -> (C) -> CommandWrapper", + "key.typeusr" : "$sy10Commandant14CommandWrapperVyxGqd__c11ClientErrorQyd__RszAA0B8ProtocolRd__luD", + "key.usr" : "s:10Commandant14CommandWrapperVyACyxGqd__c11ClientErrorQyd__RszAA0B8ProtocolRd__lu33_1DD6990CD6DFDE28F713A55F8EE2B70ELlfc" + } + ], + "key.typename" : "CommandWrapper.Type", + "key.typeusr" : "$s10Commandant14CommandWrapperVyxGmD", + "key.usr" : "s:10Commandant14CommandWrapperV" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public enum CommandMode<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 1859 + } + ], + "key.bodylength" : 216, + "key.bodyoffset" : 1884, + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Describes the \"mode\" in which a command should run.", + "key.doc.column" : 13, + "key.doc.comment" : "Describes the \"mode\" in which a command should run.", + "key.doc.declaration" : "public enum CommandMode", + "key.doc.file" : "\/private\/Sources\/Commandant\/Command.swift", + "key.doc.full_as_xml" : "CommandMode<\/Name>s:10Commandant11CommandModeO<\/USR>public enum CommandMode<\/Declaration>Describes the “mode” in which a command should run.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 68, + "key.doc.name" : "CommandMode", + "key.doc.type" : "Other", + "key.doclength" : 56, + "key.docoffset" : 1803, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> enum<\/syntaxtype.keyword> CommandMode<\/decl.name><\/decl.enum>", + "key.kind" : "source.lang.swift.decl.enum", + "key.length" : 235, + "key.line" : 68, + "key.modulename" : "Commandant", + "key.name" : "CommandMode", + "key.namelength" : 11, + "key.nameoffset" : 1871, + "key.offset" : 1866, + "key.parsed_declaration" : "public enum CommandMode", + "key.parsed_scope.end" : 75, + "key.parsed_scope.start" : 68, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.kind" : "source.lang.swift.decl.enumcase", + "key.length" : 30, + "key.offset" : 1955, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "case arguments(ArgumentParser<\/Type>)<\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Options should be parsed from the given command-line arguments.", + "key.doc.column" : 7, + "key.doc.comment" : "Options should be parsed from the given command-line arguments.", + "key.doc.declaration" : "", + "key.doc.file" : "\/private\/Sources\/Commandant\/Command.swift", + "key.doc.full_as_xml" : "arguments(_:)<\/Name>s:10Commandant11CommandModeO9argumentsyAcA14ArgumentParserCcACmF<\/USR><\/Declaration>Options should be parsed from the given command-line arguments.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 70, + "key.doc.name" : "arguments(_:)", + "key.doc.type" : "Other", + "key.doclength" : 68, + "key.docoffset" : 1886, + "key.filepath" : "", + "key.fully_annotated_decl" : "case<\/syntaxtype.keyword> arguments<\/decl.name>(ArgumentParser<\/ref.class><\/decl.var.parameter.type><\/decl.var.parameter>)<\/decl.enumelement>", + "key.kind" : "source.lang.swift.decl.enumelement", + "key.length" : 25, + "key.line" : 70, + "key.modulename" : "Commandant", + "key.name" : "arguments(_:)", + "key.namelength" : 25, + "key.nameoffset" : 1960, + "key.offset" : 1960, + "key.parsed_declaration" : "case arguments(ArgumentParser)", + "key.parsed_scope.end" : 70, + "key.parsed_scope.start" : 70, + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : "(CommandMode.Type) -> (ArgumentParser) -> CommandMode", + "key.typeusr" : "$sy10Commandant11CommandModeOAA14ArgumentParserCcACmcD", + "key.usr" : "s:10Commandant11CommandModeO9argumentsyAcA14ArgumentParserCcACmF" + } + ] + }, + { + "key.kind" : "source.lang.swift.decl.enumcase", + "key.length" : 10, + "key.offset" : 2089, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "case usage<\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Each option should record its usage information in an error, for\npresentation to the user.", + "key.doc.column" : 7, + "key.doc.comment" : "Each option should record its usage information in an error, for\npresentation to the user.", + "key.doc.declaration" : "", + "key.doc.file" : "\/private\/Sources\/Commandant\/Command.swift", + "key.doc.full_as_xml" : "usage<\/Name>s:10Commandant11CommandModeO5usageyA2CmF<\/USR><\/Declaration>Each option should record its usage information in an error, for presentation to the user.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 74, + "key.doc.name" : "usage", + "key.doc.type" : "Other", + "key.doclength" : 100, + "key.docoffset" : 1988, + "key.filepath" : "", + "key.fully_annotated_decl" : "case<\/syntaxtype.keyword> usage<\/decl.name><\/decl.enumelement>", + "key.kind" : "source.lang.swift.decl.enumelement", + "key.length" : 5, + "key.line" : 74, + "key.modulename" : "Commandant", + "key.name" : "usage", + "key.namelength" : 5, + "key.nameoffset" : 2094, + "key.offset" : 2094, + "key.parsed_declaration" : "case usage", + "key.parsed_scope.end" : 74, + "key.parsed_scope.start" : 74, + "key.reusingastcontext" : false, + "key.typename" : "(CommandMode.Type) -> CommandMode", + "key.typeusr" : "$sy10Commandant11CommandModeOACmcD", + "key.usr" : "s:10Commandant11CommandModeO5usageyA2CmF" + } + ] + } + ], + "key.typename" : "CommandMode.Type", + "key.typeusr" : "$s10Commandant11CommandModeOmD", + "key.usr" : "s:10Commandant11CommandModeO" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public final class CommandRegistry<ClientError> where ClientError<\/Type> : Error<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.final", + "key.length" : 5, + "key.offset" : 2163 + }, + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 2156 + } + ], + "key.bodylength" : 1204, + "key.bodyoffset" : 2212, + "key.column" : 20, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Maintains the list of commands available to run.", + "key.doc.column" : 20, + "key.doc.comment" : "Maintains the list of commands available to run.", + "key.doc.declaration" : "public final class CommandRegistry where ClientError : Error", + "key.doc.file" : "\/private\/Sources\/Commandant\/Command.swift", + "key.doc.full_as_xml" : "CommandRegistry<\/Name>s:10Commandant15CommandRegistryC<\/USR>public final class CommandRegistry<ClientError> where ClientError : Error<\/Declaration>Maintains the list of commands available to run.<\/Para><\/Abstract><\/CommentParts><\/Class>", + "key.doc.line" : 78, + "key.doc.name" : "CommandRegistry", + "key.doc.type" : "Class", + "key.doclength" : 53, + "key.docoffset" : 2103, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> final<\/syntaxtype.keyword> class<\/syntaxtype.keyword> CommandRegistry<\/decl.name><ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>> where<\/syntaxtype.keyword> ClientError<\/ref.generic_type_param> : Error<\/ref.protocol><\/decl.generic_type_requirement><\/decl.class>", + "key.kind" : "source.lang.swift.decl.class", + "key.length" : 1248, + "key.line" : 78, + "key.modulename" : "Commandant", + "key.name" : "CommandRegistry", + "key.namelength" : 15, + "key.nameoffset" : 2175, + "key.offset" : 2169, + "key.parsed_declaration" : "public final class CommandRegistry", + "key.parsed_scope.end" : 116, + "key.parsed_scope.start" : 78, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "ClientError : Error<\/Type><\/Declaration>", + "key.column" : 36, + "key.decl_lang" : "source.lang.swift", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 5, + "key.offset" : 2204 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name> : Error<\/ref.protocol><\/decl.generic_type_param.constraint><\/decl.generic_type_param>", + "key.inheritedtypes" : [ + { + "key.name" : "Error" + } + ], + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 18, + "key.line" : 78, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 2191, + "key.offset" : 2191, + "key.parsed_declaration" : "public final class CommandRegistryprivate var commandsByVerb: [String<\/Type> : CommandWrapper<\/Type><ClientError<\/Type>>]<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.private", + "key.length" : 7, + "key.offset" : 2214 + } + ], + "key.column" : 14, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "private<\/syntaxtype.keyword> var<\/syntaxtype.keyword> commandsByVerb<\/decl.name>: [String<\/ref.struct> : CommandWrapper<\/ref.struct><ClientError<\/ref.generic_type_param>>]<\/decl.var.type><\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 63, + "key.line" : 79, + "key.modulename" : "Commandant", + "key.name" : "commandsByVerb", + "key.namelength" : 14, + "key.nameoffset" : 2226, + "key.offset" : 2222, + "key.parsed_declaration" : "private var commandsByVerb: [String: CommandWrapper] = [:]", + "key.parsed_scope.end" : 79, + "key.parsed_scope.start" : 79, + "key.reusingastcontext" : false, + "key.setter_accessibility" : "source.lang.swift.accessibility.private", + "key.typename" : "[String : CommandWrapper]", + "key.typeusr" : "$sSDySS10Commandant14CommandWrapperVyxGGD", + "key.usr" : "s:10Commandant15CommandRegistryC14commandsByVerb33_1DD6990CD6DFDE28F713A55F8EE2B70ELLSDySSAA0B7WrapperVyxGGvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public var commands: [CommandWrapper<\/Type><ClientError<\/Type>>] { get }<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 2317 + } + ], + "key.bodylength" : 69, + "key.bodyoffset" : 2369, + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "All available commands.", + "key.doc.column" : 13, + "key.doc.comment" : "All available commands.", + "key.doc.declaration" : "public var commands: [CommandWrapper] { get }", + "key.doc.file" : "\/private\/Sources\/Commandant\/Command.swift", + "key.doc.full_as_xml" : "commands<\/Name>s:10Commandant15CommandRegistryC8commandsSayAA0B7WrapperVyxGGvp<\/USR>public var commands: [CommandWrapper<ClientError>] { get }<\/Declaration>All available commands.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 82, + "key.doc.name" : "commands", + "key.doc.type" : "Other", + "key.doclength" : 28, + "key.docoffset" : 2288, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> var<\/syntaxtype.keyword> commands<\/decl.name>: [CommandWrapper<\/ref.struct><ClientError<\/ref.generic_type_param>>]<\/decl.var.type> { get<\/syntaxtype.keyword> }<\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 115, + "key.line" : 82, + "key.modulename" : "Commandant", + "key.name" : "commands", + "key.namelength" : 8, + "key.nameoffset" : 2328, + "key.offset" : 2324, + "key.parsed_declaration" : "public var commands: [CommandWrapper]", + "key.parsed_scope.end" : 84, + "key.parsed_scope.start" : 82, + "key.reusingastcontext" : false, + "key.typename" : "[CommandWrapper]", + "key.typeusr" : "$sSay10Commandant14CommandWrapperVyxGGD", + "key.usr" : "s:10Commandant15CommandRegistryC8commandsSayAA0B7WrapperVyxGGvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public init()<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 2442 + } + ], + "key.bodylength" : 0, + "key.bodyoffset" : 2457, + "key.column" : 9, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> init<\/syntaxtype.keyword>()<\/decl.function.constructor>", + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 9, + "key.line" : 86, + "key.modulename" : "Commandant", + "key.name" : "init()", + "key.namelength" : 6, + "key.nameoffset" : 2449, + "key.offset" : 2449, + "key.parsed_declaration" : "public init()", + "key.parsed_scope.end" : 86, + "key.parsed_scope.start" : 86, + "key.reusingastcontext" : false, + "key.typename" : " (CommandRegistry.Type) -> () -> CommandRegistry", + "key.typeusr" : "$s10Commandant15CommandRegistryCyxGycD", + "key.usr" : "s:10Commandant15CommandRegistryCACyxGycfc" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "@discardableResult public func register<C>(_ commands: C<\/Type>...) -> CommandRegistry<\/Type> where ClientError<\/Type> == C<\/Type>.ClientError<\/Type>, C<\/Type> : CommandProtocol<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 2656 + }, + { + "key.attribute" : "source.decl.attribute.discardableResult", + "key.length" : 18, + "key.offset" : 2636 + } + ], + "key.bodylength" : 106, + "key.bodyoffset" : 2775, + "key.column" : 14, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Registers the given commands, making those available to run.\n\nIf another commands were already registered with the same `verb`s, those\nwill be overwritten.", + "key.doc.column" : 14, + "key.doc.comment" : "Registers the given commands, making those available to run.\n\nIf another commands were already registered with the same `verb`s, those\nwill be overwritten.", + "key.doc.declaration" : "@discardableResult\npublic func register(_ commands: C...) -> CommandRegistry where ClientError == C.ClientError, C : Commandant.CommandProtocol", + "key.doc.discussion" : [ + { + "Para" : "If another commands were already registered with the same `verb`s, those will be overwritten." + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Command.swift", + "key.doc.full_as_xml" : "register(_:)<\/Name>s:10Commandant15CommandRegistryC8registeryACyxGqd__d_t11ClientErrorQyd__RszAA0B8ProtocolRd__lF<\/USR>@discardableResult\npublic func register<C>(_ commands: C...) -> CommandRegistry where ClientError == C.ClientError, C : Commandant.CommandProtocol<\/Declaration>Registers the given commands, making those available to run.<\/Para><\/Abstract>If another commands were already registered with the same verb<\/codeVoice>s, those will be overwritten.<\/Para><\/Discussion><\/CommentParts><\/Function>", + "key.doc.line" : 93, + "key.doc.name" : "register(_:)", + "key.doc.type" : "Function", + "key.doclength" : 174, + "key.docoffset" : 2461, + "key.filepath" : "", + "key.fully_annotated_decl" : "@discardableResult<\/syntaxtype.attribute.name><\/syntaxtype.attribute.builtin> public<\/syntaxtype.keyword> func<\/syntaxtype.keyword> register<\/decl.name><C<\/decl.generic_type_param.name><\/decl.generic_type_param>>(_<\/decl.var.parameter.argument_label> commands<\/decl.var.parameter.name>: C<\/ref.generic_type_param>...<\/decl.var.parameter.type><\/decl.var.parameter>) -> CommandRegistry<\/ref.class><\/decl.function.returntype> where<\/syntaxtype.keyword> ClientError<\/ref.generic_type_param> == C<\/ref.generic_type_param>.ClientError<\/ref.associatedtype><\/decl.generic_type_requirement>, C<\/ref.generic_type_param> : CommandProtocol<\/ref.protocol><\/decl.generic_type_requirement><\/decl.function.method.instance>", + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 219, + "key.line" : 93, + "key.modulename" : "Commandant", + "key.name" : "register(_:)", + "key.namelength" : 46, + "key.nameoffset" : 2668, + "key.offset" : 2663, + "key.parsed_declaration" : "public func register(_ commands: C...)\n\t-> CommandRegistry\n\twhere C.ClientError == ClientError", + "key.parsed_scope.end" : 101, + "key.parsed_scope.start" : 93, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "C : CommandProtocol<\/Type><\/Declaration>", + "key.column" : 23, + "key.decl_lang" : "source.lang.swift", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 15, + "key.offset" : 2680 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "C<\/decl.generic_type_param.name> : CommandProtocol<\/ref.protocol><\/decl.generic_type_param.constraint><\/decl.generic_type_param>", + "key.inheritedtypes" : [ + { + "key.name" : "CommandProtocol" + } + ], + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 18, + "key.line" : 93, + "key.modulename" : "Commandant", + "key.name" : "C", + "key.namelength" : 1, + "key.nameoffset" : 2677, + "key.offset" : 2677, + "key.parsed_declaration" : "public func register (CommandRegistry) -> (C...) -> CommandRegistry", + "key.typeusr" : "$sy10Commandant15CommandRegistryCyxGqd__d_tc11ClientErrorQyd__RszAA0B8ProtocolRd__luD", + "key.usr" : "s:10Commandant15CommandRegistryC8registeryACyxGqd__d_t11ClientErrorQyd__RszAA0B8ProtocolRd__lF" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public func run(command verb: String<\/Type>, arguments: [String<\/Type>]) -> Result<\/Type><(), CommandantError<\/Type><ClientError<\/Type>>>?<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 3059 + } + ], + "key.bodylength" : 54, + "key.bodyoffset" : 3164, + "key.column" : 14, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Runs the command corresponding to the given verb, passing it the given\narguments.\n\nReturns the results of the execution, or nil if no such command exists.", + "key.doc.column" : 14, + "key.doc.comment" : "Runs the command corresponding to the given verb, passing it the given\narguments.\n\nReturns the results of the execution, or nil if no such command exists.", + "key.doc.declaration" : "public func run(command verb: String, arguments: [String]) -> Result<(), CommandantError>?", + "key.doc.discussion" : [ + { + "Para" : "Returns the results of the execution, or nil if no such command exists." + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Command.swift", + "key.doc.full_as_xml" : "run(command:arguments:)<\/Name>s:10Commandant15CommandRegistryC3run7command9argumentss6ResultOyytAA0A5ErrorOyxGGSgSS_SaySSGtF<\/USR>public func run(command verb: String, arguments: [String]) -> Result<(), CommandantError<ClientError>>?<\/Declaration>Runs the command corresponding to the given verb, passing it the given arguments.<\/Para><\/Abstract>Returns the results of the execution, or nil if no such command exists.<\/Para><\/Discussion><\/CommentParts><\/Function>", + "key.doc.line" : 107, + "key.doc.name" : "run(command:arguments:)", + "key.doc.type" : "Function", + "key.doclength" : 173, + "key.docoffset" : 2885, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> func<\/syntaxtype.keyword> run<\/decl.name>(command<\/decl.var.parameter.argument_label> verb<\/decl.var.parameter.name>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>, arguments<\/decl.var.parameter.argument_label>: [String<\/ref.struct>]<\/decl.var.parameter.type><\/decl.var.parameter>) -> Result<\/ref.enum><()<\/tuple>, CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>>>?<\/decl.function.returntype><\/decl.function.method.instance>", + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 153, + "key.line" : 107, + "key.modulename" : "Commandant", + "key.name" : "run(command:arguments:)", + "key.namelength" : 46, + "key.nameoffset" : 3071, + "key.offset" : 3066, + "key.parsed_declaration" : "public func run(command verb: String, arguments: [String]) -> Result<(), CommandantError>?", + "key.parsed_scope.end" : 109, + "key.parsed_scope.start" : 107, + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : " (CommandRegistry) -> (String, [String]) -> Result<(), CommandantError>?", + "key.typeusr" : "$s7command9argumentss6ResultOyyt10Commandant0D5ErrorOyxGGSgSS_SaySSGtcD", + "key.usr" : "s:10Commandant15CommandRegistryC3run7command9argumentss6ResultOyytAA0A5ErrorOyxGGSgSS_SaySSGtF" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public subscript(verb: String<\/Type>) -> CommandWrapper<\/Type><ClientError<\/Type>>? { get }<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 3318 + } + ], + "key.bodylength" : 32, + "key.bodyoffset" : 3382, + "key.column" : 9, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Returns the command matching the given verb, or nil if no such command\nis registered.", + "key.doc.column" : 9, + "key.doc.comment" : "Returns the command matching the given verb, or nil if no such command\nis registered.", + "key.doc.declaration" : "public subscript(verb: String) -> CommandWrapper? { get }", + "key.doc.file" : "\/private\/Sources\/Commandant\/Command.swift", + "key.doc.full_as_xml" : "subscript(_:)<\/Name>s:10Commandant15CommandRegistryCyAA0B7WrapperVyxGSgSScip<\/USR>public subscript(verb: String) -> CommandWrapper<ClientError>? { get }<\/Declaration>Returns the command matching the given verb, or nil if no such command is registered.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 113, + "key.doc.name" : "subscript(_:)", + "key.doc.type" : "Other", + "key.doclength" : 95, + "key.docoffset" : 3222, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> subscript<\/syntaxtype.keyword>(verb<\/decl.var.parameter.name>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>) -> CommandWrapper<\/ref.struct><ClientError<\/ref.generic_type_param>>?<\/decl.function.returntype> { get<\/syntaxtype.keyword> }<\/decl.function.subscript>", + "key.kind" : "source.lang.swift.decl.function.subscript", + "key.length" : 90, + "key.line" : 113, + "key.modulename" : "Commandant", + "key.name" : "subscript(_:)", + "key.namelength" : 23, + "key.nameoffset" : 3325, + "key.offset" : 3325, + "key.parsed_declaration" : "public subscript(verb: String) -> CommandWrapper?", + "key.parsed_scope.end" : 115, + "key.parsed_scope.start" : 113, + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : " (String) -> CommandWrapper?", + "key.typeusr" : "$sy10Commandant14CommandWrapperVyxGSgSScD", + "key.usr" : "s:10Commandant15CommandRegistryCyAA0B7WrapperVyxGSgSScip" + } + ], + "key.typename" : "CommandRegistry.Type", + "key.typeusr" : "$s10Commandant15CommandRegistryCyxGmD", + "key.usr" : "s:10Commandant15CommandRegistryC" + }, + { + "key.annotated_decl" : "public final class CommandRegistry<ClientError> where ClientError<\/Type> : Error<\/Type><\/Declaration>", + "key.bodylength" : 4074, + "key.bodyoffset" : 3446, + "key.column" : 20, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Maintains the list of commands available to run.", + "key.doc.column" : 20, + "key.doc.declaration" : "public final class CommandRegistry where ClientError : Error", + "key.doc.file" : "\/private\/Sources\/Commandant\/Command.swift", + "key.doc.full_as_xml" : "CommandRegistry<\/Name>s:10Commandant15CommandRegistryC<\/USR>public final class CommandRegistry<ClientError> where ClientError : Error<\/Declaration>Maintains the list of commands available to run.<\/Para><\/Abstract><\/CommentParts><\/Class>", + "key.doc.line" : 78, + "key.doc.name" : "CommandRegistry", + "key.doc.type" : "Class", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> final<\/syntaxtype.keyword> class<\/syntaxtype.keyword> CommandRegistry<\/decl.name><ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>> where<\/syntaxtype.keyword> ClientError<\/ref.generic_type_param> : Error<\/ref.protocol><\/decl.generic_type_requirement><\/decl.class>", + "key.kind" : "source.lang.swift.decl.extension", + "key.length" : 4102, + "key.line" : 78, + "key.modulename" : "Commandant", + "key.name" : "CommandRegistry", + "key.namelength" : 15, + "key.nameoffset" : 3429, + "key.offset" : 3419, + "key.parsed_declaration" : "extension CommandRegistry", + "key.parsed_scope.end" : 241, + "key.parsed_scope.start" : 118, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public func main(defaultVerb: String<\/Type>, errorHandler: (ClientError<\/Type>) -> Void<\/Type>) -> Never<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 4246 + } + ], + "key.bodylength" : 97, + "key.bodyoffset" : 4332, + "key.column" : 14, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Hands off execution to the CommandRegistry, by parsing CommandLine.arguments\nand then running whichever command has been identified in the argument\nlist.\n\nIf the chosen command executes successfully, the process will exit with\na successful exit code.\n\nIf the chosen command fails, the provided error handler will be invoked,\nthen the process will exit with a failure exit code.\n\nIf a matching command could not be found but there is any `executable-verb`\nstyle subcommand executable in the caller's `$PATH`, the subcommand will\nbe executed.\n\nIf a matching command could not be found or a usage error occurred,\na helpful error message will be written to `stderr`, then the process\nwill exit with a failure error code.", + "key.doc.column" : 14, + "key.doc.comment" : "Hands off execution to the CommandRegistry, by parsing CommandLine.arguments\nand then running whichever command has been identified in the argument\nlist.\n\nIf the chosen command executes successfully, the process will exit with\na successful exit code.\n\nIf the chosen command fails, the provided error handler will be invoked,\nthen the process will exit with a failure exit code.\n\nIf a matching command could not be found but there is any `executable-verb`\nstyle subcommand executable in the caller's `$PATH`, the subcommand will\nbe executed.\n\nIf a matching command could not be found or a usage error occurred,\na helpful error message will be written to `stderr`, then the process\nwill exit with a failure error code.", + "key.doc.declaration" : "public func main(defaultVerb: String, errorHandler: (ClientError) -> Void) -> Never", + "key.doc.discussion" : [ + { + "Para" : "If the chosen command executes successfully, the process will exit with a successful exit code." + }, + { + "Para" : "If the chosen command fails, the provided error handler will be invoked, then the process will exit with a failure exit code." + }, + { + "Para" : "If a matching command could not be found but there is any `executable-verb` style subcommand executable in the caller’s `$PATH`, the subcommand will be executed." + }, + { + "Para" : "If a matching command could not be found or a usage error occurred, a helpful error message will be written to `stderr`, then the process will exit with a failure error code." + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Command.swift", + "key.doc.full_as_xml" : "main(defaultVerb:errorHandler:)<\/Name>s:10Commandant15CommandRegistryC4main11defaultVerb12errorHandlers5NeverOSS_yxXEtF<\/USR>public func main(defaultVerb: String, errorHandler: (ClientError) -> Void) -> Never<\/Declaration>Hands off execution to the CommandRegistry, by parsing CommandLine.arguments and then running whichever command has been identified in the argument list.<\/Para><\/Abstract>If the chosen command executes successfully, the process will exit with a successful exit code.<\/Para>If the chosen command fails, the provided error handler will be invoked, then the process will exit with a failure exit code.<\/Para>If a matching command could not be found but there is any executable-verb<\/codeVoice> style subcommand executable in the caller’s $PATH<\/codeVoice>, the subcommand will be executed.<\/Para>If a matching command could not be found or a usage error occurred, a helpful error message will be written to stderr<\/codeVoice>, then the process will exit with a failure error code.<\/Para><\/Discussion><\/CommentParts><\/Function>", + "key.doc.line" : 136, + "key.doc.name" : "main(defaultVerb:errorHandler:)", + "key.doc.type" : "Function", + "key.doclength" : 797, + "key.docoffset" : 3448, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> func<\/syntaxtype.keyword> main<\/decl.name>(defaultVerb<\/decl.var.parameter.argument_label>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>, errorHandler<\/decl.var.parameter.argument_label>: (ClientError<\/ref.generic_type_param><\/decl.var.parameter.type><\/decl.var.parameter>) -> Void<\/ref.typealias><\/decl.function.returntype><\/decl.var.parameter.type><\/decl.var.parameter>) -> Never<\/ref.enum><\/decl.function.returntype><\/decl.function.method.instance>", + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 177, + "key.line" : 136, + "key.modulename" : "Commandant", + "key.name" : "main(defaultVerb:errorHandler:)", + "key.namelength" : 62, + "key.nameoffset" : 4258, + "key.offset" : 4253, + "key.parsed_declaration" : "public func main(defaultVerb: String, errorHandler: (ClientError) -> Void) -> Never", + "key.parsed_scope.end" : 138, + "key.parsed_scope.start" : 136, + "key.related_decls" : [ + { + "key.annotated_decl" : "main(arguments:defaultVerb:errorHandler:)<\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : " (CommandRegistry) -> (String, (ClientError) -> ()) -> Never", + "key.typeusr" : "$s11defaultVerb12errorHandlers5NeverOSS_yxXEtcD", + "key.usr" : "s:10Commandant15CommandRegistryC4main11defaultVerb12errorHandlers5NeverOSS_yxXEtF" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public func main(arguments: [String<\/Type>], defaultVerb: String<\/Type>, errorHandler: (ClientError<\/Type>) -> Void<\/Type>) -> Never<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 5221 + } + ], + "key.bodylength" : 945, + "key.bodyoffset" : 5328, + "key.column" : 14, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Hands off execution to the CommandRegistry, by parsing `arguments`\nand then running whichever command has been identified in the argument\nlist.\n\nIf the chosen command executes successfully, the process will exit with\na successful exit code.\n\nIf the chosen command fails, the provided error handler will be invoked,\nthen the process will exit with a failure exit code.\n\nIf a matching command could not be found but there is any `executable-verb`\nstyle subcommand executable in the caller's `$PATH`, the subcommand will\nbe executed.\n\nIf a matching command could not be found or a usage error occurred,\na helpful error message will be written to `stderr`, then the process\nwill exit with a failure error code.", + "key.doc.column" : 14, + "key.doc.comment" : "Hands off execution to the CommandRegistry, by parsing `arguments`\nand then running whichever command has been identified in the argument\nlist.\n\nIf the chosen command executes successfully, the process will exit with\na successful exit code.\n\nIf the chosen command fails, the provided error handler will be invoked,\nthen the process will exit with a failure exit code.\n\nIf a matching command could not be found but there is any `executable-verb`\nstyle subcommand executable in the caller's `$PATH`, the subcommand will\nbe executed.\n\nIf a matching command could not be found or a usage error occurred,\na helpful error message will be written to `stderr`, then the process\nwill exit with a failure error code.", + "key.doc.declaration" : "public func main(arguments: [String], defaultVerb: String, errorHandler: (ClientError) -> Void) -> Never", + "key.doc.discussion" : [ + { + "Para" : "If the chosen command executes successfully, the process will exit with a successful exit code." + }, + { + "Para" : "If the chosen command fails, the provided error handler will be invoked, then the process will exit with a failure exit code." + }, + { + "Para" : "If a matching command could not be found but there is any `executable-verb` style subcommand executable in the caller’s `$PATH`, the subcommand will be executed." + }, + { + "Para" : "If a matching command could not be found or a usage error occurred, a helpful error message will be written to `stderr`, then the process will exit with a failure error code." + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Command.swift", + "key.doc.full_as_xml" : "main(arguments:defaultVerb:errorHandler:)<\/Name>s:10Commandant15CommandRegistryC4main9arguments11defaultVerb12errorHandlers5NeverOSaySSG_SSyxXEtF<\/USR>public func main(arguments: [String], defaultVerb: String, errorHandler: (ClientError) -> Void) -> Never<\/Declaration>Hands off execution to the CommandRegistry, by parsing arguments<\/codeVoice> and then running whichever command has been identified in the argument list.<\/Para><\/Abstract>If the chosen command executes successfully, the process will exit with a successful exit code.<\/Para>If the chosen command fails, the provided error handler will be invoked, then the process will exit with a failure exit code.<\/Para>If a matching command could not be found but there is any executable-verb<\/codeVoice> style subcommand executable in the caller’s $PATH<\/codeVoice>, the subcommand will be executed.<\/Para>If a matching command could not be found or a usage error occurred, a helpful error message will be written to stderr<\/codeVoice>, then the process will exit with a failure error code.<\/Para><\/Discussion><\/CommentParts><\/Function>", + "key.doc.line" : 157, + "key.doc.name" : "main(arguments:defaultVerb:errorHandler:)", + "key.doc.type" : "Function", + "key.doclength" : 787, + "key.docoffset" : 4433, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> func<\/syntaxtype.keyword> main<\/decl.name>(arguments<\/decl.var.parameter.argument_label>: [String<\/ref.struct>]<\/decl.var.parameter.type><\/decl.var.parameter>, defaultVerb<\/decl.var.parameter.argument_label>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>, errorHandler<\/decl.var.parameter.argument_label>: (ClientError<\/ref.generic_type_param><\/decl.var.parameter.type><\/decl.var.parameter>) -> Void<\/ref.typealias><\/decl.function.returntype><\/decl.var.parameter.type><\/decl.var.parameter>) -> Never<\/ref.enum><\/decl.function.returntype><\/decl.function.method.instance>", + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 1046, + "key.line" : 157, + "key.modulename" : "Commandant", + "key.name" : "main(arguments:defaultVerb:errorHandler:)", + "key.namelength" : 83, + "key.nameoffset" : 5233, + "key.offset" : 5228, + "key.parsed_declaration" : "public func main(arguments: [String], defaultVerb: String, errorHandler: (ClientError) -> Void) -> Never", + "key.parsed_scope.end" : 196, + "key.parsed_scope.start" : 157, + "key.related_decls" : [ + { + "key.annotated_decl" : "main(defaultVerb:errorHandler:)<\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "var arguments: [String<\/Type>]<\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "var<\/syntaxtype.keyword> arguments<\/decl.name>: [String<\/ref.struct>]<\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 25, + "key.line" : 160, + "key.modulename" : "Commandant", + "key.name" : "arguments", + "key.namelength" : 9, + "key.nameoffset" : 5367, + "key.offset" : 5363, + "key.parsed_declaration" : "var arguments = arguments", + "key.parsed_scope.end" : 160, + "key.parsed_scope.start" : 160, + "key.reusingastcontext" : false, + "key.typename" : "[String]", + "key.typeusr" : "$sSaySSGD", + "key.usr" : "s:10Commandant15CommandRegistryC4main9arguments11defaultVerb12errorHandlers5NeverOSaySSG_SSyxXEtFAEL0_AJvp" + }, + { + "key.annotated_decl" : "let executableName: String<\/Type><\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "let<\/syntaxtype.keyword> executableName<\/decl.name>: String<\/ref.struct><\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 44, + "key.line" : 163, + "key.modulename" : "Commandant", + "key.name" : "executableName", + "key.namelength" : 14, + "key.nameoffset" : 5430, + "key.offset" : 5426, + "key.parsed_declaration" : "let executableName = arguments.remove(at: 0)", + "key.parsed_scope.end" : 163, + "key.parsed_scope.start" : 163, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant15CommandRegistryC4main9arguments11defaultVerb12errorHandlers5NeverOSaySSG_SSyxXEtF14executableNameL_SSvp" + }, + { + "key.annotated_decl" : "var verb: String<\/Type><\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "var<\/syntaxtype.keyword> verb<\/decl.name>: String<\/ref.struct><\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 22, + "key.line" : 166, + "key.modulename" : "Commandant", + "key.name" : "verb", + "key.namelength" : 4, + "key.nameoffset" : 5536, + "key.offset" : 5532, + "key.parsed_declaration" : "var verb = defaultVerb", + "key.parsed_scope.end" : 166, + "key.parsed_scope.start" : 166, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant15CommandRegistryC4main9arguments11defaultVerb12errorHandlers5NeverOSaySSG_SSyxXEtF4verbL_SSvp" + } + ], + "key.typename" : " (CommandRegistry) -> ([String], String, (ClientError) -> ()) -> Never", + "key.typeusr" : "$s9arguments11defaultVerb12errorHandlers5NeverOSaySSG_SSyxXEtcD", + "key.usr" : "s:10Commandant15CommandRegistryC4main9arguments11defaultVerb12errorHandlers5NeverOSaySSG_SSyxXEtF" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.private", + "key.annotated_decl" : "private func executeSubcommandIfExists(_ executableName: String<\/Type>, verb: String<\/Type>, arguments: [String<\/Type>]) -> Int32<\/Type>?<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.private", + "key.length" : 7, + "key.offset" : 6474 + } + ], + "key.bodylength" : 933, + "key.bodyoffset" : 6585, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Finds and executes a subcommand which exists in your $PATH. The executable\nname must be in the form of `executable-verb`.\n\n- Returns: The exit status of found subcommand or nil.", + "key.doc.column" : 15, + "key.doc.comment" : "Finds and executes a subcommand which exists in your $PATH. The executable\nname must be in the form of `executable-verb`.\n\n- Returns: The exit status of found subcommand or nil.", + "key.doc.declaration" : "private func executeSubcommandIfExists(_ executableName: String, verb: String, arguments: [String]) -> Int32?", + "key.doc.file" : "\/private\/Sources\/Commandant\/Command.swift", + "key.doc.full_as_xml" : "executeSubcommandIfExists(_:verb:arguments:)<\/Name>s:10Commandant15CommandRegistryC25executeSubcommandIfExists33_1DD6990CD6DFDE28F713A55F8EE2B70ELL_4verb9argumentss5Int32VSgSS_SSSaySSGtF<\/USR>private func executeSubcommandIfExists(_ executableName: String, verb: String, arguments: [String]) -> Int32?<\/Declaration>Finds and executes a subcommand which exists in your $PATH. The executable name must be in the form of executable-verb<\/codeVoice>.<\/Para><\/Abstract>The exit status of found subcommand or nil.<\/Para><\/ResultDiscussion><\/CommentParts><\/Function>", + "key.doc.line" : 202, + "key.doc.name" : "executeSubcommandIfExists(_:verb:arguments:)", + "key.doc.result_discussion" : [ + { + "Para" : "The exit status of found subcommand or nil." + } + ], + "key.doc.type" : "Function", + "key.doclength" : 196, + "key.docoffset" : 6277, + "key.filepath" : "", + "key.fully_annotated_decl" : "private<\/syntaxtype.keyword> func<\/syntaxtype.keyword> executeSubcommandIfExists<\/decl.name>(_<\/decl.var.parameter.argument_label> executableName<\/decl.var.parameter.name>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>, verb<\/decl.var.parameter.argument_label>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>, arguments<\/decl.var.parameter.argument_label>: [String<\/ref.struct>]<\/decl.var.parameter.type><\/decl.var.parameter>) -> Int32<\/ref.struct>?<\/decl.function.returntype><\/decl.function.method.instance>", + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 1037, + "key.line" : 202, + "key.modulename" : "Commandant", + "key.name" : "executeSubcommandIfExists(_:verb:arguments:)", + "key.namelength" : 86, + "key.nameoffset" : 6487, + "key.offset" : 6482, + "key.parsed_declaration" : "private func executeSubcommandIfExists(_ executableName: String, verb: String, arguments: [String]) -> Int32?", + "key.parsed_scope.end" : 240, + "key.parsed_scope.start" : 202, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "let subcommand: String<\/Type><\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "let<\/syntaxtype.keyword> subcommand<\/decl.name>: String<\/ref.struct><\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 80, + "key.line" : 203, + "key.modulename" : "Commandant", + "key.name" : "subcommand", + "key.namelength" : 10, + "key.nameoffset" : 6592, + "key.offset" : 6588, + "key.parsed_declaration" : "let subcommand = \"\\(NSString(string: executableName).lastPathComponent)-\\(verb)\"", + "key.parsed_scope.end" : 203, + "key.parsed_scope.start" : 203, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant15CommandRegistryC25executeSubcommandIfExists33_1DD6990CD6DFDE28F713A55F8EE2B70ELL_4verb9argumentss5Int32VSgSS_SSSaySSGtF10subcommandL_SSvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.private", + "key.annotated_decl" : "func launchTask(_ path: String<\/Type>, arguments: [String<\/Type>]) -> Int32<\/Type><\/Declaration>", + "key.bodylength" : 603, + "key.bodyoffset" : 6735, + "key.column" : 8, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "func<\/syntaxtype.keyword> launchTask<\/decl.name>(_<\/decl.var.parameter.argument_label> path<\/decl.var.parameter.name>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>, arguments<\/decl.var.parameter.argument_label>: [String<\/ref.struct>]<\/decl.var.parameter.type><\/decl.var.parameter>) -> Int32<\/ref.struct><\/decl.function.returntype><\/decl.function.free>", + "key.kind" : "source.lang.swift.decl.function.free", + "key.length" : 667, + "key.line" : 205, + "key.modulename" : "Commandant", + "key.name" : "launchTask(_:arguments:)", + "key.namelength" : 47, + "key.nameoffset" : 6677, + "key.offset" : 6672, + "key.parsed_declaration" : "func launchTask(_ path: String, arguments: [String]) -> Int32", + "key.parsed_scope.end" : 233, + "key.parsed_scope.start" : 205, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "let task: Process<\/Type><\/Declaration>", + "key.column" : 8, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "let<\/syntaxtype.keyword> task<\/decl.name>: Process<\/ref.class><\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 20, + "key.line" : 206, + "key.modulename" : "Commandant", + "key.name" : "task", + "key.namelength" : 4, + "key.nameoffset" : 6743, + "key.offset" : 6739, + "key.parsed_declaration" : "let task = Process()", + "key.parsed_scope.end" : 206, + "key.parsed_scope.start" : 206, + "key.reusingastcontext" : false, + "key.typename" : "Process", + "key.typeusr" : "$sSo6NSTaskCD", + "key.usr" : "s:10Commandant15CommandRegistryC25executeSubcommandIfExists33_1DD6990CD6DFDE28F713A55F8EE2B70ELL_4verb9argumentss5Int32VSgSS_SSSaySSGtF10launchTaskL__AgISS_AKts5ErrorRzlF4taskL_So6NSTaskCvp" + } + ], + "key.typename" : " (String, arguments: [String]) -> Int32", + "key.typeusr" : "$s_9argumentss5Int32VSS_SaySSGtcs5ErrorRzluD", + "key.usr" : "s:10Commandant15CommandRegistryC25executeSubcommandIfExists33_1DD6990CD6DFDE28F713A55F8EE2B70ELL_4verb9argumentss5Int32VSgSS_SSSaySSGtF10launchTaskL__AgISS_AKts5ErrorRzlF" + } + ], + "key.typename" : " (CommandRegistry) -> (String, String, [String]) -> Int32?", + "key.typeusr" : "$s_4verb9argumentss5Int32VSgSS_SSSaySSGtcD", + "key.usr" : "s:10Commandant15CommandRegistryC25executeSubcommandIfExists33_1DD6990CD6DFDE28F713A55F8EE2B70ELL_4verb9argumentss5Int32VSgSS_SSSaySSGtF" + } + ], + "key.typename" : "CommandRegistry.Type", + "key.typeusr" : "$s10Commandant15CommandRegistryCyxGmD", + "key.usr" : "s:10Commandant15CommandRegistryC" + } + ] + } +}, { + "\/Sources\/Commandant\/Errors.swift" : { + "key.diagnostic_stage" : "source.diagnostic.stage.swift.parse", + "key.length" : 5739, + "key.offset" : 0, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public enum CommandantError<ClientError> : Error<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 323 + } + ], + "key.bodylength" : 157, + "key.bodyoffset" : 372, + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Possible errors that can originate from Commandant.\n\n`ClientError` should be the type of error (if any) that can occur when\nrunning commands.", + "key.doc.column" : 13, + "key.doc.comment" : "Possible errors that can originate from Commandant.\n\n`ClientError` should be the type of error (if any) that can occur when\nrunning commands.", + "key.doc.declaration" : "public enum CommandantError : Error", + "key.doc.discussion" : [ + { + "Para" : "`ClientError` should be the type of error (if any) that can occur when running commands." + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Errors.swift", + "key.doc.full_as_xml" : "CommandantError<\/Name>s:10Commandant0A5ErrorO<\/USR>public enum CommandantError<ClientError> : Error<\/Declaration>Possible errors that can originate from Commandant.<\/Para><\/Abstract>ClientError<\/codeVoice> should be the type of error (if any) that can occur when running commands.<\/Para><\/Discussion><\/CommentParts><\/Other>", + "key.doc.line" : 15, + "key.doc.name" : "CommandantError", + "key.doc.type" : "Other", + "key.doclength" : 157, + "key.docoffset" : 166, + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 5, + "key.offset" : 365 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> enum<\/syntaxtype.keyword> CommandantError<\/decl.name><ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>> : Error<\/ref.protocol><\/decl.enum>", + "key.inheritedtypes" : [ + { + "key.name" : "Error" + } + ], + "key.kind" : "source.lang.swift.decl.enum", + "key.length" : 200, + "key.line" : 15, + "key.modulename" : "Commandant", + "key.name" : "CommandantError", + "key.namelength" : 15, + "key.nameoffset" : 335, + "key.offset" : 330, + "key.parsed_declaration" : "public enum CommandantError: Error", + "key.parsed_scope.end" : 21, + "key.parsed_scope.start" : 15, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "ClientError<\/Declaration>", + "key.column" : 29, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 15, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 351, + "key.offset" : 351, + "key.parsed_declaration" : "public enum CommandantErrorcase usageError(description: String<\/Type>)<\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "An option was used incorrectly.", + "key.doc.column" : 7, + "key.doc.comment" : "An option was used incorrectly.", + "key.doc.declaration" : "", + "key.doc.file" : "\/private\/Sources\/Commandant\/Errors.swift", + "key.doc.full_as_xml" : "usageError(description:)<\/Name>s:10Commandant0A5ErrorO05usageB0yACyxGSS_tcAEmlF<\/USR><\/Declaration>An option was used incorrectly.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 17, + "key.doc.name" : "usageError(description:)", + "key.doc.type" : "Other", + "key.doclength" : 36, + "key.docoffset" : 374, + "key.filepath" : "", + "key.fully_annotated_decl" : "case<\/syntaxtype.keyword> usageError<\/decl.name>(description<\/decl.var.parameter.argument_label>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>)<\/decl.enumelement>", + "key.kind" : "source.lang.swift.decl.enumelement", + "key.length" : 31, + "key.line" : 17, + "key.modulename" : "Commandant", + "key.name" : "usageError(description:)", + "key.namelength" : 31, + "key.nameoffset" : 416, + "key.offset" : 416, + "key.parsed_declaration" : "case usageError(description: String)", + "key.parsed_scope.end" : 17, + "key.parsed_scope.start" : 17, + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : " (CommandantError.Type) -> (String) -> CommandantError", + "key.typeusr" : "$sy10Commandant0A5ErrorOyxGSS_tcADmcluD", + "key.usr" : "s:10Commandant0A5ErrorO05usageB0yACyxGSS_tcAEmlF" + } + ] + }, + { + "key.kind" : "source.lang.swift.decl.enumcase", + "key.length" : 30, + "key.offset" : 498, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "case commandError(ClientError<\/Type>)<\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "An error occurred while running a command.", + "key.doc.column" : 7, + "key.doc.comment" : "An error occurred while running a command.", + "key.doc.declaration" : "", + "key.doc.file" : "\/private\/Sources\/Commandant\/Errors.swift", + "key.doc.full_as_xml" : "commandError(_:)<\/Name>s:10Commandant0A5ErrorO07commandB0yACyxGxcAEmlF<\/USR><\/Declaration>An error occurred while running a command.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 20, + "key.doc.name" : "commandError(_:)", + "key.doc.type" : "Other", + "key.doclength" : 47, + "key.docoffset" : 450, + "key.filepath" : "", + "key.fully_annotated_decl" : "case<\/syntaxtype.keyword> commandError<\/decl.name>(ClientError<\/ref.generic_type_param><\/decl.var.parameter.type><\/decl.var.parameter>)<\/decl.enumelement>", + "key.kind" : "source.lang.swift.decl.enumelement", + "key.length" : 25, + "key.line" : 20, + "key.modulename" : "Commandant", + "key.name" : "commandError(_:)", + "key.namelength" : 25, + "key.nameoffset" : 503, + "key.offset" : 503, + "key.parsed_declaration" : "case commandError(ClientError)", + "key.parsed_scope.end" : 20, + "key.parsed_scope.start" : 20, + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : " (CommandantError.Type) -> (ClientError) -> CommandantError", + "key.typeusr" : "$sy10Commandant0A5ErrorOyxGxcADmcluD", + "key.usr" : "s:10Commandant0A5ErrorO07commandB0yACyxGxcAEmlF" + } + ] + } + ], + "key.typename" : "CommandantError.Type", + "key.typeusr" : "$s10Commandant0A5ErrorOyxGmD", + "key.usr" : "s:10Commandant0A5ErrorO" + }, + { + "key.annotated_decl" : "public enum CommandantError<ClientError> : Error<\/Type><\/Declaration>", + "key.bodylength" : 187, + "key.bodyoffset" : 584, + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Possible errors that can originate from Commandant.\n\n`ClientError` should be the type of error (if any) that can occur when\nrunning commands.", + "key.doc.column" : 13, + "key.doc.declaration" : "public enum CommandantError : Error", + "key.doc.discussion" : [ + { + "Para" : "`ClientError` should be the type of error (if any) that can occur when running commands." + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Errors.swift", + "key.doc.full_as_xml" : "CommandantError<\/Name>s:10Commandant0A5ErrorO<\/USR>public enum CommandantError<ClientError> : Error<\/Declaration>Possible errors that can originate from Commandant.<\/Para><\/Abstract>ClientError<\/codeVoice> should be the type of error (if any) that can occur when running commands.<\/Para><\/Discussion><\/CommentParts><\/Other>", + "key.doc.line" : 15, + "key.doc.name" : "CommandantError", + "key.doc.type" : "Other", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 23, + "key.offset" : 559 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> enum<\/syntaxtype.keyword> CommandantError<\/decl.name><ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>> : Error<\/ref.protocol><\/decl.enum>", + "key.inheritedtypes" : [ + { + "key.name" : "CustomStringConvertible" + } + ], + "key.kind" : "source.lang.swift.decl.extension", + "key.length" : 240, + "key.line" : 15, + "key.modulename" : "Commandant", + "key.name" : "CommandantError", + "key.namelength" : 15, + "key.nameoffset" : 542, + "key.offset" : 532, + "key.parsed_declaration" : "extension CommandantError: CustomStringConvertible", + "key.parsed_scope.end" : 33, + "key.parsed_scope.start" : 23, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public var description: String<\/Type> { get }<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 586 + } + ], + "key.bodylength" : 151, + "key.bodyoffset" : 618, + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A textual representation of this instance.\n\nCalling this property directly is discouraged. Instead, convert an\ninstance of any type to a string by using the `String(describing:)`\ninitializer. This initializer works with any type, and uses the custom\n`description` property for types that conform to\n`CustomStringConvertible`:\n\n struct Point: CustomStringConvertible {\n let x: Int, y: Int\n\n var description: String {\n return \"(\\(x), \\(y))\"\n }\n }\n\n let p = Point(x: 21, y: 30)\n let s = String(describing: p)\n print(s)\n \/\/ Prints \"(21, 30)\"\n\nThe conversion of `p` to a string in the assignment to `s` uses the\n`Point` type's `description` property.", + "key.doc.declaration" : "var description: String { get }", + "key.doc.discussion" : [ + { + "Para" : "Calling this property directly is discouraged. Instead, convert an instance of any type to a string by using the `String(describing:)` initializer. This initializer works with any type, and uses the custom `description` property for types that conform to `CustomStringConvertible`:" + }, + { + "CodeListing" : "" + }, + { + "Para" : "The conversion of `p` to a string in the assignment to `s` uses the `Point` type’s `description` property." + }, + { + "Note" : "" + } + ], + "key.doc.full_as_xml" : "description<\/Name>s:s23CustomStringConvertibleP11descriptionSSvp<\/USR>var description: String { get }<\/Declaration>A textual representation of this instance.<\/Para><\/Abstract>Calling this property directly is discouraged. Instead, convert an instance of any type to a string by using the String(describing:)<\/codeVoice> initializer. This initializer works with any type, and uses the custom description<\/codeVoice> property for types that conform to CustomStringConvertible<\/codeVoice>:<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>The conversion of p<\/codeVoice> to a string in the assignment to s<\/codeVoice> uses the Point<\/codeVoice> type’s description<\/codeVoice> property.<\/Para>This documentation comment was inherited from CustomStringConvertible<\/codeVoice>.<\/Para><\/Note><\/Discussion><\/CommentParts><\/Other>", + "key.doc.name" : "description", + "key.doc.type" : "Other", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> var<\/syntaxtype.keyword> description<\/decl.name>: String<\/ref.struct><\/decl.var.type> { get<\/syntaxtype.keyword> }<\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 177, + "key.line" : 24, + "key.modulename" : "Commandant", + "key.name" : "description", + "key.namelength" : 11, + "key.nameoffset" : 597, + "key.offset" : 593, + "key.overrides" : [ + { + "key.usr" : "s:s23CustomStringConvertibleP11descriptionSSvp" + } + ], + "key.parsed_declaration" : "public var description: String", + "key.parsed_scope.end" : 32, + "key.parsed_scope.start" : 24, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:s23CustomStringConvertibleP11descriptionSSvp" + } + ], + "key.typename" : "CommandantError.Type", + "key.typeusr" : "$s10Commandant0A5ErrorOyxGmD", + "key.usr" : "s:10Commandant0A5ErrorO" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "internal func missingArgumentError<ClientError>(_ argumentName: String<\/Type>) -> CommandantError<\/Type><ClientError<\/Type>><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.internal", + "key.length" : 8, + "key.offset" : 887 + } + ], + "key.bodylength" : 105, + "key.bodyoffset" : 992, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Constructs an `InvalidArgument` error that indicates a missing value for\nthe argument by the given name.", + "key.doc.column" : 15, + "key.doc.comment" : "Constructs an `InvalidArgument` error that indicates a missing value for\nthe argument by the given name.", + "key.doc.declaration" : "internal func missingArgumentError(_ argumentName: String) -> CommandantError", + "key.doc.file" : "\/private\/Sources\/Commandant\/Errors.swift", + "key.doc.full_as_xml" : "missingArgumentError(_:)<\/Name>s:10Commandant20missingArgumentErroryAA0aD0OyxGSSlF<\/USR>internal func missingArgumentError<ClientError>(_ argumentName: String) -> CommandantError<ClientError><\/Declaration>Constructs an InvalidArgument<\/codeVoice> error that indicates a missing value for the argument by the given name.<\/Para><\/Abstract><\/CommentParts><\/Function>", + "key.doc.line" : 37, + "key.doc.name" : "missingArgumentError(_:)", + "key.doc.type" : "Function", + "key.doclength" : 113, + "key.docoffset" : 774, + "key.filepath" : "", + "key.fully_annotated_decl" : "internal<\/syntaxtype.keyword> func<\/syntaxtype.keyword> missingArgumentError<\/decl.name><ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>>(_<\/decl.var.parameter.argument_label> argumentName<\/decl.var.parameter.name>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>) -> CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>><\/decl.function.returntype><\/decl.function.free>", + "key.kind" : "source.lang.swift.decl.function.free", + "key.length" : 202, + "key.line" : 37, + "key.modulename" : "Commandant", + "key.name" : "missingArgumentError(_:)", + "key.namelength" : 57, + "key.nameoffset" : 901, + "key.offset" : 896, + "key.parsed_declaration" : "internal func missingArgumentError(_ argumentName: String) -> CommandantError", + "key.parsed_scope.end" : 40, + "key.parsed_scope.start" : 37, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "ClientError<\/Declaration>", + "key.column" : 36, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 37, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 922, + "key.offset" : 922, + "key.parsed_declaration" : "internal func missingArgumentErrorlet description: String<\/Type><\/Declaration>", + "key.column" : 6, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "let<\/syntaxtype.keyword> description<\/decl.name>: String<\/ref.struct><\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 56, + "key.line" : 38, + "key.modulename" : "Commandant", + "key.name" : "description", + "key.namelength" : 11, + "key.nameoffset" : 998, + "key.offset" : 994, + "key.parsed_declaration" : "let description = \"Missing argument for \\(argumentName)\"", + "key.parsed_scope.end" : 38, + "key.parsed_scope.start" : 38, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant20missingArgumentErroryAA0aD0OyxGSSlF11descriptionL_SSvp" + } + ], + "key.typename" : " (String) -> CommandantError", + "key.typeusr" : "$sy10Commandant0A5ErrorOyxGSScluD", + "key.usr" : "s:10Commandant20missingArgumentErroryAA0aD0OyxGSSlF" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "internal func informativeUsageError<ClientError>(_ keyValueExample: String<\/Type>, usage: String<\/Type>) -> CommandantError<\/Type><ClientError<\/Type>><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.internal", + "key.length" : 8, + "key.offset" : 1215 + } + ], + "key.bodylength" : 179, + "key.bodyoffset" : 1339, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Constructs an error by combining the example of key (and value, if applicable)\nwith the usage description.", + "key.doc.column" : 15, + "key.doc.comment" : "Constructs an error by combining the example of key (and value, if applicable)\nwith the usage description.", + "key.doc.declaration" : "internal func informativeUsageError(_ keyValueExample: String, usage: String) -> CommandantError", + "key.doc.file" : "\/private\/Sources\/Commandant\/Errors.swift", + "key.doc.full_as_xml" : "informativeUsageError(_:usage:)<\/Name>s:10Commandant21informativeUsageError_5usageAA0aD0OyxGSS_SStlF<\/USR>internal func informativeUsageError<ClientError>(_ keyValueExample: String, usage: String) -> CommandantError<ClientError><\/Declaration>Constructs an error by combining the example of key (and value, if applicable) with the usage description.<\/Para><\/Abstract><\/CommentParts><\/Function>", + "key.doc.line" : 44, + "key.doc.name" : "informativeUsageError(_:usage:)", + "key.doc.type" : "Function", + "key.doclength" : 115, + "key.docoffset" : 1100, + "key.filepath" : "", + "key.fully_annotated_decl" : "internal<\/syntaxtype.keyword> func<\/syntaxtype.keyword> informativeUsageError<\/decl.name><ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>>(_<\/decl.var.parameter.argument_label> keyValueExample<\/decl.var.parameter.name>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>, usage<\/decl.var.parameter.argument_label>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>) -> CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>><\/decl.function.returntype><\/decl.function.free>", + "key.kind" : "source.lang.swift.decl.function.free", + "key.length" : 295, + "key.line" : 44, + "key.modulename" : "Commandant", + "key.name" : "informativeUsageError(_:usage:)", + "key.namelength" : 76, + "key.nameoffset" : 1229, + "key.offset" : 1224, + "key.parsed_declaration" : "internal func informativeUsageError(_ keyValueExample: String, usage: String) -> CommandantError", + "key.parsed_scope.end" : 50, + "key.parsed_scope.start" : 44, + "key.related_decls" : [ + { + "key.annotated_decl" : "informativeUsageError(_:argument:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Argument<T>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Argument<[T]>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError(_:option:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<T>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<T?>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<[T]>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<[T]?>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<ClientError>(_: Option<Bool>) -> CommandantError<ClientError><\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "ClientError<\/Declaration>", + "key.column" : 37, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 44, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 1251, + "key.offset" : 1251, + "key.parsed_declaration" : "internal func informativeUsageErrorlet lines: [String<\/Type>]<\/Declaration>", + "key.column" : 6, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "let<\/syntaxtype.keyword> lines<\/decl.name>: [String<\/ref.struct>]<\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 52, + "key.line" : 45, + "key.modulename" : "Commandant", + "key.name" : "lines", + "key.namelength" : 5, + "key.nameoffset" : 1345, + "key.offset" : 1341, + "key.parsed_declaration" : "let lines = usage.components(separatedBy: .newlines)", + "key.parsed_scope.end" : 45, + "key.parsed_scope.start" : 45, + "key.reusingastcontext" : false, + "key.typename" : "[String]", + "key.typeusr" : "$sSaySSGD", + "key.usr" : "s:10Commandant21informativeUsageError_5usageAA0aD0OyxGSS_SStlF5linesL_SaySSGvp" + } + ], + "key.typename" : " (String, usage: String) -> CommandantError", + "key.typeusr" : "$s_5usage10Commandant0B5ErrorOyxGSS_SStcluD", + "key.usr" : "s:10Commandant21informativeUsageError_5usageAA0aD0OyxGSS_SStlF" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "internal func combineUsageErrors<ClientError>(_ lhs: CommandantError<\/Type><ClientError<\/Type>>, _ rhs: CommandantError<\/Type><ClientError<\/Type>>) -> CommandantError<\/Type><ClientError<\/Type>><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.internal", + "key.length" : 8, + "key.offset" : 1660 + } + ], + "key.bodylength" : 265, + "key.bodyoffset" : 1813, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Combines the text of the two errors, if they're both `UsageError`s.\nOtherwise, uses whichever one is not (biased toward the left).", + "key.doc.column" : 15, + "key.doc.comment" : "Combines the text of the two errors, if they're both `UsageError`s.\nOtherwise, uses whichever one is not (biased toward the left).", + "key.doc.declaration" : "internal func combineUsageErrors(_ lhs: CommandantError, _ rhs: CommandantError) -> CommandantError", + "key.doc.file" : "\/private\/Sources\/Commandant\/Errors.swift", + "key.doc.full_as_xml" : "combineUsageErrors(_:_:)<\/Name>s:10Commandant18combineUsageErrorsyAA0A5ErrorOyxGAE_AEtlF<\/USR>internal func combineUsageErrors<ClientError>(_ lhs: CommandantError<ClientError>, _ rhs: CommandantError<ClientError>) -> CommandantError<ClientError><\/Declaration>Combines the text of the two errors, if they’re both UsageError<\/codeVoice>s. Otherwise, uses whichever one is not (biased toward the left).<\/Para><\/Abstract><\/CommentParts><\/Function>", + "key.doc.line" : 54, + "key.doc.name" : "combineUsageErrors(_:_:)", + "key.doc.type" : "Function", + "key.doclength" : 139, + "key.docoffset" : 1521, + "key.filepath" : "", + "key.fully_annotated_decl" : "internal<\/syntaxtype.keyword> func<\/syntaxtype.keyword> combineUsageErrors<\/decl.name><ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>>(_<\/decl.var.parameter.argument_label> lhs<\/decl.var.parameter.name>: CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>><\/decl.var.parameter.type><\/decl.var.parameter>, _<\/decl.var.parameter.argument_label> rhs<\/decl.var.parameter.name>: CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>><\/decl.var.parameter.type><\/decl.var.parameter>) -> CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>><\/decl.function.returntype><\/decl.function.free>", + "key.kind" : "source.lang.swift.decl.function.free", + "key.length" : 410, + "key.line" : 54, + "key.modulename" : "Commandant", + "key.name" : "combineUsageErrors(_:_:)", + "key.namelength" : 105, + "key.nameoffset" : 1674, + "key.offset" : 1669, + "key.parsed_declaration" : "internal func combineUsageErrors(_ lhs: CommandantError, _ rhs: CommandantError) -> CommandantError", + "key.parsed_scope.end" : 66, + "key.parsed_scope.start" : 54, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "ClientError<\/Declaration>", + "key.column" : 34, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 54, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 1693, + "key.offset" : 1693, + "key.parsed_declaration" : "internal func combineUsageErrors (CommandantError, CommandantError) -> CommandantError", + "key.typeusr" : "$sy10Commandant0A5ErrorOyxGAD_ADtcluD", + "key.usr" : "s:10Commandant18combineUsageErrorsyAA0A5ErrorOyxGAE_AEtlF" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "internal func unrecognizedArgumentsError<ClientError>(_ options: [String<\/Type>]) -> CommandantError<\/Type><ClientError<\/Type>><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.internal", + "key.length" : 8, + "key.offset" : 2152 + } + ], + "key.bodylength" : 96, + "key.bodyoffset" : 2260, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Constructs an error that indicates unrecognized arguments remains.", + "key.doc.column" : 15, + "key.doc.comment" : "Constructs an error that indicates unrecognized arguments remains.", + "key.doc.declaration" : "internal func unrecognizedArgumentsError(_ options: [String]) -> CommandantError", + "key.doc.file" : "\/private\/Sources\/Commandant\/Errors.swift", + "key.doc.full_as_xml" : "unrecognizedArgumentsError(_:)<\/Name>s:10Commandant26unrecognizedArgumentsErroryAA0aD0OyxGSaySSGlF<\/USR>internal func unrecognizedArgumentsError<ClientError>(_ options: [String]) -> CommandantError<ClientError><\/Declaration>Constructs an error that indicates unrecognized arguments remains.<\/Para><\/Abstract><\/CommentParts><\/Function>", + "key.doc.line" : 69, + "key.doc.name" : "unrecognizedArgumentsError(_:)", + "key.doc.type" : "Function", + "key.doclength" : 71, + "key.docoffset" : 2081, + "key.filepath" : "", + "key.fully_annotated_decl" : "internal<\/syntaxtype.keyword> func<\/syntaxtype.keyword> unrecognizedArgumentsError<\/decl.name><ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>>(_<\/decl.var.parameter.argument_label> options<\/decl.var.parameter.name>: [String<\/ref.struct>]<\/decl.var.parameter.type><\/decl.var.parameter>) -> CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>><\/decl.function.returntype><\/decl.function.free>", + "key.kind" : "source.lang.swift.decl.function.free", + "key.length" : 196, + "key.line" : 69, + "key.modulename" : "Commandant", + "key.name" : "unrecognizedArgumentsError(_:)", + "key.namelength" : 60, + "key.nameoffset" : 2166, + "key.offset" : 2161, + "key.parsed_declaration" : "internal func unrecognizedArgumentsError(_ options: [String]) -> CommandantError", + "key.parsed_scope.end" : 71, + "key.parsed_scope.start" : 69, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "ClientError<\/Declaration>", + "key.column" : 42, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 69, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 2193, + "key.offset" : 2193, + "key.parsed_declaration" : "internal func unrecognizedArgumentsError ([String]) -> CommandantError", + "key.typeusr" : "$sy10Commandant0A5ErrorOyxGSaySSGcluD", + "key.usr" : "s:10Commandant26unrecognizedArgumentsErroryAA0aD0OyxGSaySSGlF" + }, + { + "key.kind" : "source.lang.swift.syntaxtype.comment.mark", + "key.length" : 14, + "key.name" : "MARK: Argument", + "key.offset" : 2362 + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "internal func informativeUsageError<T, ClientError>(_ valueExample: String<\/Type>, argument: Argument<\/Type><T<\/Type>>) -> CommandantError<\/Type><ClientError<\/Type>><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.internal", + "key.length" : 8, + "key.offset" : 2499 + } + ], + "key.bodylength" : 192, + "key.bodyoffset" : 2631, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Constructs an error that describes how to use the argument, with the given\nexample of value usage if applicable.", + "key.doc.column" : 15, + "key.doc.comment" : "Constructs an error that describes how to use the argument, with the given\nexample of value usage if applicable.", + "key.doc.declaration" : "internal func informativeUsageError(_ valueExample: String, argument: Argument) -> CommandantError", + "key.doc.file" : "\/private\/Sources\/Commandant\/Errors.swift", + "key.doc.full_as_xml" : "informativeUsageError(_:argument:)<\/Name>s:10Commandant21informativeUsageError_8argumentAA0aD0Oyq_GSS_AA8ArgumentVyxGtr0_lF<\/USR>internal func informativeUsageError<T, ClientError>(_ valueExample: String, argument: Argument<T>) -> CommandantError<ClientError><\/Declaration>Constructs an error that describes how to use the argument, with the given example of value usage if applicable.<\/Para><\/Abstract><\/CommentParts><\/Function>", + "key.doc.line" : 77, + "key.doc.name" : "informativeUsageError(_:argument:)", + "key.doc.type" : "Function", + "key.doclength" : 121, + "key.docoffset" : 2378, + "key.filepath" : "", + "key.fully_annotated_decl" : "internal<\/syntaxtype.keyword> func<\/syntaxtype.keyword> informativeUsageError<\/decl.name><T<\/decl.generic_type_param.name><\/decl.generic_type_param>, ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>>(_<\/decl.var.parameter.argument_label> valueExample<\/decl.var.parameter.name>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>, argument<\/decl.var.parameter.argument_label>: Argument<\/ref.struct><T<\/ref.generic_type_param>><\/decl.var.parameter.type><\/decl.var.parameter>) -> CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>><\/decl.function.returntype><\/decl.function.free>", + "key.kind" : "source.lang.swift.decl.function.free", + "key.length" : 316, + "key.line" : 77, + "key.modulename" : "Commandant", + "key.name" : "informativeUsageError(_:argument:)", + "key.namelength" : 84, + "key.nameoffset" : 2513, + "key.offset" : 2508, + "key.parsed_declaration" : "internal func informativeUsageError(_ valueExample: String, argument: Argument) -> CommandantError", + "key.parsed_scope.end" : 83, + "key.parsed_scope.start" : 77, + "key.related_decls" : [ + { + "key.annotated_decl" : "informativeUsageError(_:usage:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Argument<T>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Argument<[T]>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError(_:option:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<T>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<T?>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<[T]>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<[T]?>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<ClientError>(_: Option<Bool>) -> CommandantError<ClientError><\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "T<\/Declaration>", + "key.column" : 37, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "T<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 1, + "key.line" : 77, + "key.modulename" : "Commandant", + "key.name" : "T", + "key.namelength" : 1, + "key.nameoffset" : 2535, + "key.offset" : 2535, + "key.parsed_declaration" : "internal func informativeUsageErrorClientError<\/Declaration>", + "key.column" : 40, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 77, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 2538, + "key.offset" : 2538, + "key.parsed_declaration" : "internal func informativeUsageError (String, argument: Argument) -> CommandantError", + "key.typeusr" : "$s_8argument10Commandant0B5ErrorOyq_GSS_AB8ArgumentVyxGtcr0_luD", + "key.usr" : "s:10Commandant21informativeUsageError_8argumentAA0aD0Oyq_GSS_AA8ArgumentVyxGtr0_lF" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "internal func informativeUsageError<T, ClientError>(_ argument: Argument<\/Type><T<\/Type>>) -> CommandantError<\/Type><ClientError<\/Type>> where T<\/Type> : ArgumentProtocol<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.internal", + "key.length" : 8, + "key.offset" : 2890 + } + ], + "key.bodylength" : 378, + "key.bodyoffset" : 3018, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Constructs an error that describes how to use the argument.", + "key.doc.column" : 15, + "key.doc.comment" : "Constructs an error that describes how to use the argument.", + "key.doc.declaration" : "internal func informativeUsageError(_ argument: Argument) -> CommandantError where T : Commandant.ArgumentProtocol", + "key.doc.file" : "\/private\/Sources\/Commandant\/Errors.swift", + "key.doc.full_as_xml" : "informativeUsageError(_:)<\/Name>s:10Commandant21informativeUsageErroryAA0aD0Oyq_GAA8ArgumentVyxGAA0E8ProtocolRzr0_lF<\/USR>internal func informativeUsageError<T, ClientError>(_ argument: Argument<T>) -> CommandantError<ClientError> where T : Commandant.ArgumentProtocol<\/Declaration>Constructs an error that describes how to use the argument.<\/Para><\/Abstract><\/CommentParts><\/Function>", + "key.doc.line" : 86, + "key.doc.name" : "informativeUsageError(_:)", + "key.doc.type" : "Function", + "key.doclength" : 64, + "key.docoffset" : 2826, + "key.filepath" : "", + "key.fully_annotated_decl" : "internal<\/syntaxtype.keyword> func<\/syntaxtype.keyword> informativeUsageError<\/decl.name><T<\/decl.generic_type_param.name><\/decl.generic_type_param>, ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>>(_<\/decl.var.parameter.argument_label> argument<\/decl.var.parameter.name>: Argument<\/ref.struct><T<\/ref.generic_type_param>><\/decl.var.parameter.type><\/decl.var.parameter>) -> CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>><\/decl.function.returntype> where<\/syntaxtype.keyword> T<\/ref.generic_type_param> : ArgumentProtocol<\/ref.protocol><\/decl.generic_type_requirement><\/decl.function.free>", + "key.kind" : "source.lang.swift.decl.function.free", + "key.length" : 498, + "key.line" : 86, + "key.modulename" : "Commandant", + "key.name" : "informativeUsageError(_:)", + "key.namelength" : 80, + "key.nameoffset" : 2904, + "key.offset" : 2899, + "key.parsed_declaration" : "internal func informativeUsageError(_ argument: Argument) -> CommandantError", + "key.parsed_scope.end" : 103, + "key.parsed_scope.start" : 86, + "key.related_decls" : [ + { + "key.annotated_decl" : "informativeUsageError(_:usage:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError(_:argument:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Argument<[T]>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError(_:option:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<T>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<T?>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<[T]>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<[T]?>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<ClientError>(_: Option<Bool>) -> CommandantError<ClientError><\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "T : ArgumentProtocol<\/Type><\/Declaration>", + "key.column" : 37, + "key.decl_lang" : "source.lang.swift", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 16, + "key.offset" : 2929 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "T<\/decl.generic_type_param.name> : ArgumentProtocol<\/ref.protocol><\/decl.generic_type_param.constraint><\/decl.generic_type_param>", + "key.inheritedtypes" : [ + { + "key.name" : "ArgumentProtocol" + } + ], + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 19, + "key.line" : 86, + "key.modulename" : "Commandant", + "key.name" : "T", + "key.namelength" : 1, + "key.nameoffset" : 2926, + "key.offset" : 2926, + "key.parsed_declaration" : "internal func informativeUsageErrorClientError<\/Declaration>", + "key.column" : 58, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 86, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 2947, + "key.offset" : 2947, + "key.parsed_declaration" : "internal func informativeUsageErrorvar example: String<\/Type><\/Declaration>", + "key.column" : 6, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "var<\/syntaxtype.keyword> example<\/decl.name>: String<\/ref.struct><\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 16, + "key.line" : 87, + "key.modulename" : "Commandant", + "key.name" : "example", + "key.namelength" : 7, + "key.nameoffset" : 3024, + "key.offset" : 3020, + "key.parsed_declaration" : "var example = \"\"", + "key.parsed_scope.end" : 87, + "key.parsed_scope.start" : 87, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant21informativeUsageErroryAA0aD0Oyq_GAA8ArgumentVyxGAA0E8ProtocolRzr0_lF7exampleL_SSvp" + }, + { + "key.annotated_decl" : "var valueExample: String<\/Type><\/Declaration>", + "key.column" : 6, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "var<\/syntaxtype.keyword> valueExample<\/decl.name>: String<\/ref.struct><\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 21, + "key.line" : 89, + "key.modulename" : "Commandant", + "key.name" : "valueExample", + "key.namelength" : 12, + "key.nameoffset" : 3043, + "key.offset" : 3039, + "key.parsed_declaration" : "var valueExample = \"\"", + "key.parsed_scope.end" : 89, + "key.parsed_scope.start" : 89, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant21informativeUsageErroryAA0aD0Oyq_GAA8ArgumentVyxGAA0E8ProtocolRzr0_lF12valueExampleL_SSvp" + } + ], + "key.typename" : " (Argument) -> CommandantError", + "key.typeusr" : "$sy10Commandant0A5ErrorOyq_GAA8ArgumentVyxGcAA0C8ProtocolRzr0_luD", + "key.usr" : "s:10Commandant21informativeUsageErroryAA0aD0Oyq_GAA8ArgumentVyxGAA0E8ProtocolRzr0_lF" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "internal func informativeUsageError<T, ClientError>(_ argument: Argument<\/Type><[T<\/Type>]>) -> CommandantError<\/Type><ClientError<\/Type>> where T<\/Type> : ArgumentProtocol<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.internal", + "key.length" : 8, + "key.offset" : 3468 + } + ], + "key.bodylength" : 378, + "key.bodyoffset" : 3598, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Constructs an error that describes how to use the argument list.", + "key.doc.column" : 15, + "key.doc.comment" : "Constructs an error that describes how to use the argument list.", + "key.doc.declaration" : "internal func informativeUsageError(_ argument: Argument<[T]>) -> CommandantError where T : Commandant.ArgumentProtocol", + "key.doc.file" : "\/private\/Sources\/Commandant\/Errors.swift", + "key.doc.full_as_xml" : "informativeUsageError(_:)<\/Name>s:10Commandant21informativeUsageErroryAA0aD0Oyq_GAA8ArgumentVySayxGGAA0E8ProtocolRzr0_lF<\/USR>internal func informativeUsageError<T, ClientError>(_ argument: Argument<[T]>) -> CommandantError<ClientError> where T : Commandant.ArgumentProtocol<\/Declaration>Constructs an error that describes how to use the argument list.<\/Para><\/Abstract><\/CommentParts><\/Function>", + "key.doc.line" : 106, + "key.doc.name" : "informativeUsageError(_:)", + "key.doc.type" : "Function", + "key.doclength" : 69, + "key.docoffset" : 3399, + "key.filepath" : "", + "key.fully_annotated_decl" : "internal<\/syntaxtype.keyword> func<\/syntaxtype.keyword> informativeUsageError<\/decl.name><T<\/decl.generic_type_param.name><\/decl.generic_type_param>, ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>>(_<\/decl.var.parameter.argument_label> argument<\/decl.var.parameter.name>: Argument<\/ref.struct><[T<\/ref.generic_type_param>]><\/decl.var.parameter.type><\/decl.var.parameter>) -> CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>><\/decl.function.returntype> where<\/syntaxtype.keyword> T<\/ref.generic_type_param> : ArgumentProtocol<\/ref.protocol><\/decl.generic_type_requirement><\/decl.function.free>", + "key.kind" : "source.lang.swift.decl.function.free", + "key.length" : 500, + "key.line" : 106, + "key.modulename" : "Commandant", + "key.name" : "informativeUsageError(_:)", + "key.namelength" : 82, + "key.nameoffset" : 3482, + "key.offset" : 3477, + "key.parsed_declaration" : "internal func informativeUsageError(_ argument: Argument<[T]>) -> CommandantError", + "key.parsed_scope.end" : 123, + "key.parsed_scope.start" : 106, + "key.related_decls" : [ + { + "key.annotated_decl" : "informativeUsageError(_:usage:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError(_:argument:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Argument<T>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError(_:option:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<T>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<T?>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<[T]>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<[T]?>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<ClientError>(_: Option<Bool>) -> CommandantError<ClientError><\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "T : ArgumentProtocol<\/Type><\/Declaration>", + "key.column" : 37, + "key.decl_lang" : "source.lang.swift", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 16, + "key.offset" : 3507 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "T<\/decl.generic_type_param.name> : ArgumentProtocol<\/ref.protocol><\/decl.generic_type_param.constraint><\/decl.generic_type_param>", + "key.inheritedtypes" : [ + { + "key.name" : "ArgumentProtocol" + } + ], + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 19, + "key.line" : 106, + "key.modulename" : "Commandant", + "key.name" : "T", + "key.namelength" : 1, + "key.nameoffset" : 3504, + "key.offset" : 3504, + "key.parsed_declaration" : "internal func informativeUsageErrorClientError<\/Declaration>", + "key.column" : 58, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 106, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 3525, + "key.offset" : 3525, + "key.parsed_declaration" : "internal func informativeUsageErrorvar example: String<\/Type><\/Declaration>", + "key.column" : 6, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "var<\/syntaxtype.keyword> example<\/decl.name>: String<\/ref.struct><\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 16, + "key.line" : 107, + "key.modulename" : "Commandant", + "key.name" : "example", + "key.namelength" : 7, + "key.nameoffset" : 3604, + "key.offset" : 3600, + "key.parsed_declaration" : "var example = \"\"", + "key.parsed_scope.end" : 107, + "key.parsed_scope.start" : 107, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant21informativeUsageErroryAA0aD0Oyq_GAA8ArgumentVySayxGGAA0E8ProtocolRzr0_lF7exampleL_SSvp" + }, + { + "key.annotated_decl" : "var valueExample: String<\/Type><\/Declaration>", + "key.column" : 6, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "var<\/syntaxtype.keyword> valueExample<\/decl.name>: String<\/ref.struct><\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 21, + "key.line" : 109, + "key.modulename" : "Commandant", + "key.name" : "valueExample", + "key.namelength" : 12, + "key.nameoffset" : 3623, + "key.offset" : 3619, + "key.parsed_declaration" : "var valueExample = \"\"", + "key.parsed_scope.end" : 109, + "key.parsed_scope.start" : 109, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant21informativeUsageErroryAA0aD0Oyq_GAA8ArgumentVySayxGGAA0E8ProtocolRzr0_lF12valueExampleL_SSvp" + } + ], + "key.typename" : " (Argument<[T]>) -> CommandantError", + "key.typeusr" : "$sy10Commandant0A5ErrorOyq_GAA8ArgumentVySayxGGcAA0C8ProtocolRzr0_luD", + "key.usr" : "s:10Commandant21informativeUsageErroryAA0aD0Oyq_GAA8ArgumentVySayxGGAA0E8ProtocolRzr0_lF" + }, + { + "key.kind" : "source.lang.swift.syntaxtype.comment.mark", + "key.length" : 12, + "key.name" : "MARK: Option", + "key.offset" : 3982 + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "internal func informativeUsageError<T, ClientError>(_ keyValueExample: String<\/Type>, option: Option<\/Type><T<\/Type>>) -> CommandantError<\/Type><ClientError<\/Type>><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.internal", + "key.length" : 8, + "key.offset" : 4126 + } + ], + "key.bodylength" : 76, + "key.bodyoffset" : 4257, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Constructs an error that describes how to use the option, with the given\nexample of key (and value, if applicable) usage.", + "key.doc.column" : 15, + "key.doc.comment" : "Constructs an error that describes how to use the option, with the given\nexample of key (and value, if applicable) usage.", + "key.doc.declaration" : "internal func informativeUsageError(_ keyValueExample: String, option: Option) -> CommandantError", + "key.doc.file" : "\/private\/Sources\/Commandant\/Errors.swift", + "key.doc.full_as_xml" : "informativeUsageError(_:option:)<\/Name>s:10Commandant21informativeUsageError_6optionAA0aD0Oyq_GSS_AA6OptionVyxGtr0_lF<\/USR>internal func informativeUsageError<T, ClientError>(_ keyValueExample: String, option: Option<T>) -> CommandantError<ClientError><\/Declaration>Constructs an error that describes how to use the option, with the given example of key (and value, if applicable) usage.<\/Para><\/Abstract><\/CommentParts><\/Function>", + "key.doc.line" : 129, + "key.doc.name" : "informativeUsageError(_:option:)", + "key.doc.type" : "Function", + "key.doclength" : 130, + "key.docoffset" : 3996, + "key.filepath" : "", + "key.fully_annotated_decl" : "internal<\/syntaxtype.keyword> func<\/syntaxtype.keyword> informativeUsageError<\/decl.name><T<\/decl.generic_type_param.name><\/decl.generic_type_param>, ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>>(_<\/decl.var.parameter.argument_label> keyValueExample<\/decl.var.parameter.name>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>, option<\/decl.var.parameter.argument_label>: Option<\/ref.struct><T<\/ref.generic_type_param>><\/decl.var.parameter.type><\/decl.var.parameter>) -> CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>><\/decl.function.returntype><\/decl.function.free>", + "key.kind" : "source.lang.swift.decl.function.free", + "key.length" : 199, + "key.line" : 129, + "key.modulename" : "Commandant", + "key.name" : "informativeUsageError(_:option:)", + "key.namelength" : 83, + "key.nameoffset" : 4140, + "key.offset" : 4135, + "key.parsed_declaration" : "internal func informativeUsageError(_ keyValueExample: String, option: Option) -> CommandantError", + "key.parsed_scope.end" : 131, + "key.parsed_scope.start" : 129, + "key.related_decls" : [ + { + "key.annotated_decl" : "informativeUsageError(_:usage:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError(_:argument:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Argument<T>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Argument<[T]>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<T>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<T?>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<[T]>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<[T]?>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<ClientError>(_: Option<Bool>) -> CommandantError<ClientError><\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "T<\/Declaration>", + "key.column" : 37, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "T<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 1, + "key.line" : 129, + "key.modulename" : "Commandant", + "key.name" : "T", + "key.namelength" : 1, + "key.nameoffset" : 4162, + "key.offset" : 4162, + "key.parsed_declaration" : "internal func informativeUsageErrorClientError<\/Declaration>", + "key.column" : 40, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 129, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 4165, + "key.offset" : 4165, + "key.parsed_declaration" : "internal func informativeUsageError (String, option: Option) -> CommandantError", + "key.typeusr" : "$s_6option10Commandant0B5ErrorOyq_GSS_AB6OptionVyxGtcr0_luD", + "key.usr" : "s:10Commandant21informativeUsageError_6optionAA0aD0Oyq_GSS_AA6OptionVyxGtr0_lF" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "internal func informativeUsageError<T, ClientError>(_ option: Option<\/Type><T<\/Type>>) -> CommandantError<\/Type><ClientError<\/Type>> where T<\/Type> : ArgumentProtocol<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.internal", + "key.length" : 8, + "key.offset" : 4398 + } + ], + "key.bodylength" : 89, + "key.bodyoffset" : 4522, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Constructs an error that describes how to use the option.", + "key.doc.column" : 15, + "key.doc.comment" : "Constructs an error that describes how to use the option.", + "key.doc.declaration" : "internal func informativeUsageError(_ option: Option) -> CommandantError where T : Commandant.ArgumentProtocol", + "key.doc.file" : "\/private\/Sources\/Commandant\/Errors.swift", + "key.doc.full_as_xml" : "informativeUsageError(_:)<\/Name>s:10Commandant21informativeUsageErroryAA0aD0Oyq_GAA6OptionVyxGAA16ArgumentProtocolRzr0_lF<\/USR>internal func informativeUsageError<T, ClientError>(_ option: Option<T>) -> CommandantError<ClientError> where T : Commandant.ArgumentProtocol<\/Declaration>Constructs an error that describes how to use the option.<\/Para><\/Abstract><\/CommentParts><\/Function>", + "key.doc.line" : 134, + "key.doc.name" : "informativeUsageError(_:)", + "key.doc.type" : "Function", + "key.doclength" : 62, + "key.docoffset" : 4336, + "key.filepath" : "", + "key.fully_annotated_decl" : "internal<\/syntaxtype.keyword> func<\/syntaxtype.keyword> informativeUsageError<\/decl.name><T<\/decl.generic_type_param.name><\/decl.generic_type_param>, ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>>(_<\/decl.var.parameter.argument_label> option<\/decl.var.parameter.name>: Option<\/ref.struct><T<\/ref.generic_type_param>><\/decl.var.parameter.type><\/decl.var.parameter>) -> CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>><\/decl.function.returntype> where<\/syntaxtype.keyword> T<\/ref.generic_type_param> : ArgumentProtocol<\/ref.protocol><\/decl.generic_type_requirement><\/decl.function.free>", + "key.kind" : "source.lang.swift.decl.function.free", + "key.length" : 205, + "key.line" : 134, + "key.modulename" : "Commandant", + "key.name" : "informativeUsageError(_:)", + "key.namelength" : 76, + "key.nameoffset" : 4412, + "key.offset" : 4407, + "key.parsed_declaration" : "internal func informativeUsageError(_ option: Option) -> CommandantError", + "key.parsed_scope.end" : 136, + "key.parsed_scope.start" : 134, + "key.related_decls" : [ + { + "key.annotated_decl" : "informativeUsageError(_:usage:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError(_:argument:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Argument<T>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Argument<[T]>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError(_:option:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<T?>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<[T]>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<[T]?>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<ClientError>(_: Option<Bool>) -> CommandantError<ClientError><\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "T : ArgumentProtocol<\/Type><\/Declaration>", + "key.column" : 37, + "key.decl_lang" : "source.lang.swift", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 16, + "key.offset" : 4437 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "T<\/decl.generic_type_param.name> : ArgumentProtocol<\/ref.protocol><\/decl.generic_type_param.constraint><\/decl.generic_type_param>", + "key.inheritedtypes" : [ + { + "key.name" : "ArgumentProtocol" + } + ], + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 19, + "key.line" : 134, + "key.modulename" : "Commandant", + "key.name" : "T", + "key.namelength" : 1, + "key.nameoffset" : 4434, + "key.offset" : 4434, + "key.parsed_declaration" : "internal func informativeUsageErrorClientError<\/Declaration>", + "key.column" : 58, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 134, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 4455, + "key.offset" : 4455, + "key.parsed_declaration" : "internal func informativeUsageError (Option) -> CommandantError", + "key.typeusr" : "$sy10Commandant0A5ErrorOyq_GAA6OptionVyxGcAA16ArgumentProtocolRzr0_luD", + "key.usr" : "s:10Commandant21informativeUsageErroryAA0aD0Oyq_GAA6OptionVyxGAA16ArgumentProtocolRzr0_lF" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "internal func informativeUsageError<T, ClientError>(_ option: Option<\/Type><T<\/Type>?>) -> CommandantError<\/Type><ClientError<\/Type>> where T<\/Type> : ArgumentProtocol<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.internal", + "key.length" : 8, + "key.offset" : 4676 + } + ], + "key.bodylength" : 78, + "key.bodyoffset" : 4801, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Constructs an error that describes how to use the option.", + "key.doc.column" : 15, + "key.doc.comment" : "Constructs an error that describes how to use the option.", + "key.doc.declaration" : "internal func informativeUsageError(_ option: Option) -> CommandantError where T : Commandant.ArgumentProtocol", + "key.doc.file" : "\/private\/Sources\/Commandant\/Errors.swift", + "key.doc.full_as_xml" : "informativeUsageError(_:)<\/Name>s:10Commandant21informativeUsageErroryAA0aD0Oyq_GAA6OptionVyxSgGAA16ArgumentProtocolRzr0_lF<\/USR>internal func informativeUsageError<T, ClientError>(_ option: Option<T?>) -> CommandantError<ClientError> where T : Commandant.ArgumentProtocol<\/Declaration>Constructs an error that describes how to use the option.<\/Para><\/Abstract><\/CommentParts><\/Function>", + "key.doc.line" : 139, + "key.doc.name" : "informativeUsageError(_:)", + "key.doc.type" : "Function", + "key.doclength" : 62, + "key.docoffset" : 4614, + "key.filepath" : "", + "key.fully_annotated_decl" : "internal<\/syntaxtype.keyword> func<\/syntaxtype.keyword> informativeUsageError<\/decl.name><T<\/decl.generic_type_param.name><\/decl.generic_type_param>, ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>>(_<\/decl.var.parameter.argument_label> option<\/decl.var.parameter.name>: Option<\/ref.struct><T<\/ref.generic_type_param>?><\/decl.var.parameter.type><\/decl.var.parameter>) -> CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>><\/decl.function.returntype> where<\/syntaxtype.keyword> T<\/ref.generic_type_param> : ArgumentProtocol<\/ref.protocol><\/decl.generic_type_requirement><\/decl.function.free>", + "key.kind" : "source.lang.swift.decl.function.free", + "key.length" : 195, + "key.line" : 139, + "key.modulename" : "Commandant", + "key.name" : "informativeUsageError(_:)", + "key.namelength" : 77, + "key.nameoffset" : 4690, + "key.offset" : 4685, + "key.parsed_declaration" : "internal func informativeUsageError(_ option: Option) -> CommandantError", + "key.parsed_scope.end" : 141, + "key.parsed_scope.start" : 139, + "key.related_decls" : [ + { + "key.annotated_decl" : "informativeUsageError(_:usage:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError(_:argument:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Argument<T>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Argument<[T]>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError(_:option:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<T>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<[T]>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<[T]?>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<ClientError>(_: Option<Bool>) -> CommandantError<ClientError><\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "T : ArgumentProtocol<\/Type><\/Declaration>", + "key.column" : 37, + "key.decl_lang" : "source.lang.swift", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 16, + "key.offset" : 4715 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "T<\/decl.generic_type_param.name> : ArgumentProtocol<\/ref.protocol><\/decl.generic_type_param.constraint><\/decl.generic_type_param>", + "key.inheritedtypes" : [ + { + "key.name" : "ArgumentProtocol" + } + ], + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 19, + "key.line" : 139, + "key.modulename" : "Commandant", + "key.name" : "T", + "key.namelength" : 1, + "key.nameoffset" : 4712, + "key.offset" : 4712, + "key.parsed_declaration" : "internal func informativeUsageErrorClientError<\/Declaration>", + "key.column" : 58, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 139, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 4733, + "key.offset" : 4733, + "key.parsed_declaration" : "internal func informativeUsageError (Option) -> CommandantError", + "key.typeusr" : "$sy10Commandant0A5ErrorOyq_GAA6OptionVyxSgGcAA16ArgumentProtocolRzr0_luD", + "key.usr" : "s:10Commandant21informativeUsageErroryAA0aD0Oyq_GAA6OptionVyxSgGAA16ArgumentProtocolRzr0_lF" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "internal func informativeUsageError<T, ClientError>(_ option: Option<\/Type><[T<\/Type>]>) -> CommandantError<\/Type><ClientError<\/Type>> where T<\/Type> : ArgumentProtocol<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.internal", + "key.length" : 8, + "key.offset" : 4944 + } + ], + "key.bodylength" : 91, + "key.bodyoffset" : 5070, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Constructs an error that describes how to use the option.", + "key.doc.column" : 15, + "key.doc.comment" : "Constructs an error that describes how to use the option.", + "key.doc.declaration" : "internal func informativeUsageError(_ option: Option<[T]>) -> CommandantError where T : Commandant.ArgumentProtocol", + "key.doc.file" : "\/private\/Sources\/Commandant\/Errors.swift", + "key.doc.full_as_xml" : "informativeUsageError(_:)<\/Name>s:10Commandant21informativeUsageErroryAA0aD0Oyq_GAA6OptionVySayxGGAA16ArgumentProtocolRzr0_lF<\/USR>internal func informativeUsageError<T, ClientError>(_ option: Option<[T]>) -> CommandantError<ClientError> where T : Commandant.ArgumentProtocol<\/Declaration>Constructs an error that describes how to use the option.<\/Para><\/Abstract><\/CommentParts><\/Function>", + "key.doc.line" : 144, + "key.doc.name" : "informativeUsageError(_:)", + "key.doc.type" : "Function", + "key.doclength" : 62, + "key.docoffset" : 4882, + "key.filepath" : "", + "key.fully_annotated_decl" : "internal<\/syntaxtype.keyword> func<\/syntaxtype.keyword> informativeUsageError<\/decl.name><T<\/decl.generic_type_param.name><\/decl.generic_type_param>, ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>>(_<\/decl.var.parameter.argument_label> option<\/decl.var.parameter.name>: Option<\/ref.struct><[T<\/ref.generic_type_param>]><\/decl.var.parameter.type><\/decl.var.parameter>) -> CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>><\/decl.function.returntype> where<\/syntaxtype.keyword> T<\/ref.generic_type_param> : ArgumentProtocol<\/ref.protocol><\/decl.generic_type_requirement><\/decl.function.free>", + "key.kind" : "source.lang.swift.decl.function.free", + "key.length" : 209, + "key.line" : 144, + "key.modulename" : "Commandant", + "key.name" : "informativeUsageError(_:)", + "key.namelength" : 78, + "key.nameoffset" : 4958, + "key.offset" : 4953, + "key.parsed_declaration" : "internal func informativeUsageError(_ option: Option<[T]>) -> CommandantError", + "key.parsed_scope.end" : 146, + "key.parsed_scope.start" : 144, + "key.related_decls" : [ + { + "key.annotated_decl" : "informativeUsageError(_:usage:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError(_:argument:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Argument<T>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Argument<[T]>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError(_:option:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<T>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<T?>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<[T]?>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<ClientError>(_: Option<Bool>) -> CommandantError<ClientError><\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "T : ArgumentProtocol<\/Type><\/Declaration>", + "key.column" : 37, + "key.decl_lang" : "source.lang.swift", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 16, + "key.offset" : 4983 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "T<\/decl.generic_type_param.name> : ArgumentProtocol<\/ref.protocol><\/decl.generic_type_param.constraint><\/decl.generic_type_param>", + "key.inheritedtypes" : [ + { + "key.name" : "ArgumentProtocol" + } + ], + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 19, + "key.line" : 144, + "key.modulename" : "Commandant", + "key.name" : "T", + "key.namelength" : 1, + "key.nameoffset" : 4980, + "key.offset" : 4980, + "key.parsed_declaration" : "internal func informativeUsageErrorClientError<\/Declaration>", + "key.column" : 58, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 144, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 5001, + "key.offset" : 5001, + "key.parsed_declaration" : "internal func informativeUsageError (Option<[T]>) -> CommandantError", + "key.typeusr" : "$sy10Commandant0A5ErrorOyq_GAA6OptionVySayxGGcAA16ArgumentProtocolRzr0_luD", + "key.usr" : "s:10Commandant21informativeUsageErroryAA0aD0Oyq_GAA6OptionVySayxGGAA16ArgumentProtocolRzr0_lF" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "internal func informativeUsageError<T, ClientError>(_ option: Option<\/Type><[T<\/Type>]?>) -> CommandantError<\/Type><ClientError<\/Type>> where T<\/Type> : ArgumentProtocol<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.internal", + "key.length" : 8, + "key.offset" : 5226 + } + ], + "key.bodylength" : 78, + "key.bodyoffset" : 5353, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Constructs an error that describes how to use the option.", + "key.doc.column" : 15, + "key.doc.comment" : "Constructs an error that describes how to use the option.", + "key.doc.declaration" : "internal func informativeUsageError(_ option: Option<[T]?>) -> CommandantError where T : Commandant.ArgumentProtocol", + "key.doc.file" : "\/private\/Sources\/Commandant\/Errors.swift", + "key.doc.full_as_xml" : "informativeUsageError(_:)<\/Name>s:10Commandant21informativeUsageErroryAA0aD0Oyq_GAA6OptionVySayxGSgGAA16ArgumentProtocolRzr0_lF<\/USR>internal func informativeUsageError<T, ClientError>(_ option: Option<[T]?>) -> CommandantError<ClientError> where T : Commandant.ArgumentProtocol<\/Declaration>Constructs an error that describes how to use the option.<\/Para><\/Abstract><\/CommentParts><\/Function>", + "key.doc.line" : 149, + "key.doc.name" : "informativeUsageError(_:)", + "key.doc.type" : "Function", + "key.doclength" : 62, + "key.docoffset" : 5164, + "key.filepath" : "", + "key.fully_annotated_decl" : "internal<\/syntaxtype.keyword> func<\/syntaxtype.keyword> informativeUsageError<\/decl.name><T<\/decl.generic_type_param.name><\/decl.generic_type_param>, ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>>(_<\/decl.var.parameter.argument_label> option<\/decl.var.parameter.name>: Option<\/ref.struct><[T<\/ref.generic_type_param>]?><\/decl.var.parameter.type><\/decl.var.parameter>) -> CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>><\/decl.function.returntype> where<\/syntaxtype.keyword> T<\/ref.generic_type_param> : ArgumentProtocol<\/ref.protocol><\/decl.generic_type_requirement><\/decl.function.free>", + "key.kind" : "source.lang.swift.decl.function.free", + "key.length" : 197, + "key.line" : 149, + "key.modulename" : "Commandant", + "key.name" : "informativeUsageError(_:)", + "key.namelength" : 79, + "key.nameoffset" : 5240, + "key.offset" : 5235, + "key.parsed_declaration" : "internal func informativeUsageError(_ option: Option<[T]?>) -> CommandantError", + "key.parsed_scope.end" : 151, + "key.parsed_scope.start" : 149, + "key.related_decls" : [ + { + "key.annotated_decl" : "informativeUsageError(_:usage:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError(_:argument:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Argument<T>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Argument<[T]>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError(_:option:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<T>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<T?>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<[T]>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<ClientError>(_: Option<Bool>) -> CommandantError<ClientError><\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "T : ArgumentProtocol<\/Type><\/Declaration>", + "key.column" : 37, + "key.decl_lang" : "source.lang.swift", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 16, + "key.offset" : 5265 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "T<\/decl.generic_type_param.name> : ArgumentProtocol<\/ref.protocol><\/decl.generic_type_param.constraint><\/decl.generic_type_param>", + "key.inheritedtypes" : [ + { + "key.name" : "ArgumentProtocol" + } + ], + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 19, + "key.line" : 149, + "key.modulename" : "Commandant", + "key.name" : "T", + "key.namelength" : 1, + "key.nameoffset" : 5262, + "key.offset" : 5262, + "key.parsed_declaration" : "internal func informativeUsageErrorClientError<\/Declaration>", + "key.column" : 58, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 149, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 5283, + "key.offset" : 5283, + "key.parsed_declaration" : "internal func informativeUsageError (Option<[T]?>) -> CommandantError", + "key.typeusr" : "$sy10Commandant0A5ErrorOyq_GAA6OptionVySayxGSgGcAA16ArgumentProtocolRzr0_luD", + "key.usr" : "s:10Commandant21informativeUsageErroryAA0aD0Oyq_GAA6OptionVySayxGSgGAA16ArgumentProtocolRzr0_lF" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "internal func informativeUsageError<ClientError>(_ option: Option<\/Type><Bool<\/Type>>) -> CommandantError<\/Type><ClientError<\/Type>><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.internal", + "key.length" : 8, + "key.offset" : 5510 + } + ], + "key.bodylength" : 121, + "key.bodyoffset" : 5616, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Constructs an error that describes how to use the given boolean option.", + "key.doc.column" : 15, + "key.doc.comment" : "Constructs an error that describes how to use the given boolean option.", + "key.doc.declaration" : "internal func informativeUsageError(_ option: Option) -> CommandantError", + "key.doc.file" : "\/private\/Sources\/Commandant\/Errors.swift", + "key.doc.full_as_xml" : "informativeUsageError(_:)<\/Name>s:10Commandant21informativeUsageErroryAA0aD0OyxGAA6OptionVySbGlF<\/USR>internal func informativeUsageError<ClientError>(_ option: Option<Bool>) -> CommandantError<ClientError><\/Declaration>Constructs an error that describes how to use the given boolean option.<\/Para><\/Abstract><\/CommentParts><\/Function>", + "key.doc.line" : 154, + "key.doc.name" : "informativeUsageError(_:)", + "key.doc.type" : "Function", + "key.doclength" : 76, + "key.docoffset" : 5434, + "key.filepath" : "", + "key.fully_annotated_decl" : "internal<\/syntaxtype.keyword> func<\/syntaxtype.keyword> informativeUsageError<\/decl.name><ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>>(_<\/decl.var.parameter.argument_label> option<\/decl.var.parameter.name>: Option<\/ref.struct><Bool<\/ref.struct>><\/decl.var.parameter.type><\/decl.var.parameter>) -> CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>><\/decl.function.returntype><\/decl.function.free>", + "key.kind" : "source.lang.swift.decl.function.free", + "key.length" : 219, + "key.line" : 154, + "key.modulename" : "Commandant", + "key.name" : "informativeUsageError(_:)", + "key.namelength" : 58, + "key.nameoffset" : 5524, + "key.offset" : 5519, + "key.parsed_declaration" : "internal func informativeUsageError(_ option: Option) -> CommandantError", + "key.parsed_scope.end" : 157, + "key.parsed_scope.start" : 154, + "key.related_decls" : [ + { + "key.annotated_decl" : "informativeUsageError(_:usage:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError(_:argument:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Argument<T>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Argument<[T]>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError(_:option:)<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<T>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<T?>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<[T]>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "informativeUsageError<T, ClientError>(_: Option<[T]?>) -> CommandantError<ClientError> where T : ArgumentProtocol<\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "ClientError<\/Declaration>", + "key.column" : 37, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 154, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 5546, + "key.offset" : 5546, + "key.parsed_declaration" : "internal func informativeUsageErrorlet key: String<\/Type><\/Declaration>", + "key.column" : 6, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "let<\/syntaxtype.keyword> key<\/decl.name>: String<\/ref.struct><\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 20, + "key.line" : 155, + "key.modulename" : "Commandant", + "key.name" : "key", + "key.namelength" : 3, + "key.nameoffset" : 5622, + "key.offset" : 5618, + "key.parsed_declaration" : "let key = option.key", + "key.parsed_scope.end" : 155, + "key.parsed_scope.start" : 155, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant21informativeUsageErroryAA0aD0OyxGAA6OptionVySbGlF3keyL_SSvp" + } + ], + "key.typename" : " (Option) -> CommandantError", + "key.typeusr" : "$sy10Commandant0A5ErrorOyxGAA6OptionVySbGcluD", + "key.usr" : "s:10Commandant21informativeUsageErroryAA0aD0OyxGAA6OptionVySbGlF" + } + ] + } +}, { + "\/Sources\/Commandant\/HelpCommand.swift" : { + "key.diagnostic_stage" : "source.diagnostic.stage.swift.parse", + "key.length" : 2203, + "key.offset" : 0, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public struct HelpCommand<ClientError> : CommandProtocol<\/Type> where ClientError<\/Type> : Error<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 537 + } + ], + "key.bodylength" : 1127, + "key.bodyoffset" : 601, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A basic implementation of a `help` command, using information available in a\n`CommandRegistry`.\n\nIf you want to use this command, initialize it with the registry, then add\nit to that same registry:\n\n\tlet commands: CommandRegistry = …\n\tlet helpCommand = HelpCommand(registry: commands)\n\tcommands.register(helpCommand)", + "key.doc.column" : 15, + "key.doc.comment" : "A basic implementation of a `help` command, using information available in a\n`CommandRegistry`.\n\nIf you want to use this command, initialize it with the registry, then add\nit to that same registry:\n\n\tlet commands: CommandRegistry = …\n\tlet helpCommand = HelpCommand(registry: commands)\n\tcommands.register(helpCommand)", + "key.doc.declaration" : "public struct HelpCommand : CommandProtocol where ClientError : Error", + "key.doc.discussion" : [ + { + "Para" : "If you want to use this command, initialize it with the registry, then add it to that same registry:" + }, + { + "CodeListing" : "" + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/HelpCommand.swift", + "key.doc.full_as_xml" : "HelpCommand<\/Name>s:10Commandant11HelpCommandV<\/USR>public struct HelpCommand<ClientError> : CommandProtocol where ClientError : Error<\/Declaration>A basic implementation of a help<\/codeVoice> command, using information available in a CommandRegistry<\/codeVoice>.<\/Para><\/Abstract>If you want to use this command, initialize it with the registry, then add it to that same registry:<\/Para> = …]]><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing><\/Discussion><\/CommentParts><\/Class>", + "key.doc.line" : 20, + "key.doc.name" : "HelpCommand", + "key.doc.type" : "Class", + "key.doclength" : 366, + "key.docoffset" : 171, + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 15, + "key.offset" : 584 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> struct<\/syntaxtype.keyword> HelpCommand<\/decl.name><ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>> : CommandProtocol<\/ref.protocol> where<\/syntaxtype.keyword> ClientError<\/ref.generic_type_param> : Error<\/ref.protocol><\/decl.generic_type_requirement><\/decl.struct>", + "key.inheritedtypes" : [ + { + "key.name" : "CommandProtocol" + } + ], + "key.kind" : "source.lang.swift.decl.struct", + "key.length" : 1185, + "key.line" : 20, + "key.modulename" : "Commandant", + "key.name" : "HelpCommand", + "key.namelength" : 11, + "key.nameoffset" : 551, + "key.offset" : 544, + "key.parsed_declaration" : "public struct HelpCommand: CommandProtocol", + "key.parsed_scope.end" : 59, + "key.parsed_scope.start" : 20, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "ClientError : Error<\/Type><\/Declaration>", + "key.column" : 27, + "key.decl_lang" : "source.lang.swift", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 5, + "key.offset" : 576 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name> : Error<\/ref.protocol><\/decl.generic_type_param.constraint><\/decl.generic_type_param>", + "key.inheritedtypes" : [ + { + "key.name" : "Error" + } + ], + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 18, + "key.line" : 20, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 563, + "key.offset" : 563, + "key.parsed_declaration" : "public struct HelpCommandClientError<\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.typename" : "ClientError.Type", + "key.typeusr" : "$sxmD", + "key.usr" : "s:10Commandant11HelpCommandV11ClientErrorxmfp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public typealias HelpCommand<\/Type><ClientError<\/Type>>.Options = HelpOptions<\/Type><ClientError<\/Type>><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 603 + } + ], + "key.column" : 19, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "The command's options type.", + "key.doc.column" : 17, + "key.doc.declaration" : "associatedtype Options : Commandant.OptionsProtocol", + "key.doc.discussion" : [ + { + "Note" : "" + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Command.swift", + "key.doc.full_as_xml" : "Options<\/Name>s:10Commandant15CommandProtocolP7OptionsQa<\/USR>associatedtype Options : Commandant.OptionsProtocol<\/Declaration>The command’s options type.<\/Para><\/Abstract>This documentation comment was inherited from CommandProtocol<\/codeVoice>.<\/Para><\/Note><\/Discussion><\/CommentParts><\/Other>", + "key.doc.line" : 15, + "key.doc.name" : "Options", + "key.doc.type" : "Other", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> typealias<\/syntaxtype.keyword> HelpCommand<\/ref.struct><ClientError<\/ref.generic_type_param>>.Options<\/decl.name> = HelpOptions<\/ref.struct><ClientError<\/ref.generic_type_param>><\/decl.typealias>", + "key.kind" : "source.lang.swift.decl.typealias", + "key.length" : 44, + "key.line" : 21, + "key.modulename" : "Commandant", + "key.name" : "Options", + "key.namelength" : 7, + "key.nameoffset" : 620, + "key.offset" : 610, + "key.overrides" : [ + { + "key.usr" : "s:10Commandant15CommandProtocolP7OptionsQa" + } + ], + "key.parsed_declaration" : "public typealias Options = HelpOptions", + "key.parsed_scope.end" : 21, + "key.parsed_scope.start" : 21, + "key.reusingastcontext" : false, + "key.typename" : "HelpOptions.Type", + "key.typeusr" : "$s10Commandant11HelpOptionsVyxGmD", + "key.usr" : "s:10Commandant15CommandProtocolP7OptionsQa" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public let verb: String<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 657 + } + ], + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "The action that users should specify to use this subcommand (e.g.,\n`help`).", + "key.doc.column" : 6, + "key.doc.declaration" : "var verb: String { get }", + "key.doc.discussion" : [ + { + "Note" : "" + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Command.swift", + "key.doc.full_as_xml" : "verb<\/Name>s:10Commandant15CommandProtocolP4verbSSvp<\/USR>var verb: String { get }<\/Declaration>The action that users should specify to use this subcommand (e.g., help<\/codeVoice>).<\/Para><\/Abstract>This documentation comment was inherited from CommandProtocol<\/codeVoice>.<\/Para><\/Note><\/Discussion><\/CommentParts><\/Other>", + "key.doc.line" : 21, + "key.doc.name" : "verb", + "key.doc.type" : "Other", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> let<\/syntaxtype.keyword> verb<\/decl.name>: String<\/ref.struct><\/decl.var.type><\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 17, + "key.line" : 23, + "key.modulename" : "Commandant", + "key.name" : "verb", + "key.namelength" : 4, + "key.nameoffset" : 668, + "key.offset" : 664, + "key.overrides" : [ + { + "key.usr" : "s:10Commandant15CommandProtocolP4verbSSvp" + } + ], + "key.parsed_declaration" : "public let verb = \"help\"", + "key.parsed_scope.end" : 23, + "key.parsed_scope.start" : 23, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant15CommandProtocolP4verbSSvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public let function: String<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 683 + } + ], + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A human-readable, high-level description of what this command is used\nfor.", + "key.doc.column" : 6, + "key.doc.declaration" : "var function: String { get }", + "key.doc.discussion" : [ + { + "Note" : "" + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Command.swift", + "key.doc.full_as_xml" : "function<\/Name>s:10Commandant15CommandProtocolP8functionSSvp<\/USR>var function: String { get }<\/Declaration>A human-readable, high-level description of what this command is used for.<\/Para><\/Abstract>This documentation comment was inherited from CommandProtocol<\/codeVoice>.<\/Para><\/Note><\/Discussion><\/CommentParts><\/Other>", + "key.doc.line" : 25, + "key.doc.name" : "function", + "key.doc.type" : "Other", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> let<\/syntaxtype.keyword> function<\/decl.name>: String<\/ref.struct><\/decl.var.type><\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 20, + "key.line" : 24, + "key.modulename" : "Commandant", + "key.name" : "function", + "key.namelength" : 8, + "key.nameoffset" : 694, + "key.offset" : 690, + "key.overrides" : [ + { + "key.usr" : "s:10Commandant15CommandProtocolP8functionSSvp" + } + ], + "key.parsed_declaration" : "public let function: String", + "key.parsed_scope.end" : 24, + "key.parsed_scope.start" : 24, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant15CommandProtocolP8functionSSvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.private", + "key.annotated_decl" : "private let registry: CommandRegistry<\/Type><ClientError<\/Type>><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.private", + "key.length" : 7, + "key.offset" : 713 + } + ], + "key.column" : 14, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "private<\/syntaxtype.keyword> let<\/syntaxtype.keyword> registry<\/decl.name>: CommandRegistry<\/ref.class><ClientError<\/ref.generic_type_param>><\/decl.var.type><\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 42, + "key.line" : 26, + "key.modulename" : "Commandant", + "key.name" : "registry", + "key.namelength" : 8, + "key.nameoffset" : 725, + "key.offset" : 721, + "key.parsed_declaration" : "private let registry: CommandRegistry", + "key.parsed_scope.end" : 26, + "key.parsed_scope.start" : 26, + "key.reusingastcontext" : false, + "key.typename" : "CommandRegistry", + "key.typeusr" : "$s10Commandant15CommandRegistryCyxGD", + "key.usr" : "s:10Commandant11HelpCommandV8registry33_38F61CE0DF9D73793CEDF5D1C3140331LLAA0C8RegistryCyxGvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public init(registry: CommandRegistry<\/Type><ClientError<\/Type>>, function: String<\/Type>? = nil)<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 853 + } + ], + "key.bodylength" : 102, + "key.bodyoffset" : 931, + "key.column" : 9, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Initializes the command to provide help from the given registry of\ncommands.", + "key.doc.column" : 9, + "key.doc.comment" : "Initializes the command to provide help from the given registry of\ncommands.", + "key.doc.declaration" : "public init(registry: CommandRegistry, function: String? = nil)", + "key.doc.file" : "\/private\/Sources\/Commandant\/HelpCommand.swift", + "key.doc.full_as_xml" : "init(registry:function:)<\/Name>s:10Commandant11HelpCommandV8registry8functionACyxGAA0C8RegistryCyxG_SSSgtcfc<\/USR>public init(registry: CommandRegistry<ClientError>, function: String? = nil)<\/Declaration>Initializes the command to provide help from the given registry of commands.<\/Para><\/Abstract><\/CommentParts><\/Function>", + "key.doc.line" : 30, + "key.doc.name" : "init(registry:function:)", + "key.doc.type" : "Function", + "key.doclength" : 86, + "key.docoffset" : 766, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> init<\/syntaxtype.keyword>(registry<\/decl.var.parameter.argument_label>: CommandRegistry<\/ref.class><ClientError<\/ref.generic_type_param>><\/decl.var.parameter.type><\/decl.var.parameter>, function<\/decl.var.parameter.argument_label>: String<\/ref.struct>?<\/decl.var.parameter.type> = nil<\/decl.var.parameter>)<\/decl.function.constructor>", + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 174, + "key.line" : 30, + "key.modulename" : "Commandant", + "key.name" : "init(registry:function:)", + "key.namelength" : 69, + "key.nameoffset" : 860, + "key.offset" : 860, + "key.parsed_declaration" : "public init(registry: CommandRegistry, function: String? = nil)", + "key.parsed_scope.end" : 33, + "key.parsed_scope.start" : 30, + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : " (HelpCommand.Type) -> (CommandRegistry, String?) -> HelpCommand", + "key.typeusr" : "$s8registry8function10Commandant11HelpCommandVyxGAC0E8RegistryCyxG_SSSgtcD", + "key.usr" : "s:10Commandant11HelpCommandV8registry8functionACyxGAA0C8RegistryCyxG_SSSgtcfc" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public func run(_ options: Options<\/Type>) -> Result<\/Type><(), ClientError<\/Type>><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 1037 + } + ], + "key.bodylength" : 625, + "key.bodyoffset" : 1101, + "key.column" : 14, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Runs this subcommand with the given options.", + "key.doc.column" : 7, + "key.doc.declaration" : "func run(_ options: Options) -> Result<(), ClientError>", + "key.doc.discussion" : [ + { + "Note" : "" + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Command.swift", + "key.doc.full_as_xml" : "run(_:)<\/Name>s:10Commandant15CommandProtocolP3runys6ResultOyyt11ClientErrorQzG7OptionsQzF<\/USR>func run(_ options: Options) -> Result<(), ClientError><\/Declaration>Runs this subcommand with the given options.<\/Para><\/Abstract>This documentation comment was inherited from CommandProtocol<\/codeVoice>.<\/Para><\/Note><\/Discussion><\/CommentParts><\/Function>", + "key.doc.line" : 28, + "key.doc.name" : "run(_:)", + "key.doc.type" : "Function", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> func<\/syntaxtype.keyword> run<\/decl.name>(_<\/decl.var.parameter.argument_label> options<\/decl.var.parameter.name>: Options<\/ref.typealias><\/decl.var.parameter.type><\/decl.var.parameter>) -> Result<\/ref.enum><()<\/tuple>, ClientError<\/ref.generic_type_param>><\/decl.function.returntype><\/decl.function.method.instance>", + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 683, + "key.line" : 35, + "key.modulename" : "Commandant", + "key.name" : "run(_:)", + "key.namelength" : 23, + "key.nameoffset" : 1049, + "key.offset" : 1044, + "key.overrides" : [ + { + "key.usr" : "s:10Commandant15CommandProtocolP3runys6ResultOyyt11ClientErrorQzG7OptionsQzF" + } + ], + "key.parsed_declaration" : "public func run(_ options: Options) -> Result<(), ClientError>", + "key.parsed_scope.end" : 58, + "key.parsed_scope.start" : 35, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "let maxVerbLength: Int<\/Type><\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "let<\/syntaxtype.keyword> maxVerbLength<\/decl.name>: Int<\/ref.struct><\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 75, + "key.line" : 50, + "key.modulename" : "Commandant", + "key.name" : "maxVerbLength", + "key.namelength" : 13, + "key.nameoffset" : 1422, + "key.offset" : 1418, + "key.parsed_declaration" : "let maxVerbLength = self.registry.commands.map { $0.verb.count }.max() ?? 0", + "key.parsed_scope.end" : 50, + "key.parsed_scope.start" : 50, + "key.reusingastcontext" : false, + "key.typename" : "Int", + "key.typeusr" : "$sSiD", + "key.usr" : "s:10Commandant11HelpCommandV3runys6ResultOyytxGAA0B7OptionsVyxGF13maxVerbLengthL_Sivp" + } + ], + "key.typename" : " (HelpCommand) -> (HelpOptions) -> Result<(), ClientError>", + "key.typeusr" : "$sys6ResultOyytxG10Commandant11HelpOptionsVyxGcD", + "key.usr" : "s:10Commandant15CommandProtocolP3runys6ResultOyyt11ClientErrorQzG7OptionsQzF" + } + ], + "key.typename" : "HelpCommand.Type", + "key.typeusr" : "$s10Commandant11HelpCommandVyxGmD", + "key.usr" : "s:10Commandant11HelpCommandV" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public struct HelpOptions<ClientError> : OptionsProtocol<\/Type> where ClientError<\/Type> : Error<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 1731 + } + ], + "key.bodylength" : 406, + "key.bodyoffset" : 1795, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 15, + "key.offset" : 1778 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> struct<\/syntaxtype.keyword> HelpOptions<\/decl.name><ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>> : OptionsProtocol<\/ref.protocol> where<\/syntaxtype.keyword> ClientError<\/ref.generic_type_param> : Error<\/ref.protocol><\/decl.generic_type_requirement><\/decl.struct>", + "key.inheritedtypes" : [ + { + "key.name" : "OptionsProtocol" + } + ], + "key.kind" : "source.lang.swift.decl.struct", + "key.length" : 464, + "key.line" : 61, + "key.modulename" : "Commandant", + "key.name" : "HelpOptions", + "key.namelength" : 11, + "key.nameoffset" : 1745, + "key.offset" : 1738, + "key.parsed_declaration" : "public struct HelpOptions: OptionsProtocol", + "key.parsed_scope.end" : 76, + "key.parsed_scope.start" : 61, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "ClientError : Error<\/Type><\/Declaration>", + "key.column" : 27, + "key.decl_lang" : "source.lang.swift", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 5, + "key.offset" : 1770 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name> : Error<\/ref.protocol><\/decl.generic_type_param.constraint><\/decl.generic_type_param>", + "key.inheritedtypes" : [ + { + "key.name" : "Error" + } + ], + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 18, + "key.line" : 61, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 1757, + "key.offset" : 1757, + "key.parsed_declaration" : "public struct HelpOptionsClientError<\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.typename" : "ClientError.Type", + "key.typeusr" : "$sxmD", + "key.usr" : "s:10Commandant11HelpOptionsV11ClientErrorxmfp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.fileprivate", + "key.annotated_decl" : "fileprivate let verb: String<\/Type>?<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.fileprivate", + "key.length" : 11, + "key.offset" : 1797 + } + ], + "key.column" : 18, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "fileprivate<\/syntaxtype.keyword> let<\/syntaxtype.keyword> verb<\/decl.name>: String<\/ref.struct>?<\/decl.var.type><\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 17, + "key.line" : 62, + "key.modulename" : "Commandant", + "key.name" : "verb", + "key.namelength" : 4, + "key.nameoffset" : 1813, + "key.offset" : 1809, + "key.parsed_declaration" : "fileprivate let verb: String?", + "key.parsed_scope.end" : 62, + "key.parsed_scope.start" : 62, + "key.reusingastcontext" : false, + "key.typename" : "String?", + "key.typeusr" : "$sSSSgD", + "key.usr" : "s:10Commandant11HelpOptionsV4verb33_38F61CE0DF9D73793CEDF5D1C3140331LLSSSgvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.private", + "key.annotated_decl" : "private init(verb: String<\/Type>?)<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.private", + "key.length" : 7, + "key.offset" : 1829 + } + ], + "key.bodylength" : 21, + "key.bodyoffset" : 1858, + "key.column" : 10, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "private<\/syntaxtype.keyword> init<\/syntaxtype.keyword>(verb<\/decl.var.parameter.argument_label>: String<\/ref.struct>?<\/decl.var.parameter.type><\/decl.var.parameter>)<\/decl.function.constructor>", + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 43, + "key.line" : 64, + "key.modulename" : "Commandant", + "key.name" : "init(verb:)", + "key.namelength" : 19, + "key.nameoffset" : 1837, + "key.offset" : 1837, + "key.parsed_declaration" : "private init(verb: String?)", + "key.parsed_scope.end" : 66, + "key.parsed_scope.start" : 64, + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : " (HelpOptions.Type) -> (String?) -> HelpOptions", + "key.typeusr" : "$s4verb10Commandant11HelpOptionsVyxGSSSg_tcD", + "key.usr" : "s:10Commandant11HelpOptionsV4verbACyxGSSSg_tc33_38F61CE0DF9D73793CEDF5D1C3140331Llfc" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.private", + "key.annotated_decl" : "private static func create(_ verb: String<\/Type>) -> HelpOptions<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.private", + "key.length" : 7, + "key.offset" : 1883 + } + ], + "key.bodylength" : 54, + "key.bodyoffset" : 1942, + "key.column" : 22, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "private<\/syntaxtype.keyword> static<\/syntaxtype.keyword> func<\/syntaxtype.keyword> create<\/decl.name>(_<\/decl.var.parameter.argument_label> verb<\/decl.var.parameter.name>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>) -> HelpOptions<\/ref.struct><\/decl.function.returntype><\/decl.function.method.static>", + "key.kind" : "source.lang.swift.decl.function.method.static", + "key.length" : 106, + "key.line" : 68, + "key.modulename" : "Commandant", + "key.name" : "create(_:)", + "key.namelength" : 22, + "key.nameoffset" : 1903, + "key.offset" : 1891, + "key.parsed_declaration" : "private static func create(_ verb: String) -> HelpOptions", + "key.parsed_scope.end" : 70, + "key.parsed_scope.start" : 68, + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : " (HelpOptions.Type) -> (String) -> HelpOptions", + "key.typeusr" : "$sy10Commandant11HelpOptionsVyxGSScD", + "key.usr" : "s:10Commandant11HelpOptionsV6create33_38F61CE0DF9D73793CEDF5D1C3140331LLyACyxGSSFZ" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public static func evaluate(_ m: CommandMode<\/Type>) -> Result<\/Type><HelpOptions<\/Type>, CommandantError<\/Type><ClientError<\/Type>>><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 2000 + } + ], + "key.bodylength" : 99, + "key.bodyoffset" : 2100, + "key.column" : 21, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Evaluates this set of options in the given mode.\n\nReturns the parsed options or a `UsageError`.", + "key.doc.column" : 14, + "key.doc.declaration" : "static func evaluate(_ m: CommandMode) -> Result>", + "key.doc.discussion" : [ + { + "Para" : "Returns the parsed options or a `UsageError`." + }, + { + "Note" : "" + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Option.swift", + "key.doc.full_as_xml" : "evaluate(_:)<\/Name>s:10Commandant15OptionsProtocolP8evaluateys6ResultOyxAA0A5ErrorOy06ClientF0QzGGAA11CommandModeOFZ<\/USR>static func evaluate(_ m: CommandMode) -> Result<Self, CommandantError<ClientError>><\/Declaration>Evaluates this set of options in the given mode.<\/Para><\/Abstract>Returns the parsed options or a UsageError<\/codeVoice>.<\/Para>This documentation comment was inherited from OptionsProtocol<\/codeVoice>.<\/Para><\/Note><\/Discussion><\/CommentParts><\/Function>", + "key.doc.line" : 43, + "key.doc.name" : "evaluate(_:)", + "key.doc.type" : "Function", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> static<\/syntaxtype.keyword> func<\/syntaxtype.keyword> evaluate<\/decl.name>(_<\/decl.var.parameter.argument_label> m<\/decl.var.parameter.name>: CommandMode<\/ref.enum><\/decl.var.parameter.type><\/decl.var.parameter>) -> Result<\/ref.enum><HelpOptions<\/ref.struct>, CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>>><\/decl.function.returntype><\/decl.function.method.static>", + "key.kind" : "source.lang.swift.decl.function.method.static", + "key.length" : 193, + "key.line" : 72, + "key.modulename" : "Commandant", + "key.name" : "evaluate(_:)", + "key.namelength" : 26, + "key.nameoffset" : 2019, + "key.offset" : 2007, + "key.overrides" : [ + { + "key.usr" : "s:10Commandant15OptionsProtocolP8evaluateys6ResultOyxAA0A5ErrorOy06ClientF0QzGGAA11CommandModeOFZ" + } + ], + "key.parsed_declaration" : "public static func evaluate(_ m: CommandMode) -> Result>", + "key.parsed_scope.end" : 75, + "key.parsed_scope.start" : 72, + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : " (HelpOptions.Type) -> (CommandMode) -> Result, CommandantError>", + "key.typeusr" : "$sys6ResultOy10Commandant11HelpOptionsVyxGAC0B5ErrorOyxGGAC11CommandModeOcD", + "key.usr" : "s:10Commandant15OptionsProtocolP8evaluateys6ResultOyxAA0A5ErrorOy06ClientF0QzGGAA11CommandModeOFZ" + } + ], + "key.typename" : "HelpOptions.Type", + "key.typeusr" : "$s10Commandant11HelpOptionsVyxGmD", + "key.usr" : "s:10Commandant11HelpOptionsV" + } + ] + } +}, { + "\/Sources\/Commandant\/Option.swift" : { + "key.diagnostic_stage" : "source.diagnostic.stage.swift.parse", + "key.length" : 9661, + "key.offset" : 0, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public protocol OptionsProtocol<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 1388 + } + ], + "key.bodylength" : 233, + "key.bodyoffset" : 1421, + "key.column" : 17, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Represents a record of options for a command, which can be parsed from\na list of command-line arguments.\n\nThis is most helpful when used in conjunction with the `Option` and `Switch`\ntypes, and `<*>` and `<|` combinators.\n\nExample:\n\n\tstruct LogOptions: OptionsProtocol {\n\t\tlet verbosity: Int\n\t\tlet outputFilename: String\n\t\tlet shouldDelete: Bool\n\t\tlet logName: String\n\n\t\tstatic func create(_ verbosity: Int) -> (String) -> (Bool) -> (String) -> LogOptions {\n\t\t\treturn { outputFilename in { shouldDelete in { logName in LogOptions(verbosity: verbosity, outputFilename: outputFilename, shouldDelete: shouldDelete, logName: logName) } } }\n\t\t}\n\n\t\tstatic func evaluate(_ m: CommandMode) -> Result> {\n\t\t\treturn create\n\t\t\t\t<*> m <| Option(key: \"verbose\", defaultValue: 0, usage: \"the verbosity level with which to read the logs\")\n\t\t\t\t<*> m <| Option(key: \"outputFilename\", defaultValue: \"\", usage: \"a file to print output to, instead of stdout\")\n\t\t\t\t<*> m <| Switch(flag: \"d\", key: \"delete\", usage: \"delete the logs when finished\")\n\t\t\t\t<*> m <| Argument(usage: \"the log to read\")\n\t\t}\n\t}", + "key.doc.column" : 17, + "key.doc.comment" : "Represents a record of options for a command, which can be parsed from\na list of command-line arguments.\n\nThis is most helpful when used in conjunction with the `Option` and `Switch`\ntypes, and `<*>` and `<|` combinators.\n\nExample:\n\n\tstruct LogOptions: OptionsProtocol {\n\t\tlet verbosity: Int\n\t\tlet outputFilename: String\n\t\tlet shouldDelete: Bool\n\t\tlet logName: String\n\n\t\tstatic func create(_ verbosity: Int) -> (String) -> (Bool) -> (String) -> LogOptions {\n\t\t\treturn { outputFilename in { shouldDelete in { logName in LogOptions(verbosity: verbosity, outputFilename: outputFilename, shouldDelete: shouldDelete, logName: logName) } } }\n\t\t}\n\n\t\tstatic func evaluate(_ m: CommandMode) -> Result> {\n\t\t\treturn create\n\t\t\t\t<*> m <| Option(key: \"verbose\", defaultValue: 0, usage: \"the verbosity level with which to read the logs\")\n\t\t\t\t<*> m <| Option(key: \"outputFilename\", defaultValue: \"\", usage: \"a file to print output to, instead of stdout\")\n\t\t\t\t<*> m <| Switch(flag: \"d\", key: \"delete\", usage: \"delete the logs when finished\")\n\t\t\t\t<*> m <| Argument(usage: \"the log to read\")\n\t\t}\n\t}", + "key.doc.declaration" : "public protocol OptionsProtocol", + "key.doc.discussion" : [ + { + "Para" : "This is most helpful when used in conjunction with the `Option` and `Switch` types, and `<*>` and `<|` combinators." + }, + { + "Para" : "Example:" + }, + { + "CodeListing" : "" + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Option.swift", + "key.doc.full_as_xml" : "OptionsProtocol<\/Name>s:10Commandant15OptionsProtocolP<\/USR>public protocol OptionsProtocol<\/Declaration>Represents a record of options for a command, which can be parsed from a list of command-line arguments.<\/Para><\/Abstract>This is most helpful when used in conjunction with the Option<\/codeVoice> and Switch<\/codeVoice> types, and <*><\/codeVoice> and <|<\/codeVoice> combinators.<\/Para>Example:<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered> (String) -> (Bool) -> (String) -> LogOptions {]]><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered> Result> {]]><\/zCodeLineNumbered><\/zCodeLineNumbered> m <| Option(key: \"verbose\", defaultValue: 0, usage: \"the verbosity level with which to read the logs\")]]><\/zCodeLineNumbered> m <| Option(key: \"outputFilename\", defaultValue: \"\", usage: \"a file to print output to, instead of stdout\")]]><\/zCodeLineNumbered> m <| Switch(flag: \"d\", key: \"delete\", usage: \"delete the logs when finished\")]]><\/zCodeLineNumbered> m <| Argument(usage: \"the log to read\")]]><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing><\/Discussion><\/CommentParts><\/Class>", + "key.doc.line" : 37, + "key.doc.name" : "OptionsProtocol", + "key.doc.type" : "Class", + "key.doclength" : 1222, + "key.docoffset" : 166, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> protocol<\/syntaxtype.keyword> OptionsProtocol<\/decl.name><\/decl.protocol>", + "key.kind" : "source.lang.swift.decl.protocol", + "key.length" : 260, + "key.line" : 37, + "key.modulename" : "Commandant", + "key.name" : "OptionsProtocol", + "key.namelength" : 15, + "key.nameoffset" : 1404, + "key.offset" : 1395, + "key.parsed_declaration" : "public protocol OptionsProtocol", + "key.parsed_scope.end" : 44, + "key.parsed_scope.start" : 37, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "associatedtype ClientError : Error<\/Type><\/Declaration>", + "key.column" : 17, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "associatedtype<\/syntaxtype.keyword> ClientError<\/decl.name> : Error<\/ref.protocol><\/decl.associatedtype>", + "key.is_dynamic" : true, + "key.kind" : "source.lang.swift.decl.associatedtype", + "key.length" : 33, + "key.line" : 38, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 1438, + "key.offset" : 1423, + "key.parsed_declaration" : "associatedtype ClientError: Error", + "key.parsed_scope.end" : 38, + "key.parsed_scope.start" : 38, + "key.receivers" : [ + { + "key.usr" : "s:10Commandant15OptionsProtocolP" + } + ], + "key.reusingastcontext" : false, + "key.typename" : "Self.ClientError.Type", + "key.typeusr" : "$s11ClientErrorQzmD", + "key.usr" : "s:10Commandant15OptionsProtocolP11ClientErrorQa" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "static func evaluate(_ m: CommandMode<\/Type>) -> Result<\/Type><Self<\/Type>, CommandantError<\/Type><ClientError<\/Type>>><\/Declaration>", + "key.column" : 14, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Evaluates this set of options in the given mode.\n\nReturns the parsed options or a `UsageError`.", + "key.doc.column" : 14, + "key.doc.comment" : "Evaluates this set of options in the given mode.\n\nReturns the parsed options or a `UsageError`.", + "key.doc.declaration" : "static func evaluate(_ m: CommandMode) -> Result>", + "key.doc.discussion" : [ + { + "Para" : "Returns the parsed options or a `UsageError`." + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Option.swift", + "key.doc.full_as_xml" : "evaluate(_:)<\/Name>s:10Commandant15OptionsProtocolP8evaluateys6ResultOyxAA0A5ErrorOy06ClientF0QzGGAA11CommandModeOFZ<\/USR>static func evaluate(_ m: CommandMode) -> Result<Self, CommandantError<ClientError>><\/Declaration>Evaluates this set of options in the given mode.<\/Para><\/Abstract>Returns the parsed options or a UsageError<\/codeVoice>.<\/Para><\/Discussion><\/CommentParts><\/Function>", + "key.doc.line" : 43, + "key.doc.name" : "evaluate(_:)", + "key.doc.type" : "Function", + "key.doclength" : 109, + "key.docoffset" : 1459, + "key.filepath" : "", + "key.fully_annotated_decl" : "static<\/syntaxtype.keyword> func<\/syntaxtype.keyword> evaluate<\/decl.name>(_<\/decl.var.parameter.argument_label> m<\/decl.var.parameter.name>: CommandMode<\/ref.enum><\/decl.var.parameter.type><\/decl.var.parameter>) -> Result<\/ref.enum><Self<\/ref.generic_type_param>, CommandantError<\/ref.enum><ClientError<\/ref.associatedtype>>><\/decl.function.returntype><\/decl.function.method.static>", + "key.is_dynamic" : true, + "key.kind" : "source.lang.swift.decl.function.method.static", + "key.length" : 84, + "key.line" : 43, + "key.modulename" : "Commandant", + "key.name" : "evaluate(_:)", + "key.namelength" : 26, + "key.nameoffset" : 1581, + "key.offset" : 1569, + "key.parsed_declaration" : "static func evaluate(_ m: CommandMode) -> Result>", + "key.parsed_scope.end" : 43, + "key.parsed_scope.start" : 43, + "key.receivers" : [ + { + "key.usr" : "s:10Commandant15OptionsProtocolP" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : " (Self.Type) -> (CommandMode) -> Result>", + "key.typeusr" : "$sys6ResultOyx10Commandant0B5ErrorOy06ClientC0QzGGAC11CommandModeOcD", + "key.usr" : "s:10Commandant15OptionsProtocolP8evaluateys6ResultOyxAA0A5ErrorOy06ClientF0QzGGAA11CommandModeOFZ" + } + ], + "key.typename" : "OptionsProtocol.Type", + "key.typeusr" : "$s10Commandant15OptionsProtocol_pmD", + "key.usr" : "s:10Commandant15OptionsProtocolP" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public struct NoOptions<ClientError> : OptionsProtocol<\/Type> where ClientError<\/Type> : Error<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 1703 + } + ], + "key.bodylength" : 154, + "key.bodyoffset" : 1765, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "An `OptionsProtocol` that has no options.", + "key.doc.column" : 15, + "key.doc.comment" : "An `OptionsProtocol` that has no options.", + "key.doc.declaration" : "public struct NoOptions : OptionsProtocol where ClientError : Error", + "key.doc.file" : "\/private\/Sources\/Commandant\/Option.swift", + "key.doc.full_as_xml" : "NoOptions<\/Name>s:10Commandant9NoOptionsV<\/USR>public struct NoOptions<ClientError> : OptionsProtocol where ClientError : Error<\/Declaration>An OptionsProtocol<\/codeVoice> that has no options.<\/Para><\/Abstract><\/CommentParts><\/Class>", + "key.doc.line" : 47, + "key.doc.name" : "NoOptions", + "key.doc.type" : "Class", + "key.doclength" : 46, + "key.docoffset" : 1657, + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 15, + "key.offset" : 1748 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> struct<\/syntaxtype.keyword> NoOptions<\/decl.name><ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>> : OptionsProtocol<\/ref.protocol> where<\/syntaxtype.keyword> ClientError<\/ref.generic_type_param> : Error<\/ref.protocol><\/decl.generic_type_requirement><\/decl.struct>", + "key.inheritedtypes" : [ + { + "key.name" : "OptionsProtocol" + } + ], + "key.kind" : "source.lang.swift.decl.struct", + "key.length" : 210, + "key.line" : 47, + "key.modulename" : "Commandant", + "key.name" : "NoOptions", + "key.namelength" : 9, + "key.nameoffset" : 1717, + "key.offset" : 1710, + "key.parsed_declaration" : "public struct NoOptions: OptionsProtocol", + "key.parsed_scope.end" : 53, + "key.parsed_scope.start" : 47, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "ClientError : Error<\/Type><\/Declaration>", + "key.column" : 25, + "key.decl_lang" : "source.lang.swift", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 5, + "key.offset" : 1740 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name> : Error<\/ref.protocol><\/decl.generic_type_param.constraint><\/decl.generic_type_param>", + "key.inheritedtypes" : [ + { + "key.name" : "Error" + } + ], + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 18, + "key.line" : 47, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 1727, + "key.offset" : 1727, + "key.parsed_declaration" : "public struct NoOptionsClientError<\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.typename" : "ClientError.Type", + "key.typeusr" : "$sxmD", + "key.usr" : "s:10Commandant9NoOptionsV11ClientErrorxmfp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public init()<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 1767 + } + ], + "key.bodylength" : 0, + "key.bodyoffset" : 1782, + "key.column" : 9, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> init<\/syntaxtype.keyword>()<\/decl.function.constructor>", + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 9, + "key.line" : 48, + "key.modulename" : "Commandant", + "key.name" : "init()", + "key.namelength" : 6, + "key.nameoffset" : 1774, + "key.offset" : 1774, + "key.parsed_declaration" : "public init()", + "key.parsed_scope.end" : 48, + "key.parsed_scope.start" : 48, + "key.reusingastcontext" : false, + "key.typename" : " (NoOptions.Type) -> () -> NoOptions", + "key.typeusr" : "$s10Commandant9NoOptionsVyxGycD", + "key.usr" : "s:10Commandant9NoOptionsVACyxGycfc" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public static func evaluate(_ m: CommandMode<\/Type>) -> Result<\/Type><NoOptions<\/Type>, CommandantError<\/Type><ClientError<\/Type>>><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 1786 + } + ], + "key.bodylength" : 33, + "key.bodyoffset" : 1884, + "key.column" : 21, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Evaluates this set of options in the given mode.\n\nReturns the parsed options or a `UsageError`.", + "key.doc.column" : 14, + "key.doc.declaration" : "static func evaluate(_ m: CommandMode) -> Result>", + "key.doc.discussion" : [ + { + "Para" : "Returns the parsed options or a `UsageError`." + }, + { + "Note" : "" + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Option.swift", + "key.doc.full_as_xml" : "evaluate(_:)<\/Name>s:10Commandant15OptionsProtocolP8evaluateys6ResultOyxAA0A5ErrorOy06ClientF0QzGGAA11CommandModeOFZ<\/USR>static func evaluate(_ m: CommandMode) -> Result<Self, CommandantError<ClientError>><\/Declaration>Evaluates this set of options in the given mode.<\/Para><\/Abstract>Returns the parsed options or a UsageError<\/codeVoice>.<\/Para>This documentation comment was inherited from OptionsProtocol<\/codeVoice>.<\/Para><\/Note><\/Discussion><\/CommentParts><\/Function>", + "key.doc.line" : 43, + "key.doc.name" : "evaluate(_:)", + "key.doc.type" : "Function", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> static<\/syntaxtype.keyword> func<\/syntaxtype.keyword> evaluate<\/decl.name>(_<\/decl.var.parameter.argument_label> m<\/decl.var.parameter.name>: CommandMode<\/ref.enum><\/decl.var.parameter.type><\/decl.var.parameter>) -> Result<\/ref.enum><NoOptions<\/ref.struct>, CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>>><\/decl.function.returntype><\/decl.function.method.static>", + "key.kind" : "source.lang.swift.decl.function.method.static", + "key.length" : 125, + "key.line" : 50, + "key.modulename" : "Commandant", + "key.name" : "evaluate(_:)", + "key.namelength" : 26, + "key.nameoffset" : 1805, + "key.offset" : 1793, + "key.overrides" : [ + { + "key.usr" : "s:10Commandant15OptionsProtocolP8evaluateys6ResultOyxAA0A5ErrorOy06ClientF0QzGGAA11CommandModeOFZ" + } + ], + "key.parsed_declaration" : "public static func evaluate(_ m: CommandMode) -> Result>", + "key.parsed_scope.end" : 52, + "key.parsed_scope.start" : 50, + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : " (NoOptions.Type) -> (CommandMode) -> Result, CommandantError>", + "key.typeusr" : "$sys6ResultOy10Commandant9NoOptionsVyxGAC0B5ErrorOyxGGAC11CommandModeOcD", + "key.usr" : "s:10Commandant15OptionsProtocolP8evaluateys6ResultOyxAA0A5ErrorOy06ClientF0QzGGAA11CommandModeOFZ" + } + ], + "key.typename" : "NoOptions.Type", + "key.typeusr" : "$s10Commandant9NoOptionsVyxGmD", + "key.usr" : "s:10Commandant9NoOptionsV" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public struct Option<T><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 1988 + } + ], + "key.bodylength" : 786, + "key.bodyoffset" : 2013, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Describes an option that can be provided on the command line.", + "key.doc.column" : 15, + "key.doc.comment" : "Describes an option that can be provided on the command line.", + "key.doc.declaration" : "public struct Option", + "key.doc.file" : "\/private\/Sources\/Commandant\/Option.swift", + "key.doc.full_as_xml" : "Option<\/Name>s:10Commandant6OptionV<\/USR>public struct Option<T><\/Declaration>Describes an option that can be provided on the command line.<\/Para><\/Abstract><\/CommentParts><\/Class>", + "key.doc.line" : 56, + "key.doc.name" : "Option", + "key.doc.type" : "Class", + "key.doclength" : 66, + "key.docoffset" : 1922, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> struct<\/syntaxtype.keyword> Option<\/decl.name><T<\/decl.generic_type_param.name><\/decl.generic_type_param>><\/decl.struct>", + "key.kind" : "source.lang.swift.decl.struct", + "key.length" : 805, + "key.line" : 56, + "key.modulename" : "Commandant", + "key.name" : "Option", + "key.namelength" : 6, + "key.nameoffset" : 2002, + "key.offset" : 1995, + "key.parsed_declaration" : "public struct Option", + "key.parsed_scope.end" : 78, + "key.parsed_scope.start" : 56, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "T<\/Declaration>", + "key.column" : 22, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "T<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 1, + "key.line" : 56, + "key.modulename" : "Commandant", + "key.name" : "T", + "key.namelength" : 1, + "key.nameoffset" : 2009, + "key.offset" : 2009, + "key.parsed_declaration" : "public struct Optionpublic let key: String<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 2132 + } + ], + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "The key that controls this option. For example, a key of `verbose` would\nbe used for a `--verbose` option.", + "key.doc.column" : 13, + "key.doc.comment" : "The key that controls this option. For example, a key of `verbose` would\nbe used for a `--verbose` option.", + "key.doc.declaration" : "public let key: String", + "key.doc.file" : "\/private\/Sources\/Commandant\/Option.swift", + "key.doc.full_as_xml" : "key<\/Name>s:10Commandant6OptionV3keySSvp<\/USR>public let key: String<\/Declaration>The key that controls this option. For example, a key of verbose<\/codeVoice> would be used for a --verbose<\/codeVoice> option.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 59, + "key.doc.name" : "key", + "key.doc.type" : "Other", + "key.doclength" : 116, + "key.docoffset" : 2015, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> let<\/syntaxtype.keyword> key<\/decl.name>: String<\/ref.struct><\/decl.var.type><\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 15, + "key.line" : 59, + "key.modulename" : "Commandant", + "key.name" : "key", + "key.namelength" : 3, + "key.nameoffset" : 2143, + "key.offset" : 2139, + "key.parsed_declaration" : "public let key: String", + "key.parsed_scope.end" : 59, + "key.parsed_scope.start" : 59, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant6OptionV3keySSvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public let defaultValue: T<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 2303 + } + ], + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "The default value for this option. This is the value that will be used\nif the option is never explicitly specified on the command line.", + "key.doc.column" : 13, + "key.doc.comment" : "The default value for this option. This is the value that will be used\nif the option is never explicitly specified on the command line.", + "key.doc.declaration" : "public let defaultValue: T", + "key.doc.file" : "\/private\/Sources\/Commandant\/Option.swift", + "key.doc.full_as_xml" : "defaultValue<\/Name>s:10Commandant6OptionV12defaultValuexvp<\/USR>public let defaultValue: T<\/Declaration>The default value for this option. This is the value that will be used if the option is never explicitly specified on the command line.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 63, + "key.doc.name" : "defaultValue", + "key.doc.type" : "Other", + "key.doclength" : 145, + "key.docoffset" : 2157, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> let<\/syntaxtype.keyword> defaultValue<\/decl.name>: T<\/ref.generic_type_param><\/decl.var.type><\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 19, + "key.line" : 63, + "key.modulename" : "Commandant", + "key.name" : "defaultValue", + "key.namelength" : 12, + "key.nameoffset" : 2314, + "key.offset" : 2310, + "key.parsed_declaration" : "public let defaultValue: T", + "key.parsed_scope.end" : 63, + "key.parsed_scope.start" : 63, + "key.reusingastcontext" : false, + "key.typename" : "T", + "key.typeusr" : "$sxD", + "key.usr" : "s:10Commandant6OptionV12defaultValuexvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public let usage: String<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 2637 + } + ], + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A human-readable string describing the purpose of this option. This will\nbe shown in help messages.\n\nFor boolean operations, this should describe the effect of _not_ using\nthe default value (i.e., what will happen if you disable\/enable the flag\ndifferently from the default).", + "key.doc.column" : 13, + "key.doc.comment" : "A human-readable string describing the purpose of this option. This will\nbe shown in help messages.\n\nFor boolean operations, this should describe the effect of _not_ using\nthe default value (i.e., what will happen if you disable\/enable the flag\ndifferently from the default).", + "key.doc.declaration" : "public let usage: String", + "key.doc.discussion" : [ + { + "Para" : "For boolean operations, this should describe the effect of using the default value (i.e., what will happen if you disable\/enable the flag differently from the default)." + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Option.swift", + "key.doc.full_as_xml" : "usage<\/Name>s:10Commandant6OptionV5usageSSvp<\/USR>public let usage: String<\/Declaration>A human-readable string describing the purpose of this option. This will be shown in help messages.<\/Para><\/Abstract>For boolean operations, this should describe the effect of not<\/emphasis> using the default value (i.e., what will happen if you disable\/enable the flag differently from the default).<\/Para><\/Discussion><\/CommentParts><\/Other>", + "key.doc.line" : 71, + "key.doc.name" : "usage", + "key.doc.type" : "Other", + "key.doclength" : 304, + "key.docoffset" : 2332, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> let<\/syntaxtype.keyword> usage<\/decl.name>: String<\/ref.struct><\/decl.var.type><\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 17, + "key.line" : 71, + "key.modulename" : "Commandant", + "key.name" : "usage", + "key.namelength" : 5, + "key.nameoffset" : 2648, + "key.offset" : 2644, + "key.parsed_declaration" : "public let usage: String", + "key.parsed_scope.end" : 71, + "key.parsed_scope.start" : 71, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant6OptionV5usageSSvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public init(key: String<\/Type>, defaultValue: T<\/Type>, usage: String<\/Type>)<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 2664 + } + ], + "key.bodylength" : 75, + "key.bodyoffset" : 2722, + "key.column" : 9, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> init<\/syntaxtype.keyword>(key<\/decl.var.parameter.argument_label>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>, defaultValue<\/decl.var.parameter.argument_label>: T<\/ref.generic_type_param><\/decl.var.parameter.type><\/decl.var.parameter>, usage<\/decl.var.parameter.argument_label>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>)<\/decl.function.constructor>", + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 127, + "key.line" : 73, + "key.modulename" : "Commandant", + "key.name" : "init(key:defaultValue:usage:)", + "key.namelength" : 49, + "key.nameoffset" : 2671, + "key.offset" : 2671, + "key.parsed_declaration" : "public init(key: String, defaultValue: T, usage: String)", + "key.parsed_scope.end" : 77, + "key.parsed_scope.start" : 73, + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : " (Option.Type) -> (String, T, String) -> Option", + "key.typeusr" : "$s3key12defaultValue5usage10Commandant6OptionVyxGSS_xSStcD", + "key.usr" : "s:10Commandant6OptionV3key12defaultValue5usageACyxGSS_xSStcfc" + } + ], + "key.typename" : "Option.Type", + "key.typeusr" : "$s10Commandant6OptionVyxGmD", + "key.usr" : "s:10Commandant6OptionV" + }, + { + "key.annotated_decl" : "public struct Option<T><\/Declaration>", + "key.bodylength" : 58, + "key.bodyoffset" : 2845, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Describes an option that can be provided on the command line.", + "key.doc.column" : 15, + "key.doc.declaration" : "public struct Option", + "key.doc.file" : "\/private\/Sources\/Commandant\/Option.swift", + "key.doc.full_as_xml" : "Option<\/Name>s:10Commandant6OptionV<\/USR>public struct Option<T><\/Declaration>Describes an option that can be provided on the command line.<\/Para><\/Abstract><\/CommentParts><\/Class>", + "key.doc.line" : 56, + "key.doc.name" : "Option", + "key.doc.type" : "Class", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 23, + "key.offset" : 2820 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> struct<\/syntaxtype.keyword> Option<\/decl.name><T<\/decl.generic_type_param.name><\/decl.generic_type_param>><\/decl.struct>", + "key.inheritedtypes" : [ + { + "key.name" : "CustomStringConvertible" + } + ], + "key.kind" : "source.lang.swift.decl.extension", + "key.length" : 102, + "key.line" : 56, + "key.modulename" : "Commandant", + "key.name" : "Option", + "key.namelength" : 6, + "key.nameoffset" : 2812, + "key.offset" : 2802, + "key.parsed_declaration" : "extension Option: CustomStringConvertible", + "key.parsed_scope.end" : 84, + "key.parsed_scope.start" : 80, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public var description: String<\/Type> { get }<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 2847 + } + ], + "key.bodylength" : 22, + "key.bodyoffset" : 2879, + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A textual representation of this instance.\n\nCalling this property directly is discouraged. Instead, convert an\ninstance of any type to a string by using the `String(describing:)`\ninitializer. This initializer works with any type, and uses the custom\n`description` property for types that conform to\n`CustomStringConvertible`:\n\n struct Point: CustomStringConvertible {\n let x: Int, y: Int\n\n var description: String {\n return \"(\\(x), \\(y))\"\n }\n }\n\n let p = Point(x: 21, y: 30)\n let s = String(describing: p)\n print(s)\n \/\/ Prints \"(21, 30)\"\n\nThe conversion of `p` to a string in the assignment to `s` uses the\n`Point` type's `description` property.", + "key.doc.declaration" : "var description: String { get }", + "key.doc.discussion" : [ + { + "Para" : "Calling this property directly is discouraged. Instead, convert an instance of any type to a string by using the `String(describing:)` initializer. This initializer works with any type, and uses the custom `description` property for types that conform to `CustomStringConvertible`:" + }, + { + "CodeListing" : "" + }, + { + "Para" : "The conversion of `p` to a string in the assignment to `s` uses the `Point` type’s `description` property." + }, + { + "Note" : "" + } + ], + "key.doc.full_as_xml" : "description<\/Name>s:s23CustomStringConvertibleP11descriptionSSvp<\/USR>var description: String { get }<\/Declaration>A textual representation of this instance.<\/Para><\/Abstract>Calling this property directly is discouraged. Instead, convert an instance of any type to a string by using the String(describing:)<\/codeVoice> initializer. This initializer works with any type, and uses the custom description<\/codeVoice> property for types that conform to CustomStringConvertible<\/codeVoice>:<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>The conversion of p<\/codeVoice> to a string in the assignment to s<\/codeVoice> uses the Point<\/codeVoice> type’s description<\/codeVoice> property.<\/Para>This documentation comment was inherited from CustomStringConvertible<\/codeVoice>.<\/Para><\/Note><\/Discussion><\/CommentParts><\/Other>", + "key.doc.name" : "description", + "key.doc.type" : "Other", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> var<\/syntaxtype.keyword> description<\/decl.name>: String<\/ref.struct><\/decl.var.type> { get<\/syntaxtype.keyword> }<\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 48, + "key.line" : 81, + "key.modulename" : "Commandant", + "key.name" : "description", + "key.namelength" : 11, + "key.nameoffset" : 2858, + "key.offset" : 2854, + "key.overrides" : [ + { + "key.usr" : "s:s23CustomStringConvertibleP11descriptionSSvp" + } + ], + "key.parsed_declaration" : "public var description: String", + "key.parsed_scope.end" : 83, + "key.parsed_scope.start" : 81, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:s23CustomStringConvertibleP11descriptionSSvp" + } + ], + "key.typename" : "Option.Type", + "key.typeusr" : "$s10Commandant6OptionVyxGmD", + "key.usr" : "s:10Commandant6OptionV" + }, + { + "key.kind" : "source.lang.swift.syntaxtype.comment.mark", + "key.length" : 17, + "key.name" : "MARK: - Operators", + "key.offset" : 2909 + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public func <*> <T, U, ClientError>(f: (T<\/Type>) -> U<\/Type>, value: Result<\/Type><T<\/Type>, CommandantError<\/Type><ClientError<\/Type>>>) -> Result<\/Type><U<\/Type>, CommandantError<\/Type><ClientError<\/Type>>><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 4404 + } + ], + "key.bodylength" : 22, + "key.bodyoffset" : 4545, + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Applies `f` to the value in the given result.\n\nIn the context of command-line option parsing, this is used to chain\ntogether the parsing of multiple arguments. See OptionsProtocol for an example.", + "key.doc.column" : 13, + "key.doc.comment" : "Applies `f` to the value in the given result.\n\nIn the context of command-line option parsing, this is used to chain\ntogether the parsing of multiple arguments. See OptionsProtocol for an example.", + "key.doc.declaration" : "public func <*> (f: (T) -> U, value: Result>) -> Result>", + "key.doc.discussion" : [ + { + "Para" : "In the context of command-line option parsing, this is used to chain together the parsing of multiple arguments. See OptionsProtocol for an example." + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Option.swift", + "key.doc.full_as_xml" : "<*>(_:_:)<\/Name>s:10Commandant3lmgoiys6ResultOyq_AA0A5ErrorOyq0_GGq_xXE_ADyxAGGtr1_lF<\/USR>public func <*> <T, U, ClientError>(f: (T) -> U, value: Result<T, CommandantError<ClientError>>) -> Result<U, CommandantError<ClientError>><\/Declaration>Applies f<\/codeVoice> to the value in the given result.<\/Para><\/Abstract>In the context of command-line option parsing, this is used to chain together the parsing of multiple arguments. See OptionsProtocol for an example.<\/Para><\/Discussion><\/CommentParts><\/Function>", + "key.doc.line" : 122, + "key.doc.name" : "<*>(_:_:)", + "key.doc.type" : "Function", + "key.doclength" : 211, + "key.docoffset" : 4193, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> func<\/syntaxtype.keyword> <*> <\/decl.name><T<\/decl.generic_type_param.name><\/decl.generic_type_param>, U<\/decl.generic_type_param.name><\/decl.generic_type_param>, ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>>(f<\/decl.var.parameter.name>: (T<\/ref.generic_type_param><\/decl.var.parameter.type><\/decl.var.parameter>) -> U<\/ref.generic_type_param><\/decl.function.returntype><\/decl.var.parameter.type><\/decl.var.parameter>, value<\/decl.var.parameter.name>: Result<\/ref.enum><T<\/ref.generic_type_param>, CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>>><\/decl.var.parameter.type><\/decl.var.parameter>) -> Result<\/ref.enum><U<\/ref.generic_type_param>, CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>>><\/decl.function.returntype><\/decl.function.operator.infix>", + "key.kind" : "source.lang.swift.decl.function.free", + "key.length" : 157, + "key.line" : 122, + "key.modulename" : "Commandant", + "key.name" : "<*>(_:_:)", + "key.namelength" : 84, + "key.nameoffset" : 4416, + "key.offset" : 4411, + "key.parsed_declaration" : "public func <*> (f: (T) -> U, value: Result>) -> Result>", + "key.parsed_scope.end" : 124, + "key.parsed_scope.start" : 122, + "key.related_decls" : [ + { + "key.annotated_decl" : "<*> <T, U, ClientError>(_: Result<((T) -> U), CommandantError<ClientError>>, _: Result<T, CommandantError<ClientError>>) -> Result<U, CommandantError<ClientError>><\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "T<\/Declaration>", + "key.column" : 18, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "T<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 1, + "key.line" : 122, + "key.modulename" : "Commandant", + "key.name" : "T", + "key.namelength" : 1, + "key.nameoffset" : 4421, + "key.offset" : 4421, + "key.parsed_declaration" : "public func <*> U<\/Declaration>", + "key.column" : 21, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "U<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 1, + "key.line" : 122, + "key.modulename" : "Commandant", + "key.name" : "U", + "key.namelength" : 1, + "key.nameoffset" : 4424, + "key.offset" : 4424, + "key.parsed_declaration" : "public func <*> ClientError<\/Declaration>", + "key.column" : 24, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 122, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 4427, + "key.offset" : 4427, + "key.parsed_declaration" : "public func <*> ((T) -> U, Result>) -> Result>", + "key.typeusr" : "$sys6ResultOyq_10Commandant0B5ErrorOyq0_GGq_xXE_AByxAFGtcr1_luD", + "key.usr" : "s:10Commandant3lmgoiys6ResultOyq_AA0A5ErrorOyq0_GGq_xXE_ADyxAGGtr1_lF" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public func <*> <T, U, ClientError>(f: Result<\/Type><((T<\/Type>) -> U<\/Type>), CommandantError<\/Type><ClientError<\/Type>>>, value: Result<\/Type><T<\/Type>, CommandantError<\/Type><ClientError<\/Type>>>) -> Result<\/Type><U<\/Type>, CommandantError<\/Type><ClientError<\/Type>>><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 4797 + } + ], + "key.bodylength" : 346, + "key.bodyoffset" : 4978, + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Applies the function in `f` to the value in the given result.\n\nIn the context of command-line option parsing, this is used to chain\ntogether the parsing of multiple arguments. See OptionsProtocol for an example.", + "key.doc.column" : 13, + "key.doc.comment" : "Applies the function in `f` to the value in the given result.\n\nIn the context of command-line option parsing, this is used to chain\ntogether the parsing of multiple arguments. See OptionsProtocol for an example.", + "key.doc.declaration" : "public func <*> (f: Result<((T) -> U), CommandantError>, value: Result>) -> Result>", + "key.doc.discussion" : [ + { + "Para" : "In the context of command-line option parsing, this is used to chain together the parsing of multiple arguments. See OptionsProtocol for an example." + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Option.swift", + "key.doc.full_as_xml" : "<*>(_:_:)<\/Name>s:10Commandant3lmgoiys6ResultOyq_AA0A5ErrorOyq0_GGADyq_xcAGG_ADyxAGGtr1_lF<\/USR>public func <*> <T, U, ClientError>(f: Result<((T) -> U), CommandantError<ClientError>>, value: Result<T, CommandantError<ClientError>>) -> Result<U, CommandantError<ClientError>><\/Declaration>Applies the function in f<\/codeVoice> to the value in the given result.<\/Para><\/Abstract>In the context of command-line option parsing, this is used to chain together the parsing of multiple arguments. See OptionsProtocol for an example.<\/Para><\/Discussion><\/CommentParts><\/Function>", + "key.doc.line" : 130, + "key.doc.name" : "<*>(_:_:)", + "key.doc.type" : "Function", + "key.doclength" : 227, + "key.docoffset" : 4570, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> func<\/syntaxtype.keyword> <*> <\/decl.name><T<\/decl.generic_type_param.name><\/decl.generic_type_param>, U<\/decl.generic_type_param.name><\/decl.generic_type_param>, ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>>(f<\/decl.var.parameter.name>: Result<\/ref.enum><((T<\/ref.generic_type_param><\/decl.var.parameter.type><\/decl.var.parameter>) -> U<\/ref.generic_type_param><\/decl.function.returntype><\/tuple.element.type><\/tuple.element>)<\/tuple>, CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>>><\/decl.var.parameter.type><\/decl.var.parameter>, value<\/decl.var.parameter.name>: Result<\/ref.enum><T<\/ref.generic_type_param>, CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>>><\/decl.var.parameter.type><\/decl.var.parameter>) -> Result<\/ref.enum><U<\/ref.generic_type_param>, CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>>><\/decl.function.returntype><\/decl.function.operator.infix>", + "key.kind" : "source.lang.swift.decl.function.free", + "key.length" : 521, + "key.line" : 130, + "key.modulename" : "Commandant", + "key.name" : "<*>(_:_:)", + "key.namelength" : 124, + "key.nameoffset" : 4809, + "key.offset" : 4804, + "key.parsed_declaration" : "public func <*> (f: Result<((T) -> U), CommandantError>, value: Result>) -> Result>", + "key.parsed_scope.end" : 145, + "key.parsed_scope.start" : 130, + "key.related_decls" : [ + { + "key.annotated_decl" : "<*> <T, U, ClientError>(_: (T) -> U, _: Result<T, CommandantError<ClientError>>) -> Result<U, CommandantError<ClientError>><\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "T<\/Declaration>", + "key.column" : 18, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "T<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 1, + "key.line" : 130, + "key.modulename" : "Commandant", + "key.name" : "T", + "key.namelength" : 1, + "key.nameoffset" : 4814, + "key.offset" : 4814, + "key.parsed_declaration" : "public func <*> U<\/Declaration>", + "key.column" : 21, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "U<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 1, + "key.line" : 130, + "key.modulename" : "Commandant", + "key.name" : "U", + "key.namelength" : 1, + "key.nameoffset" : 4817, + "key.offset" : 4817, + "key.parsed_declaration" : "public func <*> ClientError<\/Declaration>", + "key.column" : 24, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 130, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 4820, + "key.offset" : 4820, + "key.parsed_declaration" : "public func <*> (Result<((T) -> U), CommandantError>, Result>) -> Result>", + "key.typeusr" : "$sys6ResultOyq_10Commandant0B5ErrorOyq0_GGAByq_xcAFG_AByxAFGtcr1_luD", + "key.usr" : "s:10Commandant3lmgoiys6ResultOyq_AA0A5ErrorOyq0_GGADyq_xcAGG_ADyxAGGtr1_lF" + }, + { + "key.annotated_decl" : "public enum CommandMode<\/Declaration>", + "key.bodylength" : 4309, + "key.bodyoffset" : 5350, + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Describes the \"mode\" in which a command should run.", + "key.doc.column" : 13, + "key.doc.declaration" : "public enum CommandMode", + "key.doc.file" : "\/private\/Sources\/Commandant\/Command.swift", + "key.doc.full_as_xml" : "CommandMode<\/Name>s:10Commandant11CommandModeO<\/USR>public enum CommandMode<\/Declaration>Describes the “mode” in which a command should run.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 68, + "key.doc.name" : "CommandMode", + "key.doc.type" : "Other", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> enum<\/syntaxtype.keyword> CommandMode<\/decl.name><\/decl.enum>", + "key.kind" : "source.lang.swift.decl.extension", + "key.length" : 4333, + "key.line" : 68, + "key.modulename" : "Commandant", + "key.name" : "CommandMode", + "key.namelength" : 11, + "key.nameoffset" : 5337, + "key.offset" : 5327, + "key.parsed_declaration" : "extension CommandMode", + "key.parsed_scope.end" : 273, + "key.parsed_scope.start" : 147, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public static func <| <T, ClientError>(mode: CommandMode<\/Type>, option: Option<\/Type><T<\/Type>>) -> Result<\/Type><T<\/Type>, CommandantError<\/Type><ClientError<\/Type>>> where T<\/Type> : ArgumentProtocol<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 5538 + } + ], + "key.bodylength" : 230, + "key.bodyoffset" : 5677, + "key.column" : 21, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Evaluates the given option in the given mode.\n\nIf parsing command line arguments, and no value was specified on the command\nline, the option's `defaultValue` is used.", + "key.doc.column" : 21, + "key.doc.comment" : "Evaluates the given option in the given mode.\n\nIf parsing command line arguments, and no value was specified on the command\nline, the option's `defaultValue` is used.", + "key.doc.declaration" : "public static func <| (mode: CommandMode, option: Option) -> Result> where T : Commandant.ArgumentProtocol", + "key.doc.discussion" : [ + { + "Para" : "If parsing command line arguments, and no value was specified on the command line, the option’s `defaultValue` is used." + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Option.swift", + "key.doc.full_as_xml" : "<|(_:_:)<\/Name>s:10Commandant11CommandModeO2looiys6ResultOyxAA0A5ErrorOyq_GGAC_AA6OptionVyxGtAA16ArgumentProtocolRzr0_lFZ<\/USR>public static func <| <T, ClientError>(mode: CommandMode, option: Option<T>) -> Result<T, CommandantError<ClientError>> where T : Commandant.ArgumentProtocol<\/Declaration>Evaluates the given option in the given mode.<\/Para><\/Abstract>If parsing command line arguments, and no value was specified on the command line, the option’s defaultValue<\/codeVoice> is used.<\/Para><\/Discussion><\/CommentParts><\/Function>", + "key.doc.line" : 152, + "key.doc.name" : "<|(_:_:)", + "key.doc.type" : "Function", + "key.doclength" : 185, + "key.docoffset" : 5352, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> static<\/syntaxtype.keyword> func<\/syntaxtype.keyword> <| <\/decl.name><T<\/decl.generic_type_param.name><\/decl.generic_type_param>, ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>>(mode<\/decl.var.parameter.name>: CommandMode<\/ref.enum><\/decl.var.parameter.type><\/decl.var.parameter>, option<\/decl.var.parameter.name>: Option<\/ref.struct><T<\/ref.generic_type_param>><\/decl.var.parameter.type><\/decl.var.parameter>) -> Result<\/ref.enum><T<\/ref.generic_type_param>, CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>>><\/decl.function.returntype> where<\/syntaxtype.keyword> T<\/ref.generic_type_param> : ArgumentProtocol<\/ref.protocol><\/decl.generic_type_requirement><\/decl.function.operator.infix>", + "key.kind" : "source.lang.swift.decl.function.method.static", + "key.length" : 363, + "key.line" : 152, + "key.modulename" : "Commandant", + "key.name" : "<|(_:_:)", + "key.namelength" : 75, + "key.nameoffset" : 5557, + "key.offset" : 5545, + "key.parsed_declaration" : "public static func <| (mode: CommandMode, option: Option) -> Result>", + "key.parsed_scope.end" : 157, + "key.parsed_scope.start" : 152, + "key.related_decls" : [ + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Argument<T>) -> Result<T, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Argument<[T]>) -> Result<[T], CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<T?>) -> Result<T?, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<[T]>) -> Result<[T], CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<[T]?>) -> Result<[T]?, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <ClientError>(_: CommandMode, _: Option<Bool>) -> Result<Bool, CommandantError<ClientError>><\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <ClientError>(_: CommandMode, _: Switch) -> Result<Bool, CommandantError<ClientError>><\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "T : ArgumentProtocol<\/Type><\/Declaration>", + "key.column" : 25, + "key.decl_lang" : "source.lang.swift", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 16, + "key.offset" : 5564 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "T<\/decl.generic_type_param.name> : ArgumentProtocol<\/ref.protocol><\/decl.generic_type_param.constraint><\/decl.generic_type_param>", + "key.inheritedtypes" : [ + { + "key.name" : "ArgumentProtocol" + } + ], + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 19, + "key.line" : 152, + "key.modulename" : "Commandant", + "key.name" : "T", + "key.namelength" : 1, + "key.nameoffset" : 5561, + "key.offset" : 5561, + "key.parsed_declaration" : "public static func <| ClientError<\/Declaration>", + "key.column" : 46, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 152, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 5582, + "key.offset" : 5582, + "key.parsed_declaration" : "public static func <| let wrapped: Option<\/Type><T<\/Type>?><\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "let<\/syntaxtype.keyword> wrapped<\/decl.name>: Option<\/ref.struct><T<\/ref.generic_type_param>?><\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 97, + "key.line" : 153, + "key.modulename" : "Commandant", + "key.name" : "wrapped", + "key.namelength" : 7, + "key.nameoffset" : 5684, + "key.offset" : 5680, + "key.parsed_declaration" : "let wrapped = Option(key: option.key, defaultValue: option.defaultValue, usage: option.usage)", + "key.parsed_scope.end" : 153, + "key.parsed_scope.start" : 153, + "key.reusingastcontext" : false, + "key.typename" : "Option", + "key.typeusr" : "$s10Commandant6OptionVyxSgGD", + "key.usr" : "s:10Commandant11CommandModeO2looiys6ResultOyxAA0A5ErrorOyq_GGAC_AA6OptionVyxGtAA16ArgumentProtocolRzr0_lFZ7wrappedL_ALyxSgGvp" + } + ], + "key.typename" : " (CommandMode.Type) -> (CommandMode, Option) -> Result>", + "key.typeusr" : "$sys6ResultOyx10Commandant0B5ErrorOyq_GGAC11CommandModeO_AC6OptionVyxGtcAC16ArgumentProtocolRzr0_luD", + "key.usr" : "s:10Commandant11CommandModeO2looiys6ResultOyxAA0A5ErrorOyq_GGAC_AA6OptionVyxGtAA16ArgumentProtocolRzr0_lFZ" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public static func <| <T, ClientError>(mode: CommandMode<\/Type>, option: Option<\/Type><T<\/Type>?>) -> Result<\/Type><T<\/Type>?, CommandantError<\/Type><ClientError<\/Type>>> where T<\/Type> : ArgumentProtocol<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 6075 + } + ], + "key.bodylength" : 852, + "key.bodyoffset" : 6216, + "key.column" : 21, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Evaluates the given option in the given mode.\n\nIf parsing command line arguments, and no value was specified on the command\nline, `nil` is used.", + "key.doc.column" : 21, + "key.doc.comment" : "Evaluates the given option in the given mode.\n\nIf parsing command line arguments, and no value was specified on the command\nline, `nil` is used.", + "key.doc.declaration" : "public static func <| (mode: CommandMode, option: Option) -> Result> where T : Commandant.ArgumentProtocol", + "key.doc.discussion" : [ + { + "Para" : "If parsing command line arguments, and no value was specified on the command line, `nil` is used." + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Option.swift", + "key.doc.full_as_xml" : "<|(_:_:)<\/Name>s:10Commandant11CommandModeO2looiys6ResultOyxSgAA0A5ErrorOyq_GGAC_AA6OptionVyAGGtAA16ArgumentProtocolRzr0_lFZ<\/USR>public static func <| <T, ClientError>(mode: CommandMode, option: Option<T?>) -> Result<T?, CommandantError<ClientError>> where T : Commandant.ArgumentProtocol<\/Declaration>Evaluates the given option in the given mode.<\/Para><\/Abstract>If parsing command line arguments, and no value was specified on the command line, nil<\/codeVoice> is used.<\/Para><\/Discussion><\/CommentParts><\/Function>", + "key.doc.line" : 163, + "key.doc.name" : "<|(_:_:)", + "key.doc.type" : "Function", + "key.doclength" : 163, + "key.docoffset" : 5911, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> static<\/syntaxtype.keyword> func<\/syntaxtype.keyword> <| <\/decl.name><T<\/decl.generic_type_param.name><\/decl.generic_type_param>, ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>>(mode<\/decl.var.parameter.name>: CommandMode<\/ref.enum><\/decl.var.parameter.type><\/decl.var.parameter>, option<\/decl.var.parameter.name>: Option<\/ref.struct><T<\/ref.generic_type_param>?><\/decl.var.parameter.type><\/decl.var.parameter>) -> Result<\/ref.enum><T<\/ref.generic_type_param>?, CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>>><\/decl.function.returntype> where<\/syntaxtype.keyword> T<\/ref.generic_type_param> : ArgumentProtocol<\/ref.protocol><\/decl.generic_type_requirement><\/decl.function.operator.infix>", + "key.kind" : "source.lang.swift.decl.function.method.static", + "key.length" : 987, + "key.line" : 163, + "key.modulename" : "Commandant", + "key.name" : "<|(_:_:)", + "key.namelength" : 76, + "key.nameoffset" : 6094, + "key.offset" : 6082, + "key.parsed_declaration" : "public static func <| (mode: CommandMode, option: Option) -> Result>", + "key.parsed_scope.end" : 196, + "key.parsed_scope.start" : 163, + "key.related_decls" : [ + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Argument<T>) -> Result<T, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Argument<[T]>) -> Result<[T], CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<T>) -> Result<T, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<[T]>) -> Result<[T], CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<[T]?>) -> Result<[T]?, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <ClientError>(_: CommandMode, _: Option<Bool>) -> Result<Bool, CommandantError<ClientError>><\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <ClientError>(_: CommandMode, _: Switch) -> Result<Bool, CommandantError<ClientError>><\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "T : ArgumentProtocol<\/Type><\/Declaration>", + "key.column" : 25, + "key.decl_lang" : "source.lang.swift", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 16, + "key.offset" : 6101 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "T<\/decl.generic_type_param.name> : ArgumentProtocol<\/ref.protocol><\/decl.generic_type_param.constraint><\/decl.generic_type_param>", + "key.inheritedtypes" : [ + { + "key.name" : "ArgumentProtocol" + } + ], + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 19, + "key.line" : 163, + "key.modulename" : "Commandant", + "key.name" : "T", + "key.namelength" : 1, + "key.nameoffset" : 6098, + "key.offset" : 6098, + "key.parsed_declaration" : "public static func <| ClientError<\/Declaration>", + "key.column" : 46, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 163, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 6119, + "key.offset" : 6119, + "key.parsed_declaration" : "public static func <| let key: String<\/Type><\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "let<\/syntaxtype.keyword> key<\/decl.name>: String<\/ref.struct><\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 20, + "key.line" : 164, + "key.modulename" : "Commandant", + "key.name" : "key", + "key.namelength" : 3, + "key.nameoffset" : 6223, + "key.offset" : 6219, + "key.parsed_declaration" : "let key = option.key", + "key.parsed_scope.end" : 164, + "key.parsed_scope.start" : 164, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant11CommandModeO2looiys6ResultOyxSgAA0A5ErrorOyq_GGAC_AA6OptionVyAGGtAA16ArgumentProtocolRzr0_lFZ3keyL_SSvp" + } + ], + "key.typename" : " (CommandMode.Type) -> (CommandMode, Option) -> Result>", + "key.typeusr" : "$sys6ResultOyxSg10Commandant0B5ErrorOyq_GGAD11CommandModeO_AD6OptionVyACGtcAD16ArgumentProtocolRzr0_luD", + "key.usr" : "s:10Commandant11CommandModeO2looiys6ResultOyxSgAA0A5ErrorOyq_GGAC_AA6OptionVyAGGtAA16ArgumentProtocolRzr0_lFZ" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public static func <| <T, ClientError>(mode: CommandMode<\/Type>, option: Option<\/Type><[T<\/Type>]>) -> Result<\/Type><[T<\/Type>], CommandantError<\/Type><ClientError<\/Type>>> where T<\/Type> : ArgumentProtocol<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 7258 + } + ], + "key.bodylength" : 232, + "key.bodyoffset" : 7401, + "key.column" : 21, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Evaluates the given option in the given mode.\n\nIf parsing command line arguments, and no value was specified on the command\nline, the option's `defaultValue` is used.", + "key.doc.column" : 21, + "key.doc.comment" : "Evaluates the given option in the given mode.\n\nIf parsing command line arguments, and no value was specified on the command\nline, the option's `defaultValue` is used.", + "key.doc.declaration" : "public static func <| (mode: CommandMode, option: Option<[T]>) -> Result<[T], CommandantError> where T : Commandant.ArgumentProtocol", + "key.doc.discussion" : [ + { + "Para" : "If parsing command line arguments, and no value was specified on the command line, the option’s `defaultValue` is used." + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Option.swift", + "key.doc.full_as_xml" : "<|(_:_:)<\/Name>s:10Commandant11CommandModeO2looiys6ResultOySayxGAA0A5ErrorOyq_GGAC_AA6OptionVyAGGtAA16ArgumentProtocolRzr0_lFZ<\/USR>public static func <| <T, ClientError>(mode: CommandMode, option: Option<[T]>) -> Result<[T], CommandantError<ClientError>> where T : Commandant.ArgumentProtocol<\/Declaration>Evaluates the given option in the given mode.<\/Para><\/Abstract>If parsing command line arguments, and no value was specified on the command line, the option’s defaultValue<\/codeVoice> is used.<\/Para><\/Discussion><\/CommentParts><\/Function>", + "key.doc.line" : 202, + "key.doc.name" : "<|(_:_:)", + "key.doc.type" : "Function", + "key.doclength" : 185, + "key.docoffset" : 7072, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> static<\/syntaxtype.keyword> func<\/syntaxtype.keyword> <| <\/decl.name><T<\/decl.generic_type_param.name><\/decl.generic_type_param>, ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>>(mode<\/decl.var.parameter.name>: CommandMode<\/ref.enum><\/decl.var.parameter.type><\/decl.var.parameter>, option<\/decl.var.parameter.name>: Option<\/ref.struct><[T<\/ref.generic_type_param>]><\/decl.var.parameter.type><\/decl.var.parameter>) -> Result<\/ref.enum><[T<\/ref.generic_type_param>], CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>>><\/decl.function.returntype> where<\/syntaxtype.keyword> T<\/ref.generic_type_param> : ArgumentProtocol<\/ref.protocol><\/decl.generic_type_requirement><\/decl.function.operator.infix>", + "key.kind" : "source.lang.swift.decl.function.method.static", + "key.length" : 369, + "key.line" : 202, + "key.modulename" : "Commandant", + "key.name" : "<|(_:_:)", + "key.namelength" : 77, + "key.nameoffset" : 7277, + "key.offset" : 7265, + "key.parsed_declaration" : "public static func <| (mode: CommandMode, option: Option<[T]>) -> Result<[T], CommandantError>", + "key.parsed_scope.end" : 207, + "key.parsed_scope.start" : 202, + "key.related_decls" : [ + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Argument<T>) -> Result<T, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Argument<[T]>) -> Result<[T], CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<T>) -> Result<T, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<T?>) -> Result<T?, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<[T]?>) -> Result<[T]?, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <ClientError>(_: CommandMode, _: Option<Bool>) -> Result<Bool, CommandantError<ClientError>><\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <ClientError>(_: CommandMode, _: Switch) -> Result<Bool, CommandantError<ClientError>><\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "T : ArgumentProtocol<\/Type><\/Declaration>", + "key.column" : 25, + "key.decl_lang" : "source.lang.swift", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 16, + "key.offset" : 7284 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "T<\/decl.generic_type_param.name> : ArgumentProtocol<\/ref.protocol><\/decl.generic_type_param.constraint><\/decl.generic_type_param>", + "key.inheritedtypes" : [ + { + "key.name" : "ArgumentProtocol" + } + ], + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 19, + "key.line" : 202, + "key.modulename" : "Commandant", + "key.name" : "T", + "key.namelength" : 1, + "key.nameoffset" : 7281, + "key.offset" : 7281, + "key.parsed_declaration" : "public static func <| ClientError<\/Declaration>", + "key.column" : 46, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 202, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 7302, + "key.offset" : 7302, + "key.parsed_declaration" : "public static func <| let wrapped: Option<\/Type><[T<\/Type>]?><\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "let<\/syntaxtype.keyword> wrapped<\/decl.name>: Option<\/ref.struct><[T<\/ref.generic_type_param>]?><\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 99, + "key.line" : 203, + "key.modulename" : "Commandant", + "key.name" : "wrapped", + "key.namelength" : 7, + "key.nameoffset" : 7408, + "key.offset" : 7404, + "key.parsed_declaration" : "let wrapped = Option<[T]?>(key: option.key, defaultValue: option.defaultValue, usage: option.usage)", + "key.parsed_scope.end" : 203, + "key.parsed_scope.start" : 203, + "key.reusingastcontext" : false, + "key.typename" : "Option<[T]?>", + "key.typeusr" : "$s10Commandant6OptionVySayxGSgGD", + "key.usr" : "s:10Commandant11CommandModeO2looiys6ResultOySayxGAA0A5ErrorOyq_GGAC_AA6OptionVyAGGtAA16ArgumentProtocolRzr0_lFZ7wrappedL_AMyAGSgGvp" + } + ], + "key.typename" : " (CommandMode.Type) -> (CommandMode, Option<[T]>) -> Result<[T], CommandantError>", + "key.typeusr" : "$sys6ResultOySayxG10Commandant0B5ErrorOyq_GGAD11CommandModeO_AD6OptionVyACGtcAD16ArgumentProtocolRzr0_luD", + "key.usr" : "s:10Commandant11CommandModeO2looiys6ResultOySayxGAA0A5ErrorOyq_GGAC_AA6OptionVyAGGtAA16ArgumentProtocolRzr0_lFZ" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public static func <| <T, ClientError>(mode: CommandMode<\/Type>, option: Option<\/Type><[T<\/Type>]?>) -> Result<\/Type><[T<\/Type>]?, CommandantError<\/Type><ClientError<\/Type>>> where T<\/Type> : ArgumentProtocol<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 7801 + } + ], + "key.bodylength" : 1117, + "key.bodyoffset" : 7946, + "key.column" : 21, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Evaluates the given option in the given mode.\n\nIf parsing command line arguments, and no value was specified on the command\nline, `nil` is used.", + "key.doc.column" : 21, + "key.doc.comment" : "Evaluates the given option in the given mode.\n\nIf parsing command line arguments, and no value was specified on the command\nline, `nil` is used.", + "key.doc.declaration" : "public static func <| (mode: CommandMode, option: Option<[T]?>) -> Result<[T]?, CommandantError> where T : Commandant.ArgumentProtocol", + "key.doc.discussion" : [ + { + "Para" : "If parsing command line arguments, and no value was specified on the command line, `nil` is used." + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Option.swift", + "key.doc.full_as_xml" : "<|(_:_:)<\/Name>s:10Commandant11CommandModeO2looiys6ResultOySayxGSgAA0A5ErrorOyq_GGAC_AA6OptionVyAHGtAA16ArgumentProtocolRzr0_lFZ<\/USR>public static func <| <T, ClientError>(mode: CommandMode, option: Option<[T]?>) -> Result<[T]?, CommandantError<ClientError>> where T : Commandant.ArgumentProtocol<\/Declaration>Evaluates the given option in the given mode.<\/Para><\/Abstract>If parsing command line arguments, and no value was specified on the command line, nil<\/codeVoice> is used.<\/Para><\/Discussion><\/CommentParts><\/Function>", + "key.doc.line" : 213, + "key.doc.name" : "<|(_:_:)", + "key.doc.type" : "Function", + "key.doclength" : 163, + "key.docoffset" : 7637, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> static<\/syntaxtype.keyword> func<\/syntaxtype.keyword> <| <\/decl.name><T<\/decl.generic_type_param.name><\/decl.generic_type_param>, ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>>(mode<\/decl.var.parameter.name>: CommandMode<\/ref.enum><\/decl.var.parameter.type><\/decl.var.parameter>, option<\/decl.var.parameter.name>: Option<\/ref.struct><[T<\/ref.generic_type_param>]?><\/decl.var.parameter.type><\/decl.var.parameter>) -> Result<\/ref.enum><[T<\/ref.generic_type_param>]?, CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>>><\/decl.function.returntype> where<\/syntaxtype.keyword> T<\/ref.generic_type_param> : ArgumentProtocol<\/ref.protocol><\/decl.generic_type_requirement><\/decl.function.operator.infix>", + "key.kind" : "source.lang.swift.decl.function.method.static", + "key.length" : 1256, + "key.line" : 213, + "key.modulename" : "Commandant", + "key.name" : "<|(_:_:)", + "key.namelength" : 78, + "key.nameoffset" : 7820, + "key.offset" : 7808, + "key.parsed_declaration" : "public static func <| (mode: CommandMode, option: Option<[T]?>) -> Result<[T]?, CommandantError>", + "key.parsed_scope.end" : 254, + "key.parsed_scope.start" : 213, + "key.related_decls" : [ + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Argument<T>) -> Result<T, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Argument<[T]>) -> Result<[T], CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<T>) -> Result<T, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<T?>) -> Result<T?, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<[T]>) -> Result<[T], CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <ClientError>(_: CommandMode, _: Option<Bool>) -> Result<Bool, CommandantError<ClientError>><\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <ClientError>(_: CommandMode, _: Switch) -> Result<Bool, CommandantError<ClientError>><\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "T : ArgumentProtocol<\/Type><\/Declaration>", + "key.column" : 25, + "key.decl_lang" : "source.lang.swift", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 16, + "key.offset" : 7827 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "T<\/decl.generic_type_param.name> : ArgumentProtocol<\/ref.protocol><\/decl.generic_type_param.constraint><\/decl.generic_type_param>", + "key.inheritedtypes" : [ + { + "key.name" : "ArgumentProtocol" + } + ], + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 19, + "key.line" : 213, + "key.modulename" : "Commandant", + "key.name" : "T", + "key.namelength" : 1, + "key.nameoffset" : 7824, + "key.offset" : 7824, + "key.parsed_declaration" : "public static func <| ClientError<\/Declaration>", + "key.column" : 46, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 213, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 7845, + "key.offset" : 7845, + "key.parsed_declaration" : "public static func <| let key: String<\/Type><\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "let<\/syntaxtype.keyword> key<\/decl.name>: String<\/ref.struct><\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 20, + "key.line" : 214, + "key.modulename" : "Commandant", + "key.name" : "key", + "key.namelength" : 3, + "key.nameoffset" : 7953, + "key.offset" : 7949, + "key.parsed_declaration" : "let key = option.key", + "key.parsed_scope.end" : 214, + "key.parsed_scope.start" : 214, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant11CommandModeO2looiys6ResultOySayxGSgAA0A5ErrorOyq_GGAC_AA6OptionVyAHGtAA16ArgumentProtocolRzr0_lFZ3keyL_SSvp" + } + ], + "key.typename" : " (CommandMode.Type) -> (CommandMode, Option<[T]?>) -> Result<[T]?, CommandantError>", + "key.typeusr" : "$sys6ResultOySayxGSg10Commandant0B5ErrorOyq_GGAE11CommandModeO_AE6OptionVyADGtcAE16ArgumentProtocolRzr0_luD", + "key.usr" : "s:10Commandant11CommandModeO2looiys6ResultOySayxGSgAA0A5ErrorOyq_GGAC_AA6OptionVyAHGtAA16ArgumentProtocolRzr0_lFZ" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public static func <| <ClientError>(mode: CommandMode<\/Type>, option: Option<\/Type><Bool<\/Type>>) -> Result<\/Type><Bool<\/Type>, CommandantError<\/Type><ClientError<\/Type>>><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 9261 + } + ], + "key.bodylength" : 272, + "key.bodyoffset" : 9385, + "key.column" : 21, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Evaluates the given boolean option in the given mode.\n\nIf parsing command line arguments, and no value was specified on the command\nline, the option's `defaultValue` is used.", + "key.doc.column" : 21, + "key.doc.comment" : "Evaluates the given boolean option in the given mode.\n\nIf parsing command line arguments, and no value was specified on the command\nline, the option's `defaultValue` is used.", + "key.doc.declaration" : "public static func <| (mode: CommandMode, option: Option) -> Result>", + "key.doc.discussion" : [ + { + "Para" : "If parsing command line arguments, and no value was specified on the command line, the option’s `defaultValue` is used." + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Option.swift", + "key.doc.full_as_xml" : "<|(_:_:)<\/Name>s:10Commandant11CommandModeO2looiys6ResultOySbAA0A5ErrorOyxGGAC_AA6OptionVySbGtlFZ<\/USR>public static func <| <ClientError>(mode: CommandMode, option: Option<Bool>) -> Result<Bool, CommandantError<ClientError>><\/Declaration>Evaluates the given boolean option in the given mode.<\/Para><\/Abstract>If parsing command line arguments, and no value was specified on the command line, the option’s defaultValue<\/codeVoice> is used.<\/Para><\/Discussion><\/CommentParts><\/Function>", + "key.doc.line" : 260, + "key.doc.name" : "<|(_:_:)", + "key.doc.type" : "Function", + "key.doclength" : 193, + "key.docoffset" : 9067, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> static<\/syntaxtype.keyword> func<\/syntaxtype.keyword> <| <\/decl.name><ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>>(mode<\/decl.var.parameter.name>: CommandMode<\/ref.enum><\/decl.var.parameter.type><\/decl.var.parameter>, option<\/decl.var.parameter.name>: Option<\/ref.struct><Bool<\/ref.struct>><\/decl.var.parameter.type><\/decl.var.parameter>) -> Result<\/ref.enum><Bool<\/ref.struct>, CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>>><\/decl.function.returntype><\/decl.function.operator.infix>", + "key.kind" : "source.lang.swift.decl.function.method.static", + "key.length" : 390, + "key.line" : 260, + "key.modulename" : "Commandant", + "key.name" : "<|(_:_:)", + "key.namelength" : 57, + "key.nameoffset" : 9280, + "key.offset" : 9268, + "key.parsed_declaration" : "public static func <| (mode: CommandMode, option: Option) -> Result>", + "key.parsed_scope.end" : 272, + "key.parsed_scope.start" : 260, + "key.related_decls" : [ + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Argument<T>) -> Result<T, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Argument<[T]>) -> Result<[T], CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<T>) -> Result<T, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<T?>) -> Result<T?, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<[T]>) -> Result<[T], CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<[T]?>) -> Result<[T]?, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <ClientError>(_: CommandMode, _: Switch) -> Result<Bool, CommandantError<ClientError>><\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "ClientError<\/Declaration>", + "key.column" : 25, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 260, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 9284, + "key.offset" : 9284, + "key.parsed_declaration" : "public static func <| (CommandMode.Type) -> (CommandMode, Option) -> Result>", + "key.typeusr" : "$sys6ResultOySb10Commandant0B5ErrorOyxGGAC11CommandModeO_AC6OptionVySbGtcluD", + "key.usr" : "s:10Commandant11CommandModeO2looiys6ResultOySbAA0A5ErrorOyxGGAC_AA6OptionVySbGtlFZ" + } + ], + "key.typename" : "CommandMode.Type", + "key.typeusr" : "$s10Commandant11CommandModeOmD", + "key.usr" : "s:10Commandant11CommandModeO" + } + ] + } +}, { + "\/Sources\/Commandant\/OrderedSet.swift" : { + "key.diagnostic_stage" : "source.diagnostic.stage.swift.parse", + "key.length" : 800, + "key.offset" : 0, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "internal struct OrderedSet<T> : Equatable<\/Type> where T<\/Type> : Hashable<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.internal", + "key.length" : 8, + "key.offset" : 30 + } + ], + "key.bodylength" : 348, + "key.bodyoffset" : 82, + "key.column" : 17, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A poor man's ordered set.", + "key.doc.column" : 17, + "key.doc.comment" : "A poor man's ordered set.", + "key.doc.declaration" : "internal struct OrderedSet : Equatable where T : Hashable", + "key.doc.file" : "\/private\/Sources\/Commandant\/OrderedSet.swift", + "key.doc.full_as_xml" : "OrderedSet<\/Name>s:10Commandant10OrderedSetV<\/USR>internal struct OrderedSet<T> : Equatable where T : Hashable<\/Declaration>A poor man’s ordered set.<\/Para><\/Abstract><\/CommentParts><\/Class>", + "key.doc.line" : 2, + "key.doc.name" : "OrderedSet", + "key.doc.type" : "Class", + "key.doclength" : 30, + "key.docoffset" : 0, + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 9, + "key.offset" : 71 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "internal<\/syntaxtype.keyword> struct<\/syntaxtype.keyword> OrderedSet<\/decl.name><T<\/decl.generic_type_param.name><\/decl.generic_type_param>> : Equatable<\/ref.protocol> where<\/syntaxtype.keyword> T<\/ref.generic_type_param> : Hashable<\/ref.protocol><\/decl.generic_type_requirement><\/decl.struct>", + "key.inheritedtypes" : [ + { + "key.name" : "Equatable" + } + ], + "key.kind" : "source.lang.swift.decl.struct", + "key.length" : 392, + "key.line" : 2, + "key.modulename" : "Commandant", + "key.name" : "OrderedSet", + "key.namelength" : 10, + "key.nameoffset" : 46, + "key.offset" : 39, + "key.parsed_declaration" : "internal struct OrderedSet: Equatable", + "key.parsed_scope.end" : 19, + "key.parsed_scope.start" : 2, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "T : Hashable<\/Type><\/Declaration>", + "key.column" : 28, + "key.decl_lang" : "source.lang.swift", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 8, + "key.offset" : 60 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "T<\/decl.generic_type_param.name> : Hashable<\/ref.protocol><\/decl.generic_type_param.constraint><\/decl.generic_type_param>", + "key.inheritedtypes" : [ + { + "key.name" : "Hashable" + } + ], + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 2, + "key.modulename" : "Commandant", + "key.name" : "T", + "key.namelength" : 1, + "key.nameoffset" : 57, + "key.offset" : 57, + "key.parsed_declaration" : "internal struct OrderedSetfileprivate var values: [T<\/Type>]<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.fileprivate", + "key.length" : 11, + "key.offset" : 84 + } + ], + "key.column" : 18, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "fileprivate<\/syntaxtype.keyword> var<\/syntaxtype.keyword> values<\/decl.name>: [T<\/ref.generic_type_param>]<\/decl.var.type><\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 20, + "key.line" : 3, + "key.modulename" : "Commandant", + "key.name" : "values", + "key.namelength" : 6, + "key.nameoffset" : 100, + "key.offset" : 96, + "key.parsed_declaration" : "fileprivate var values: [T] = []", + "key.parsed_scope.end" : 3, + "key.parsed_scope.start" : 3, + "key.reusingastcontext" : false, + "key.setter_accessibility" : "source.lang.swift.accessibility.fileprivate", + "key.typename" : "[T]", + "key.typeusr" : "$sSayxGD", + "key.usr" : "s:10Commandant10OrderedSetV6values33_E700A43BE27995F7283A44882E2B4A42LLSayxGvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "init<S>(_ sequence: S<\/Type>) where T<\/Type> == S<\/Type>.Element<\/Type>, S<\/Type> : Sequence<\/Type><\/Declaration>", + "key.bodylength" : 74, + "key.bodyoffset" : 174, + "key.column" : 2, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "init<\/syntaxtype.keyword><S<\/decl.generic_type_param.name><\/decl.generic_type_param>>(_<\/decl.var.parameter.argument_label> sequence<\/decl.var.parameter.name>: S<\/ref.generic_type_param><\/decl.var.parameter.type><\/decl.var.parameter>) where<\/syntaxtype.keyword> T<\/ref.generic_type_param> == S<\/ref.generic_type_param>.Element<\/ref.associatedtype><\/decl.generic_type_requirement>, S<\/ref.generic_type_param> : Sequence<\/ref.protocol><\/decl.generic_type_requirement><\/decl.function.constructor>", + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 130, + "key.line" : 5, + "key.modulename" : "Commandant", + "key.name" : "init(_:)", + "key.namelength" : 32, + "key.nameoffset" : 119, + "key.offset" : 119, + "key.parsed_declaration" : "init(_ sequence: S) where S.Element == T", + "key.parsed_scope.end" : 9, + "key.parsed_scope.start" : 5, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "S : Sequence<\/Type><\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 8, + "key.offset" : 127 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "S<\/decl.generic_type_param.name> : Sequence<\/ref.protocol><\/decl.generic_type_param.constraint><\/decl.generic_type_param>", + "key.inheritedtypes" : [ + { + "key.name" : "Sequence" + } + ], + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 5, + "key.modulename" : "Commandant", + "key.name" : "S", + "key.namelength" : 1, + "key.nameoffset" : 124, + "key.offset" : 124, + "key.parsed_declaration" : "init (OrderedSet.Type) -> (S) -> OrderedSet", + "key.typeusr" : "$sy10Commandant10OrderedSetVyxGqd__c7ElementQyd__RszSTRd__luD", + "key.usr" : "s:10Commandant10OrderedSetVyACyxGqd__c7ElementQyd__RszSTRd__lufc" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "@discardableResult mutating func remove(_ member: T<\/Type>) -> T<\/Type>?<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.mutating", + "key.length" : 8, + "key.offset" : 272 + }, + { + "key.attribute" : "source.decl.attribute.discardableResult", + "key.length" : 18, + "key.offset" : 252 + } + ], + "key.bodylength" : 115, + "key.bodyoffset" : 313, + "key.column" : 16, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "@discardableResult<\/syntaxtype.attribute.name><\/syntaxtype.attribute.builtin> mutating<\/syntaxtype.keyword> func<\/syntaxtype.keyword> remove<\/decl.name>(_<\/decl.var.parameter.argument_label> member<\/decl.var.parameter.name>: T<\/ref.generic_type_param><\/decl.var.parameter.type><\/decl.var.parameter>) -> T<\/ref.generic_type_param>?<\/decl.function.returntype><\/decl.function.method.instance>", + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 148, + "key.line" : 12, + "key.modulename" : "Commandant", + "key.name" : "remove(_:)", + "key.namelength" : 19, + "key.nameoffset" : 286, + "key.offset" : 281, + "key.parsed_declaration" : "mutating func remove(_ member: T) -> T?", + "key.parsed_scope.end" : 18, + "key.parsed_scope.start" : 12, + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : " (inout OrderedSet) -> (T) -> T?", + "key.typeusr" : "$syxSgxcD", + "key.usr" : "s:10Commandant10OrderedSetV6removeyxSgxF" + } + ], + "key.typename" : "OrderedSet.Type", + "key.typeusr" : "$s10Commandant10OrderedSetVyxGmD", + "key.usr" : "s:10Commandant10OrderedSetV" + }, + { + "key.annotated_decl" : "internal struct OrderedSet<T> : Equatable<\/Type> where T<\/Type> : Hashable<\/Type><\/Declaration>", + "key.bodylength" : 331, + "key.bodyoffset" : 467, + "key.column" : 17, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A poor man's ordered set.", + "key.doc.column" : 17, + "key.doc.declaration" : "internal struct OrderedSet : Equatable where T : Hashable", + "key.doc.file" : "\/private\/Sources\/Commandant\/OrderedSet.swift", + "key.doc.full_as_xml" : "OrderedSet<\/Name>s:10Commandant10OrderedSetV<\/USR>internal struct OrderedSet<T> : Equatable where T : Hashable<\/Declaration>A poor man’s ordered set.<\/Para><\/Abstract><\/CommentParts><\/Class>", + "key.doc.line" : 2, + "key.doc.name" : "OrderedSet", + "key.doc.type" : "Class", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 10, + "key.offset" : 455 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "internal<\/syntaxtype.keyword> struct<\/syntaxtype.keyword> OrderedSet<\/decl.name><T<\/decl.generic_type_param.name><\/decl.generic_type_param>> : Equatable<\/ref.protocol> where<\/syntaxtype.keyword> T<\/ref.generic_type_param> : Hashable<\/ref.protocol><\/decl.generic_type_requirement><\/decl.struct>", + "key.inheritedtypes" : [ + { + "key.name" : "Collection" + } + ], + "key.kind" : "source.lang.swift.decl.extension", + "key.length" : 366, + "key.line" : 2, + "key.modulename" : "Commandant", + "key.name" : "OrderedSet", + "key.namelength" : 10, + "key.nameoffset" : 443, + "key.offset" : 433, + "key.parsed_declaration" : "extension OrderedSet: Collection", + "key.parsed_scope.end" : 45, + "key.parsed_scope.start" : 21, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "subscript(position: Int<\/Type>) -> T<\/Type> { get }<\/Declaration>", + "key.bodylength" : 28, + "key.bodyoffset" : 500, + "key.column" : 2, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Accesses the element at the specified position.\n\nThe following example accesses an element of an array through its\nsubscript to print its value:\n\n var streets = [\"Adams\", \"Bryant\", \"Channing\", \"Douglas\", \"Evarts\"]\n print(streets[1])\n \/\/ Prints \"Bryant\"\n\nYou can subscript a collection with any valid index other than the\ncollection's end index. The end index refers to the position one past\nthe last element of a collection, so it doesn't correspond with an\nelement.\n\n- Parameter position: The position of the element to access. `position`\n must be a valid index of the collection that is not equal to the\n `endIndex` property.\n\n- Complexity: O(1)", + "key.doc.declaration" : "subscript(position: Self.Index) -> Self.Element { get }", + "key.doc.discussion" : [ + { + "Para" : "The following example accesses an element of an array through its subscript to print its value:" + }, + { + "CodeListing" : "" + }, + { + "Para" : "You can subscript a collection with any valid index other than the collection’s end index. The end index refers to the position one past the last element of a collection, so it doesn’t correspond with an element." + }, + { + "Complexity" : "" + }, + { + "Note" : "" + } + ], + "key.doc.full_as_xml" : "subscript(_:)<\/Name>s:Sly7ElementQz5IndexQzcip<\/USR>subscript(position: Self.Index) -> Self.Element { get }<\/Declaration>Accesses the element at the specified position.<\/Para><\/Abstract>position<\/Name>in<\/Direction>The position of the element to access. position<\/codeVoice> must be a valid index of the collection that is not equal to the endIndex<\/codeVoice> property.<\/Para><\/Discussion><\/Parameter><\/Parameters>The following example accesses an element of an array through its subscript to print its value:<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>You can subscript a collection with any valid index other than the collection’s end index. The end index refers to the position one past the last element of a collection, so it doesn’t correspond with an element.<\/Para>O(1)<\/Para><\/Complexity>This documentation comment was inherited from Collection<\/codeVoice>.<\/Para><\/Note><\/Discussion><\/CommentParts><\/Other>", + "key.doc.name" : "subscript(_:)", + "key.doc.parameters" : [ + { + "discussion" : [ + { + "Para" : "The position of the element to access. `position` must be a valid index of the collection that is not equal to the `endIndex` property." + } + ], + "name" : "position" + } + ], + "key.doc.type" : "Other", + "key.filepath" : "", + "key.fully_annotated_decl" : "subscript<\/syntaxtype.keyword>(position<\/decl.var.parameter.name>: Int<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>) -> T<\/ref.generic_type_param><\/decl.function.returntype> { get<\/syntaxtype.keyword> }<\/decl.function.subscript>", + "key.kind" : "source.lang.swift.decl.function.subscript", + "key.length" : 60, + "key.line" : 22, + "key.modulename" : "Commandant", + "key.name" : "subscript(_:)", + "key.namelength" : 24, + "key.nameoffset" : 469, + "key.offset" : 469, + "key.overrides" : [ + { + "key.usr" : "s:Sly7ElementQz5IndexQzcip" + } + ], + "key.parsed_declaration" : "subscript(position: Int) -> T", + "key.parsed_scope.end" : 24, + "key.parsed_scope.start" : 22, + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : " (Int) -> T", + "key.typeusr" : "$syxSicD", + "key.usr" : "s:Sly7ElementQz5IndexQzcip" + }, + { + "key.annotated_decl" : "var count: Int<\/Type> { get }<\/Declaration>", + "key.bodylength" : 24, + "key.bodyoffset" : 548, + "key.column" : 6, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "The number of elements in the collection.\n\nTo check whether a collection is empty, use its `isEmpty` property\ninstead of comparing `count` to zero. Unless the collection guarantees\nrandom-access performance, calculating `count` can be an O(*n*)\noperation.\n\n- Complexity: O(1) if the collection conforms to\n `RandomAccessCollection`; otherwise, O(*n*), where *n* is the length\n of the collection.", + "key.doc.declaration" : "var count: Int { get }", + "key.doc.discussion" : [ + { + "Para" : "To check whether a collection is empty, use its `isEmpty` property instead of comparing `count` to zero. Unless the collection guarantees random-access performance, calculating `count` can be an O() operation." + }, + { + "Complexity" : "" + }, + { + "Note" : "" + } + ], + "key.doc.full_as_xml" : "count<\/Name>s:Sl5countSivp<\/USR>var count: Int { get }<\/Declaration>The number of elements in the collection.<\/Para><\/Abstract>To check whether a collection is empty, use its isEmpty<\/codeVoice> property instead of comparing count<\/codeVoice> to zero. Unless the collection guarantees random-access performance, calculating count<\/codeVoice> can be an O(n<\/emphasis>) operation.<\/Para>O(1) if the collection conforms to RandomAccessCollection<\/codeVoice>; otherwise, O(n<\/emphasis>), where n<\/emphasis> is the length of the collection.<\/Para><\/Complexity>This documentation comment was inherited from Collection<\/codeVoice>.<\/Para><\/Note><\/Discussion><\/CommentParts><\/Other>", + "key.doc.name" : "count", + "key.doc.type" : "Other", + "key.filepath" : "", + "key.fully_annotated_decl" : "var<\/syntaxtype.keyword> count<\/decl.name>: Int<\/ref.struct><\/decl.var.type> { get<\/syntaxtype.keyword> }<\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 41, + "key.line" : 26, + "key.modulename" : "Commandant", + "key.name" : "count", + "key.namelength" : 5, + "key.nameoffset" : 536, + "key.offset" : 532, + "key.overrides" : [ + { + "key.usr" : "s:Sl5countSivp" + } + ], + "key.parsed_declaration" : "var count: Int", + "key.parsed_scope.end" : 28, + "key.parsed_scope.start" : 26, + "key.reusingastcontext" : false, + "key.typename" : "Int", + "key.typeusr" : "$sSiD", + "key.usr" : "s:Sl5countSivp" + }, + { + "key.annotated_decl" : "var isEmpty: Bool<\/Type> { get }<\/Declaration>", + "key.bodylength" : 26, + "key.bodyoffset" : 595, + "key.column" : 6, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A Boolean value indicating whether the collection is empty.\n\nWhen you need to check whether your collection is empty, use the\n`isEmpty` property instead of checking that the `count` property is\nequal to zero. For collections that don't conform to\n`RandomAccessCollection`, accessing the `count` property iterates\nthrough the elements of the collection.\n\n let horseName = \"Silver\"\n if horseName.isEmpty {\n print(\"My horse has no name.\")\n } else {\n print(\"Hi ho, \\(horseName)!\")\n }\n \/\/ Prints \"Hi ho, Silver!\"\n\n- Complexity: O(1)", + "key.doc.declaration" : "var isEmpty: Bool { get }", + "key.doc.discussion" : [ + { + "Para" : "When you need to check whether your collection is empty, use the `isEmpty` property instead of checking that the `count` property is equal to zero. For collections that don’t conform to `RandomAccessCollection`, accessing the `count` property iterates through the elements of the collection." + }, + { + "CodeListing" : "" + }, + { + "Complexity" : "" + }, + { + "Note" : "" + } + ], + "key.doc.full_as_xml" : "isEmpty<\/Name>s:Sl7isEmptySbvp<\/USR>var isEmpty: Bool { get }<\/Declaration>A Boolean value indicating whether the collection is empty.<\/Para><\/Abstract>When you need to check whether your collection is empty, use the isEmpty<\/codeVoice> property instead of checking that the count<\/codeVoice> property is equal to zero. For collections that don’t conform to RandomAccessCollection<\/codeVoice>, accessing the count<\/codeVoice> property iterates through the elements of the collection.<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>O(1)<\/Para><\/Complexity>This documentation comment was inherited from Collection<\/codeVoice>.<\/Para><\/Note><\/Discussion><\/CommentParts><\/Other>", + "key.doc.name" : "isEmpty", + "key.doc.type" : "Other", + "key.filepath" : "", + "key.fully_annotated_decl" : "var<\/syntaxtype.keyword> isEmpty<\/decl.name>: Bool<\/ref.struct><\/decl.var.type> { get<\/syntaxtype.keyword> }<\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 46, + "key.line" : 30, + "key.modulename" : "Commandant", + "key.name" : "isEmpty", + "key.namelength" : 7, + "key.nameoffset" : 580, + "key.offset" : 576, + "key.overrides" : [ + { + "key.usr" : "s:Sl7isEmptySbvp" + } + ], + "key.parsed_declaration" : "var isEmpty: Bool", + "key.parsed_scope.end" : 32, + "key.parsed_scope.start" : 30, + "key.reusingastcontext" : false, + "key.typename" : "Bool", + "key.typeusr" : "$sSbD", + "key.usr" : "s:Sl7isEmptySbvp" + }, + { + "key.annotated_decl" : "var startIndex: Int<\/Type> { get }<\/Declaration>", + "key.bodylength" : 29, + "key.bodyoffset" : 646, + "key.column" : 6, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "The position of the first element in a nonempty collection.\n\nIf the collection is empty, `startIndex` is equal to `endIndex`.", + "key.doc.declaration" : "var startIndex: Self.Index { get }", + "key.doc.discussion" : [ + { + "Para" : "If the collection is empty, `startIndex` is equal to `endIndex`." + }, + { + "Note" : "" + } + ], + "key.doc.full_as_xml" : "startIndex<\/Name>s:Sl10startIndex0B0Qzvp<\/USR>var startIndex: Self.Index { get }<\/Declaration>The position of the first element in a nonempty collection.<\/Para><\/Abstract>If the collection is empty, startIndex<\/codeVoice> is equal to endIndex<\/codeVoice>.<\/Para>This documentation comment was inherited from Collection<\/codeVoice>.<\/Para><\/Note><\/Discussion><\/CommentParts><\/Other>", + "key.doc.name" : "startIndex", + "key.doc.type" : "Other", + "key.filepath" : "", + "key.fully_annotated_decl" : "var<\/syntaxtype.keyword> startIndex<\/decl.name>: Int<\/ref.struct><\/decl.var.type> { get<\/syntaxtype.keyword> }<\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 51, + "key.line" : 34, + "key.modulename" : "Commandant", + "key.name" : "startIndex", + "key.namelength" : 10, + "key.nameoffset" : 629, + "key.offset" : 625, + "key.overrides" : [ + { + "key.usr" : "s:Sl10startIndex0B0Qzvp" + } + ], + "key.parsed_declaration" : "var startIndex: Int", + "key.parsed_scope.end" : 36, + "key.parsed_scope.start" : 34, + "key.reusingastcontext" : false, + "key.typename" : "Int", + "key.typeusr" : "$sSiD", + "key.usr" : "s:Sl10startIndex0B0Qzvp" + }, + { + "key.annotated_decl" : "var endIndex: Int<\/Type> { get }<\/Declaration>", + "key.bodylength" : 27, + "key.bodyoffset" : 698, + "key.column" : 6, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "The collection's \"past the end\" position---that is, the position one\ngreater than the last valid subscript argument.\n\nWhen you need a range that includes the last element of a collection, use\nthe half-open range operator (`..<`) with `endIndex`. The `..<` operator\ncreates a range that doesn't include the upper bound, so it's always\nsafe to use with `endIndex`. For example:\n\n let numbers = [10, 20, 30, 40, 50]\n if let index = numbers.firstIndex(of: 30) {\n print(numbers[index ..< numbers.endIndex])\n }\n \/\/ Prints \"[30, 40, 50]\"\n\nIf the collection is empty, `endIndex` is equal to `startIndex`.", + "key.doc.declaration" : "var endIndex: Self.Index { get }", + "key.doc.discussion" : [ + { + "Para" : "When you need a range that includes the last element of a collection, use the half-open range operator (`..<`) with `endIndex`. The `..<` operator creates a range that doesn’t include the upper bound, so it’s always safe to use with `endIndex`. For example:" + }, + { + "CodeListing" : "" + }, + { + "Para" : "If the collection is empty, `endIndex` is equal to `startIndex`." + }, + { + "Note" : "" + } + ], + "key.doc.full_as_xml" : "endIndex<\/Name>s:Sl8endIndex0B0Qzvp<\/USR>var endIndex: Self.Index { get }<\/Declaration>The collection’s “past the end” position—that is, the position one greater than the last valid subscript argument.<\/Para><\/Abstract>When you need a range that includes the last element of a collection, use the half-open range operator (..<<\/codeVoice>) with endIndex<\/codeVoice>. The ..<<\/codeVoice> operator creates a range that doesn’t include the upper bound, so it’s always safe to use with endIndex<\/codeVoice>. For example:<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>If the collection is empty, endIndex<\/codeVoice> is equal to startIndex<\/codeVoice>.<\/Para>This documentation comment was inherited from Collection<\/codeVoice>.<\/Para><\/Note><\/Discussion><\/CommentParts><\/Other>", + "key.doc.name" : "endIndex", + "key.doc.type" : "Other", + "key.filepath" : "", + "key.fully_annotated_decl" : "var<\/syntaxtype.keyword> endIndex<\/decl.name>: Int<\/ref.struct><\/decl.var.type> { get<\/syntaxtype.keyword> }<\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 47, + "key.line" : 38, + "key.modulename" : "Commandant", + "key.name" : "endIndex", + "key.namelength" : 8, + "key.nameoffset" : 683, + "key.offset" : 679, + "key.overrides" : [ + { + "key.usr" : "s:Sl8endIndex0B0Qzvp" + } + ], + "key.parsed_declaration" : "var endIndex: Int", + "key.parsed_scope.end" : 40, + "key.parsed_scope.start" : 38, + "key.reusingastcontext" : false, + "key.typename" : "Int", + "key.typeusr" : "$sSiD", + "key.usr" : "s:Sl8endIndex0B0Qzvp" + }, + { + "key.annotated_decl" : "func index(after i: Int<\/Type>) -> Int<\/Type><\/Declaration>", + "key.bodylength" : 34, + "key.bodyoffset" : 762, + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Returns the position immediately after the given index.\n\nThe successor of an index must be well defined. For an index `i` into a\ncollection `c`, calling `c.index(after: i)` returns the same index every\ntime.\n\n- Parameter i: A valid index of the collection. `i` must be less than\n `endIndex`.\n- Returns: The index value immediately after `i`.", + "key.doc.declaration" : "func index(after i: Self.Index) -> Self.Index", + "key.doc.discussion" : [ + { + "Para" : "The successor of an index must be well defined. For an index `i` into a collection `c`, calling `c.index(after: i)` returns the same index every time." + }, + { + "Note" : "" + } + ], + "key.doc.full_as_xml" : "index(after:)<\/Name>s:Sl5index5after5IndexQzAD_tF<\/USR>func index(after i: Self.Index) -> Self.Index<\/Declaration>Returns the position immediately after the given index.<\/Para><\/Abstract>i<\/Name>in<\/Direction>A valid index of the collection. i<\/codeVoice> must be less than endIndex<\/codeVoice>.<\/Para><\/Discussion><\/Parameter><\/Parameters>The index value immediately after i<\/codeVoice>.<\/Para><\/ResultDiscussion>The successor of an index must be well defined. For an index i<\/codeVoice> into a collection c<\/codeVoice>, calling c.index(after: i)<\/codeVoice> returns the same index every time.<\/Para>This documentation comment was inherited from Collection<\/codeVoice>.<\/Para><\/Note><\/Discussion><\/CommentParts><\/Function>", + "key.doc.name" : "index(after:)", + "key.doc.parameters" : [ + { + "discussion" : [ + { + "Para" : "A valid index of the collection. `i` must be less than `endIndex`." + } + ], + "name" : "i" + } + ], + "key.doc.result_discussion" : [ + { + "Para" : "The index value immediately after `i`." + } + ], + "key.doc.type" : "Function", + "key.filepath" : "", + "key.fully_annotated_decl" : "func<\/syntaxtype.keyword> index<\/decl.name>(after<\/decl.var.parameter.argument_label> i<\/decl.var.parameter.name>: Int<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>) -> Int<\/ref.struct><\/decl.function.returntype><\/decl.function.method.instance>", + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 68, + "key.line" : 42, + "key.modulename" : "Commandant", + "key.name" : "index(after:)", + "key.namelength" : 19, + "key.nameoffset" : 734, + "key.offset" : 729, + "key.overrides" : [ + { + "key.usr" : "s:Sl5index5after5IndexQzAD_tF" + } + ], + "key.parsed_declaration" : "func index(after i: Int) -> Int", + "key.parsed_scope.end" : 44, + "key.parsed_scope.start" : 42, + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : " (OrderedSet) -> (Int) -> Int", + "key.typeusr" : "$s5afterS2i_tcD", + "key.usr" : "s:Sl5index5after5IndexQzAD_tF" + } + ], + "key.typename" : "OrderedSet.Type", + "key.typeusr" : "$s10Commandant10OrderedSetVyxGmD", + "key.usr" : "s:10Commandant10OrderedSetV" + } + ] + } +}, { + "\/Sources\/Commandant\/Result+Additions.swift" : { + "key.diagnostic_stage" : "source.diagnostic.stage.swift.parse", + "key.length" : 421, + "key.offset" : 0, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "@frozen enum Result<Success, Failure> where Failure<\/Type> : Error<\/Type>, Success<\/Type> : ~Copyable<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.internal", + "key.length" : 8, + "key.offset" : 148 + } + ], + "key.bodylength" : 244, + "key.bodyoffset" : 175, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A value that represents either a success or a failure, including an\nassociated value in each case.", + "key.doc.declaration" : "@frozen enum Result where Failure : Error, Success : ~Copyable", + "key.doc.full_as_xml" : "Result<\/Name>s:s6ResultO<\/USR>@frozen enum Result<Success, Failure> where Failure : Error, Success : ~Copyable<\/Declaration>A value that represents either a success or a failure, including an associated value in each case.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.name" : "Result", + "key.doc.type" : "Other", + "key.fully_annotated_decl" : "@frozen<\/syntaxtype.attribute.name><\/syntaxtype.attribute.builtin> enum<\/syntaxtype.keyword> Result<\/decl.name><Success<\/decl.generic_type_param.name><\/decl.generic_type_param>, Failure<\/decl.generic_type_param.name><\/decl.generic_type_param>> where<\/syntaxtype.keyword> Failure<\/ref.generic_type_param> : Error<\/ref.protocol><\/decl.generic_type_requirement>, Success<\/ref.generic_type_param> : <\/decl.generic_type_requirement>~Copyable<\/decl.enum>", + "key.groupname" : "Result", + "key.is_system" : true, + "key.kind" : "source.lang.swift.decl.extension", + "key.length" : 263, + "key.modulename" : "Swift", + "key.name" : "Result", + "key.namelength" : 6, + "key.nameoffset" : 167, + "key.offset" : 157, + "key.parsed_declaration" : "internal extension Result", + "key.parsed_scope.end" : 27, + "key.parsed_scope.start" : 9, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "var value: Success<\/Type>? { get }<\/Declaration>", + "key.bodylength" : 97, + "key.bodyoffset" : 198, + "key.column" : 6, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "var<\/syntaxtype.keyword> value<\/decl.name>: Success<\/ref.generic_type_param>?<\/decl.var.type> { get<\/syntaxtype.keyword> }<\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 119, + "key.line" : 10, + "key.modulename" : "Commandant", + "key.name" : "value", + "key.namelength" : 5, + "key.nameoffset" : 181, + "key.offset" : 177, + "key.parsed_declaration" : "var value: Success?", + "key.parsed_scope.end" : 17, + "key.parsed_scope.start" : 10, + "key.reusingastcontext" : false, + "key.typename" : "Success?", + "key.typeusr" : "$sxSgD", + "key.usr" : "s:s6ResultO10CommandantE5valuexSgvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "var error: Failure<\/Type>? { get }<\/Declaration>", + "key.bodylength" : 97, + "key.bodyoffset" : 320, + "key.column" : 6, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "var<\/syntaxtype.keyword> error<\/decl.name>: Failure<\/ref.generic_type_param>?<\/decl.var.type> { get<\/syntaxtype.keyword> }<\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 119, + "key.line" : 19, + "key.modulename" : "Commandant", + "key.name" : "error", + "key.namelength" : 5, + "key.nameoffset" : 303, + "key.offset" : 299, + "key.parsed_declaration" : "var error: Failure?", + "key.parsed_scope.end" : 26, + "key.parsed_scope.start" : 19, + "key.reusingastcontext" : false, + "key.typename" : "Failure?", + "key.typeusr" : "$sq_SgD", + "key.usr" : "s:s6ResultO10CommandantE5errorq_Sgvp" + } + ], + "key.typename" : "Result.Type", + "key.typeusr" : "$ss6ResultOyxq_GmD", + "key.usr" : "s:s6ResultO" + } + ] + } +}, { + "\/Sources\/Commandant\/Switch.swift" : { + "key.diagnostic_stage" : "source.diagnostic.stage.swift.parse", + "key.length" : 2007, + "key.offset" : 0, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public struct Switch<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 375 + } + ], + "key.bodylength" : 724, + "key.bodyoffset" : 397, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Describes a parameterless command line flag that defaults to false and can only\nbe switched on. Canonical examples include `--force` and `--recurse`.\n\nFor a boolean toggle that can be enabled and disabled use `Option`.", + "key.doc.column" : 15, + "key.doc.comment" : "Describes a parameterless command line flag that defaults to false and can only\nbe switched on. Canonical examples include `--force` and `--recurse`.\n\nFor a boolean toggle that can be enabled and disabled use `Option`.", + "key.doc.declaration" : "public struct Switch", + "key.doc.discussion" : [ + { + "Para" : "For a boolean toggle that can be enabled and disabled use `Option`." + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Switch.swift", + "key.doc.full_as_xml" : "Switch<\/Name>s:10Commandant6SwitchV<\/USR>public struct Switch<\/Declaration>Describes a parameterless command line flag that defaults to false and can only be switched on. Canonical examples include --force<\/codeVoice> and --recurse<\/codeVoice>.<\/Para><\/Abstract>For a boolean toggle that can be enabled and disabled use Option<Bool><\/codeVoice>.<\/Para><\/Discussion><\/CommentParts><\/Class>", + "key.doc.line" : 13, + "key.doc.name" : "Switch", + "key.doc.type" : "Class", + "key.doclength" : 240, + "key.docoffset" : 135, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> struct<\/syntaxtype.keyword> Switch<\/decl.name><\/decl.struct>", + "key.kind" : "source.lang.swift.decl.struct", + "key.length" : 740, + "key.line" : 13, + "key.modulename" : "Commandant", + "key.name" : "Switch", + "key.namelength" : 6, + "key.nameoffset" : 389, + "key.offset" : 382, + "key.parsed_declaration" : "public struct Switch", + "key.parsed_scope.end" : 34, + "key.parsed_scope.start" : 13, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public let key: String<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 515 + } + ], + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "The key that enables this switch. For example, a key of `verbose` would be\nused for a `--verbose` option.", + "key.doc.column" : 13, + "key.doc.comment" : "The key that enables this switch. For example, a key of `verbose` would be\nused for a `--verbose` option.", + "key.doc.declaration" : "public let key: String", + "key.doc.file" : "\/private\/Sources\/Commandant\/Switch.swift", + "key.doc.full_as_xml" : "key<\/Name>s:10Commandant6SwitchV3keySSvp<\/USR>public let key: String<\/Declaration>The key that enables this switch. For example, a key of verbose<\/codeVoice> would be used for a --verbose<\/codeVoice> option.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 16, + "key.doc.name" : "key", + "key.doc.type" : "Other", + "key.doclength" : 115, + "key.docoffset" : 399, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> let<\/syntaxtype.keyword> key<\/decl.name>: String<\/ref.struct><\/decl.var.type><\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 15, + "key.line" : 16, + "key.modulename" : "Commandant", + "key.name" : "key", + "key.namelength" : 3, + "key.nameoffset" : 526, + "key.offset" : 522, + "key.parsed_declaration" : "public let key: String", + "key.parsed_scope.end" : 16, + "key.parsed_scope.start" : 16, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant6SwitchV3keySSvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public let flag: Character<\/Type>?<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 828 + } + ], + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Optional single letter flag that enables this switch. For example, `-v` would\nbe used as a shorthand for `--verbose`.\n\nMultiple flags can be grouped together as a single argument and will split\nwhen parsing (e.g. `rm -rf` treats 'r' and 'f' as inidividual flags).", + "key.doc.column" : 13, + "key.doc.comment" : "Optional single letter flag that enables this switch. For example, `-v` would\nbe used as a shorthand for `--verbose`.\n\nMultiple flags can be grouped together as a single argument and will split\nwhen parsing (e.g. `rm -rf` treats 'r' and 'f' as inidividual flags).", + "key.doc.declaration" : "public let flag: Character?", + "key.doc.discussion" : [ + { + "Para" : "Multiple flags can be grouped together as a single argument and will split when parsing (e.g. `rm -rf` treats ‘r’ and ‘f’ as inidividual flags)." + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Switch.swift", + "key.doc.full_as_xml" : "flag<\/Name>s:10Commandant6SwitchV4flagSJSgvp<\/USR>public let flag: Character?<\/Declaration>Optional single letter flag that enables this switch. For example, -v<\/codeVoice> would be used as a shorthand for --verbose<\/codeVoice>.<\/Para><\/Abstract>Multiple flags can be grouped together as a single argument and will split when parsing (e.g. rm -rf<\/codeVoice> treats ‘r’ and ‘f’ as inidividual flags).<\/Para><\/Discussion><\/CommentParts><\/Other>", + "key.doc.line" : 23, + "key.doc.name" : "flag", + "key.doc.type" : "Other", + "key.doclength" : 287, + "key.docoffset" : 540, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> let<\/syntaxtype.keyword> flag<\/decl.name>: Character<\/ref.struct>?<\/decl.var.type><\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 20, + "key.line" : 23, + "key.modulename" : "Commandant", + "key.name" : "flag", + "key.namelength" : 4, + "key.nameoffset" : 839, + "key.offset" : 835, + "key.parsed_declaration" : "public let flag: Character?", + "key.parsed_scope.end" : 23, + "key.parsed_scope.start" : 23, + "key.reusingastcontext" : false, + "key.typename" : "Character?", + "key.typeusr" : "$sSJSgD", + "key.usr" : "s:10Commandant6SwitchV4flagSJSgvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public let usage: String<\/Type><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 968 + } + ], + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A human-readable string describing the purpose of this option. This will\nbe shown in help messages.", + "key.doc.column" : 13, + "key.doc.comment" : "A human-readable string describing the purpose of this option. This will\nbe shown in help messages.", + "key.doc.declaration" : "public let usage: String", + "key.doc.file" : "\/private\/Sources\/Commandant\/Switch.swift", + "key.doc.full_as_xml" : "usage<\/Name>s:10Commandant6SwitchV5usageSSvp<\/USR>public let usage: String<\/Declaration>A human-readable string describing the purpose of this option. This will be shown in help messages.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 27, + "key.doc.name" : "usage", + "key.doc.type" : "Other", + "key.doclength" : 109, + "key.docoffset" : 858, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> let<\/syntaxtype.keyword> usage<\/decl.name>: String<\/ref.struct><\/decl.var.type><\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 17, + "key.line" : 27, + "key.modulename" : "Commandant", + "key.name" : "usage", + "key.namelength" : 5, + "key.nameoffset" : 979, + "key.offset" : 975, + "key.parsed_declaration" : "public let usage: String", + "key.parsed_scope.end" : 27, + "key.parsed_scope.start" : 27, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant6SwitchV5usageSSvp" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public init(flag: Character<\/Type>? = nil, key: String<\/Type>, usage: String<\/Type>)<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 995 + } + ], + "key.bodylength" : 59, + "key.bodyoffset" : 1060, + "key.column" : 9, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> init<\/syntaxtype.keyword>(flag<\/decl.var.parameter.argument_label>: Character<\/ref.struct>?<\/decl.var.parameter.type> = nil<\/decl.var.parameter>, key<\/decl.var.parameter.argument_label>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>, usage<\/decl.var.parameter.argument_label>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>)<\/decl.function.constructor>", + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 118, + "key.line" : 29, + "key.modulename" : "Commandant", + "key.name" : "init(flag:key:usage:)", + "key.namelength" : 56, + "key.nameoffset" : 1002, + "key.offset" : 1002, + "key.parsed_declaration" : "public init(flag: Character? = nil, key: String, usage: String)", + "key.parsed_scope.end" : 33, + "key.parsed_scope.start" : 29, + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : "(Switch.Type) -> (Character?, String, String) -> Switch", + "key.typeusr" : "$s4flag3key5usage10Commandant6SwitchVSJSg_S2StcD", + "key.usr" : "s:10Commandant6SwitchV4flag3key5usageACSJSg_S2Stcfc" + } + ], + "key.typename" : "Switch.Type", + "key.typeusr" : "$s10Commandant6SwitchVmD", + "key.usr" : "s:10Commandant6SwitchV" + }, + { + "key.annotated_decl" : "public struct Switch<\/Declaration>", + "key.bodylength" : 140, + "key.bodyoffset" : 1167, + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Describes a parameterless command line flag that defaults to false and can only\nbe switched on. Canonical examples include `--force` and `--recurse`.\n\nFor a boolean toggle that can be enabled and disabled use `Option`.", + "key.doc.column" : 15, + "key.doc.declaration" : "public struct Switch", + "key.doc.discussion" : [ + { + "Para" : "For a boolean toggle that can be enabled and disabled use `Option`." + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Switch.swift", + "key.doc.full_as_xml" : "Switch<\/Name>s:10Commandant6SwitchV<\/USR>public struct Switch<\/Declaration>Describes a parameterless command line flag that defaults to false and can only be switched on. Canonical examples include --force<\/codeVoice> and --recurse<\/codeVoice>.<\/Para><\/Abstract>For a boolean toggle that can be enabled and disabled use Option<Bool><\/codeVoice>.<\/Para><\/Discussion><\/CommentParts><\/Class>", + "key.doc.line" : 13, + "key.doc.name" : "Switch", + "key.doc.type" : "Class", + "key.elements" : [ + { + "key.kind" : "source.lang.swift.structure.elem.typeref", + "key.length" : 23, + "key.offset" : 1142 + } + ], + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> struct<\/syntaxtype.keyword> Switch<\/decl.name><\/decl.struct>", + "key.inheritedtypes" : [ + { + "key.name" : "CustomStringConvertible" + } + ], + "key.kind" : "source.lang.swift.decl.extension", + "key.length" : 184, + "key.line" : 13, + "key.modulename" : "Commandant", + "key.name" : "Switch", + "key.namelength" : 6, + "key.nameoffset" : 1134, + "key.offset" : 1124, + "key.parsed_declaration" : "extension Switch: CustomStringConvertible", + "key.parsed_scope.end" : 44, + "key.parsed_scope.start" : 36, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public var description: String<\/Type> { get }<\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 1169 + } + ], + "key.bodylength" : 104, + "key.bodyoffset" : 1201, + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A textual representation of this instance.\n\nCalling this property directly is discouraged. Instead, convert an\ninstance of any type to a string by using the `String(describing:)`\ninitializer. This initializer works with any type, and uses the custom\n`description` property for types that conform to\n`CustomStringConvertible`:\n\n struct Point: CustomStringConvertible {\n let x: Int, y: Int\n\n var description: String {\n return \"(\\(x), \\(y))\"\n }\n }\n\n let p = Point(x: 21, y: 30)\n let s = String(describing: p)\n print(s)\n \/\/ Prints \"(21, 30)\"\n\nThe conversion of `p` to a string in the assignment to `s` uses the\n`Point` type's `description` property.", + "key.doc.declaration" : "var description: String { get }", + "key.doc.discussion" : [ + { + "Para" : "Calling this property directly is discouraged. Instead, convert an instance of any type to a string by using the `String(describing:)` initializer. This initializer works with any type, and uses the custom `description` property for types that conform to `CustomStringConvertible`:" + }, + { + "CodeListing" : "" + }, + { + "Para" : "The conversion of `p` to a string in the assignment to `s` uses the `Point` type’s `description` property." + }, + { + "Note" : "" + } + ], + "key.doc.full_as_xml" : "description<\/Name>s:s23CustomStringConvertibleP11descriptionSSvp<\/USR>var description: String { get }<\/Declaration>A textual representation of this instance.<\/Para><\/Abstract>Calling this property directly is discouraged. Instead, convert an instance of any type to a string by using the String(describing:)<\/codeVoice> initializer. This initializer works with any type, and uses the custom description<\/codeVoice> property for types that conform to CustomStringConvertible<\/codeVoice>:<\/Para><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/zCodeLineNumbered><\/CodeListing>The conversion of p<\/codeVoice> to a string in the assignment to s<\/codeVoice> uses the Point<\/codeVoice> type’s description<\/codeVoice> property.<\/Para>This documentation comment was inherited from CustomStringConvertible<\/codeVoice>.<\/Para><\/Note><\/Discussion><\/CommentParts><\/Other>", + "key.doc.name" : "description", + "key.doc.type" : "Other", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> var<\/syntaxtype.keyword> description<\/decl.name>: String<\/ref.struct><\/decl.var.type> { get<\/syntaxtype.keyword> }<\/decl.var.instance>", + "key.kind" : "source.lang.swift.decl.var.instance", + "key.length" : 130, + "key.line" : 37, + "key.modulename" : "Commandant", + "key.name" : "description", + "key.namelength" : 11, + "key.nameoffset" : 1180, + "key.offset" : 1176, + "key.overrides" : [ + { + "key.usr" : "s:s23CustomStringConvertibleP11descriptionSSvp" + } + ], + "key.parsed_declaration" : "public var description: String", + "key.parsed_scope.end" : 43, + "key.parsed_scope.start" : 37, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:s23CustomStringConvertibleP11descriptionSSvp" + }, + { + "key.annotated_decl" : "var options: String<\/Type><\/Declaration>", + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "var<\/syntaxtype.keyword> options<\/decl.name>: String<\/ref.struct><\/decl.var.type><\/decl.var.local>", + "key.kind" : "source.lang.swift.decl.var.local", + "key.length" : 24, + "key.line" : 38, + "key.modulename" : "Commandant", + "key.name" : "options", + "key.namelength" : 7, + "key.nameoffset" : 1208, + "key.offset" : 1204, + "key.parsed_declaration" : "var options = \"--\\(key)\"", + "key.parsed_scope.end" : 38, + "key.parsed_scope.start" : 38, + "key.reusingastcontext" : false, + "key.typename" : "String", + "key.typeusr" : "$sSSD", + "key.usr" : "s:10Commandant6SwitchV11descriptionSSvg7optionsL_SSvp" + } + ], + "key.typename" : "Switch.Type", + "key.typeusr" : "$s10Commandant6SwitchVmD", + "key.usr" : "s:10Commandant6SwitchV" + }, + { + "key.kind" : "source.lang.swift.syntaxtype.comment.mark", + "key.length" : 17, + "key.name" : "MARK: - Operators", + "key.offset" : 1313 + }, + { + "key.annotated_decl" : "public enum CommandMode<\/Declaration>", + "key.bodylength" : 650, + "key.bodyoffset" : 1355, + "key.column" : 13, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Describes the \"mode\" in which a command should run.", + "key.doc.column" : 13, + "key.doc.declaration" : "public enum CommandMode", + "key.doc.file" : "\/private\/Sources\/Commandant\/Command.swift", + "key.doc.full_as_xml" : "CommandMode<\/Name>s:10Commandant11CommandModeO<\/USR>public enum CommandMode<\/Declaration>Describes the “mode” in which a command should run.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 68, + "key.doc.name" : "CommandMode", + "key.doc.type" : "Other", + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> enum<\/syntaxtype.keyword> CommandMode<\/decl.name><\/decl.enum>", + "key.kind" : "source.lang.swift.decl.extension", + "key.length" : 674, + "key.line" : 68, + "key.modulename" : "Commandant", + "key.name" : "CommandMode", + "key.namelength" : 11, + "key.nameoffset" : 1342, + "key.offset" : 1332, + "key.parsed_declaration" : "extension CommandMode", + "key.parsed_scope.end" : 67, + "key.parsed_scope.start" : 48, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.public", + "key.annotated_decl" : "public static func <| <ClientError>(mode: CommandMode<\/Type>, option: Switch<\/Type>) -> Result<\/Type><Bool<\/Type>, CommandantError<\/Type><ClientError<\/Type>>><\/Declaration>", + "key.attributes" : [ + { + "key.attribute" : "source.decl.attribute.public", + "key.length" : 6, + "key.offset" : 1551 + } + ], + "key.bodylength" : 333, + "key.bodyoffset" : 1670, + "key.column" : 21, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Evaluates the given boolean switch in the given mode.\n\nIf parsing command line arguments, and no value was specified on the command\nline, the option's `defaultValue` is used.", + "key.doc.column" : 21, + "key.doc.comment" : "Evaluates the given boolean switch in the given mode.\n\nIf parsing command line arguments, and no value was specified on the command\nline, the option's `defaultValue` is used.", + "key.doc.declaration" : "public static func <| (mode: CommandMode, option: Switch) -> Result>", + "key.doc.discussion" : [ + { + "Para" : "If parsing command line arguments, and no value was specified on the command line, the option’s `defaultValue` is used." + } + ], + "key.doc.file" : "\/private\/Sources\/Commandant\/Switch.swift", + "key.doc.full_as_xml" : "<|(_:_:)<\/Name>s:10Commandant11CommandModeO2looiys6ResultOySbAA0A5ErrorOyxGGAC_AA6SwitchVtlFZ<\/USR>public static func <| <ClientError>(mode: CommandMode, option: Switch) -> Result<Bool, CommandantError<ClientError>><\/Declaration>Evaluates the given boolean switch in the given mode.<\/Para><\/Abstract>If parsing command line arguments, and no value was specified on the command line, the option’s defaultValue<\/codeVoice> is used.<\/Para><\/Discussion><\/CommentParts><\/Function>", + "key.doc.line" : 53, + "key.doc.name" : "<|(_:_:)", + "key.doc.type" : "Function", + "key.doclength" : 193, + "key.docoffset" : 1357, + "key.filepath" : "", + "key.fully_annotated_decl" : "public<\/syntaxtype.keyword> static<\/syntaxtype.keyword> func<\/syntaxtype.keyword> <| <\/decl.name><ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>>(mode<\/decl.var.parameter.name>: CommandMode<\/ref.enum><\/decl.var.parameter.type><\/decl.var.parameter>, option<\/decl.var.parameter.name>: Switch<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>) -> Result<\/ref.enum><Bool<\/ref.struct>, CommandantError<\/ref.enum><ClientError<\/ref.generic_type_param>>><\/decl.function.returntype><\/decl.function.operator.infix>", + "key.kind" : "source.lang.swift.decl.function.method.static", + "key.length" : 446, + "key.line" : 53, + "key.modulename" : "Commandant", + "key.name" : "<|(_:_:)", + "key.namelength" : 52, + "key.nameoffset" : 1570, + "key.offset" : 1558, + "key.parsed_declaration" : "public static func <| (mode: CommandMode, option: Switch) -> Result>", + "key.parsed_scope.end" : 66, + "key.parsed_scope.start" : 53, + "key.related_decls" : [ + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Argument<T>) -> Result<T, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Argument<[T]>) -> Result<[T], CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<T>) -> Result<T, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<T?>) -> Result<T?, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<[T]>) -> Result<[T], CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <T, ClientError>(_: CommandMode, _: Option<[T]?>) -> Result<[T]?, CommandantError<ClientError>> where T : ArgumentProtocol<\/RelatedName>" + }, + { + "key.annotated_decl" : "<| <ClientError>(_: CommandMode, _: Option<Bool>) -> Result<Bool, CommandantError<ClientError>><\/RelatedName>" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "ClientError<\/Declaration>", + "key.column" : 25, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "", + "key.fully_annotated_decl" : "ClientError<\/decl.generic_type_param.name><\/decl.generic_type_param>", + "key.kind" : "source.lang.swift.decl.generic_type_param", + "key.length" : 11, + "key.line" : 53, + "key.modulename" : "Commandant", + "key.name" : "ClientError", + "key.namelength" : 11, + "key.nameoffset" : 1574, + "key.offset" : 1574, + "key.parsed_declaration" : "public static func <| (CommandMode.Type) -> (CommandMode, Switch) -> Result>", + "key.typeusr" : "$sys6ResultOySb10Commandant0B5ErrorOyxGGAC11CommandModeO_AC6SwitchVtcluD", + "key.usr" : "s:10Commandant11CommandModeO2looiys6ResultOySbAA0A5ErrorOyxGGAC_AA6SwitchVtlFZ" + } + ], + "key.typename" : "CommandMode.Type", + "key.typeusr" : "$s10Commandant11CommandModeOmD", + "key.usr" : "s:10Commandant11CommandModeO" + } + ] + } +}] \ No newline at end of file diff --git a/Tests/SourceKittenFrameworkTests/Fixtures/CursorInfoUSR@swift-6.0.json b/Tests/SourceKittenFrameworkTests/Fixtures/CursorInfoUSR@swift-6.0.json new file mode 100644 index 00000000..a1f7a959 --- /dev/null +++ b/Tests/SourceKittenFrameworkTests/Fixtures/CursorInfoUSR@swift-6.0.json @@ -0,0 +1,19 @@ +{ + "key.annotated_decl" : "struct DocumentedStruct<\/Declaration>", + "key.column" : 8, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "A documented struct", + "key.doc.full_as_xml" : "DocumentedStruct<\/Name>s:7DocInfo16DocumentedStructV<\/USR>struct DocumentedStruct<\/Declaration>A documented struct<\/Para><\/Abstract><\/CommentParts><\/Class>", + "key.filepath" : "DocInfo.swift", + "key.fully_annotated_decl" : "struct<\/syntaxtype.keyword> DocumentedStruct<\/decl.name><\/decl.struct>", + "key.kind" : "source.lang.swift.decl.struct", + "key.length" : 16, + "key.line" : 28, + "key.modulename" : "DocInfo", + "key.name" : "DocumentedStruct", + "key.offset" : 416, + "key.reusingastcontext" : false, + "key.typename" : "DocumentedStruct.Type", + "key.typeusr" : "$s7DocInfo16DocumentedStructVmD", + "key.usr" : "s:7DocInfo16DocumentedStructV" +} \ No newline at end of file diff --git a/Tests/SourceKittenFrameworkTests/Fixtures/Extension@swift-6.0.json b/Tests/SourceKittenFrameworkTests/Fixtures/Extension@swift-6.0.json new file mode 100644 index 00000000..dca98431 --- /dev/null +++ b/Tests/SourceKittenFrameworkTests/Fixtures/Extension@swift-6.0.json @@ -0,0 +1,417 @@ +{ + "Extension.swift" : { + "key.diagnostic_stage" : "source.diagnostic.stage.swift.parse", + "key.length" : 504, + "key.offset" : 0, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "class Base<\/Declaration>", + "key.bodylength" : 166, + "key.bodyoffset" : 29, + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Doc for Base", + "key.doc.column" : 7, + "key.doc.comment" : "Doc for Base", + "key.doc.declaration" : "class Base", + "key.doc.file" : "Extension.swift", + "key.doc.full_as_xml" : "Base<\/Name>s:9Extension4BaseC<\/USR>class Base<\/Declaration>Doc for Base<\/Para><\/Abstract><\/CommentParts><\/Class>", + "key.doc.line" : 2, + "key.doc.name" : "Base", + "key.doc.type" : "Class", + "key.doclength" : 17, + "key.docoffset" : 0, + "key.filepath" : "Extension.swift", + "key.fully_annotated_decl" : "class<\/syntaxtype.keyword> Base<\/decl.name><\/decl.class>", + "key.kind" : "source.lang.swift.decl.class", + "key.length" : 179, + "key.line" : 2, + "key.modulename" : "Extension", + "key.name" : "Base", + "key.namelength" : 4, + "key.nameoffset" : 23, + "key.offset" : 17, + "key.parsed_declaration" : "class Base", + "key.parsed_scope.end" : 14, + "key.parsed_scope.start" : 2, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "typealias Base<\/Type>.Index = Int<\/Type><\/Declaration>", + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Doc for Base.Index", + "key.doc.column" : 15, + "key.doc.comment" : "Doc for Base.Index", + "key.doc.declaration" : "typealias Extension.Base.Index = Int", + "key.doc.file" : "Extension.swift", + "key.doc.full_as_xml" : "Index<\/Name>s:9Extension4BaseC5Indexa<\/USR>typealias Extension.Base.Index = Int<\/Declaration>Doc for Base.Index<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 5, + "key.doc.name" : "Index", + "key.doc.type" : "Other", + "key.doclength" : 23, + "key.docoffset" : 35, + "key.filepath" : "Extension.swift", + "key.fully_annotated_decl" : "typealias<\/syntaxtype.keyword> Base<\/ref.class>.Index<\/decl.name> = Int<\/ref.struct><\/decl.typealias>", + "key.is_dynamic" : true, + "key.kind" : "source.lang.swift.decl.typealias", + "key.length" : 21, + "key.line" : 5, + "key.modulename" : "Extension", + "key.name" : "Index", + "key.namelength" : 5, + "key.nameoffset" : 72, + "key.offset" : 62, + "key.parsed_declaration" : "typealias Index = Int", + "key.parsed_scope.end" : 5, + "key.parsed_scope.start" : 5, + "key.receivers" : [ + { + "key.usr" : "s:9Extension4BaseC" + } + ], + "key.reusingastcontext" : false, + "key.typename" : "Int.Type", + "key.typeusr" : "$sSimD", + "key.usr" : "s:9Extension4BaseC5Indexa" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "func f(index: Index<\/Type>)<\/Declaration>", + "key.bodylength" : 5, + "key.bodyoffset" : 134, + "key.column" : 10, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Doc for Base.f", + "key.doc.column" : 10, + "key.doc.comment" : "Doc for Base.f", + "key.doc.declaration" : "func f(index: Index)", + "key.doc.file" : "Extension.swift", + "key.doc.full_as_xml" : "f(index:)<\/Name>s:9Extension4BaseC1f5indexySi_tF<\/USR>func f(index: Index)<\/Declaration>Doc for Base.f<\/Para><\/Abstract><\/CommentParts><\/Function>", + "key.doc.line" : 8, + "key.doc.name" : "f(index:)", + "key.doc.type" : "Function", + "key.doclength" : 19, + "key.docoffset" : 89, + "key.filepath" : "Extension.swift", + "key.fully_annotated_decl" : "func<\/syntaxtype.keyword> f<\/decl.name>(index<\/decl.var.parameter.argument_label>: Index<\/ref.typealias><\/decl.var.parameter.type><\/decl.var.parameter>)<\/decl.function.method.instance>", + "key.is_dynamic" : true, + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 28, + "key.line" : 8, + "key.modulename" : "Extension", + "key.name" : "f(index:)", + "key.namelength" : 15, + "key.nameoffset" : 117, + "key.offset" : 112, + "key.parsed_declaration" : "func f(index: Index)", + "key.parsed_scope.end" : 9, + "key.parsed_scope.start" : 8, + "key.receivers" : [ + { + "key.usr" : "s:9Extension4BaseC" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : "(Base) -> (Int) -> ()", + "key.typeusr" : "$s5indexySi_tcD", + "key.usr" : "s:9Extension4BaseC1f5indexySi_tF" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "class Base<\/Type>.Nested<\/Declaration>", + "key.bodylength" : 5, + "key.bodyoffset" : 188, + "key.column" : 11, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Doc for Base.Nested", + "key.doc.column" : 11, + "key.doc.comment" : "Doc for Base.Nested", + "key.doc.declaration" : "class Extension.Base.Nested", + "key.doc.file" : "Extension.swift", + "key.doc.full_as_xml" : "Nested<\/Name>s:9Extension4BaseC6NestedC<\/USR>class Extension.Base.Nested<\/Declaration>Doc for Base.Nested<\/Para><\/Abstract><\/CommentParts><\/Class>", + "key.doc.line" : 12, + "key.doc.name" : "Nested", + "key.doc.type" : "Class", + "key.doclength" : 24, + "key.docoffset" : 146, + "key.filepath" : "Extension.swift", + "key.fully_annotated_decl" : "class<\/syntaxtype.keyword> Base<\/ref.class>.Nested<\/decl.name><\/decl.class>", + "key.is_dynamic" : true, + "key.kind" : "source.lang.swift.decl.class", + "key.length" : 20, + "key.line" : 12, + "key.modulename" : "Extension", + "key.name" : "Nested", + "key.namelength" : 6, + "key.nameoffset" : 180, + "key.offset" : 174, + "key.parsed_declaration" : "class Nested", + "key.parsed_scope.end" : 13, + "key.parsed_scope.start" : 12, + "key.receivers" : [ + { + "key.usr" : "s:9Extension4BaseC" + } + ], + "key.reusingastcontext" : false, + "key.typename" : "Base.Nested.Type", + "key.typeusr" : "$s9Extension4BaseC6NestedCmD", + "key.usr" : "s:9Extension4BaseC6NestedC" + } + ], + "key.typename" : "Base.Type", + "key.typeusr" : "$s9Extension4BaseCmD", + "key.usr" : "s:9Extension4BaseC" + }, + { + "key.annotated_decl" : "class Base<\/Declaration>", + "key.bodylength" : 155, + "key.bodyoffset" : 214, + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Doc for Base", + "key.doc.column" : 7, + "key.doc.declaration" : "class Base", + "key.doc.file" : "Extension.swift", + "key.doc.full_as_xml" : "Base<\/Name>s:9Extension4BaseC<\/USR>class Base<\/Declaration>Doc for Base<\/Para><\/Abstract><\/CommentParts><\/Class>", + "key.doc.line" : 2, + "key.doc.name" : "Base", + "key.doc.type" : "Class", + "key.filepath" : "Extension.swift", + "key.fully_annotated_decl" : "class<\/syntaxtype.keyword> Base<\/decl.name><\/decl.class>", + "key.kind" : "source.lang.swift.decl.extension", + "key.length" : 172, + "key.line" : 2, + "key.modulename" : "Extension", + "key.name" : "Base", + "key.namelength" : 4, + "key.nameoffset" : 208, + "key.offset" : 198, + "key.parsed_declaration" : "extension Base", + "key.parsed_scope.end" : 24, + "key.parsed_scope.start" : 16, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.annotated_decl" : "typealias ExtendedIndex = Double<\/Type><\/Declaration>", + "key.column" : 15, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Doc for Base.ExtendedIndex", + "key.doc.column" : 15, + "key.doc.comment" : "Doc for Base.ExtendedIndex", + "key.doc.declaration" : "typealias ExtendedIndex = Double", + "key.doc.file" : "Extension.swift", + "key.doc.full_as_xml" : "ExtendedIndex<\/Name>s:9Extension4BaseC13ExtendedIndexa<\/USR>typealias ExtendedIndex = Double<\/Declaration>Doc for Base.ExtendedIndex<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 19, + "key.doc.name" : "ExtendedIndex", + "key.doc.type" : "Other", + "key.doclength" : 31, + "key.docoffset" : 220, + "key.filepath" : "Extension.swift", + "key.fully_annotated_decl" : "typealias<\/syntaxtype.keyword> ExtendedIndex<\/decl.name> = Double<\/ref.struct><\/decl.typealias>", + "key.is_dynamic" : true, + "key.kind" : "source.lang.swift.decl.typealias", + "key.length" : 32, + "key.line" : 19, + "key.modulename" : "Extension", + "key.name" : "ExtendedIndex", + "key.namelength" : 13, + "key.nameoffset" : 265, + "key.offset" : 255, + "key.parsed_declaration" : "typealias ExtendedIndex = Double", + "key.parsed_scope.end" : 19, + "key.parsed_scope.start" : 19, + "key.receivers" : [ + { + "key.usr" : "s:9Extension4BaseC" + } + ], + "key.reusingastcontext" : false, + "key.typename" : "Double.Type", + "key.typeusr" : "$sSdmD", + "key.usr" : "s:9Extension4BaseC13ExtendedIndexa" + }, + { + "key.annotated_decl" : "func extendedF(index: ExtendedIndex<\/Type>)<\/Declaration>", + "key.bodylength" : 5, + "key.bodyoffset" : 362, + "key.column" : 10, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Doc for Base.extendedF", + "key.doc.column" : 10, + "key.doc.comment" : "Doc for Base.extendedF", + "key.doc.declaration" : "func extendedF(index: ExtendedIndex)", + "key.doc.file" : "Extension.swift", + "key.doc.full_as_xml" : "extendedF(index:)<\/Name>s:9Extension4BaseC9extendedF5indexySd_tF<\/USR>func extendedF(index: ExtendedIndex)<\/Declaration>Doc for Base.extendedF<\/Para><\/Abstract><\/CommentParts><\/Function>", + "key.doc.line" : 22, + "key.doc.name" : "extendedF(index:)", + "key.doc.type" : "Function", + "key.doclength" : 27, + "key.docoffset" : 293, + "key.filepath" : "Extension.swift", + "key.fully_annotated_decl" : "func<\/syntaxtype.keyword> extendedF<\/decl.name>(index<\/decl.var.parameter.argument_label>: ExtendedIndex<\/ref.typealias><\/decl.var.parameter.type><\/decl.var.parameter>)<\/decl.function.method.instance>", + "key.is_dynamic" : true, + "key.kind" : "source.lang.swift.decl.function.method.instance", + "key.length" : 44, + "key.line" : 22, + "key.modulename" : "Extension", + "key.name" : "extendedF(index:)", + "key.namelength" : 31, + "key.nameoffset" : 329, + "key.offset" : 324, + "key.parsed_declaration" : "func extendedF(index: ExtendedIndex)", + "key.parsed_scope.end" : 23, + "key.parsed_scope.start" : 22, + "key.receivers" : [ + { + "key.usr" : "s:9Extension4BaseC" + } + ], + "key.reusingastcontext" : false, + "key.substructure" : [ + + ], + "key.typename" : "(Base) -> (Double) -> ()", + "key.typeusr" : "$s5indexySd_tcD", + "key.usr" : "s:9Extension4BaseC9extendedF5indexySd_tF" + } + ], + "key.typename" : "Base.Type", + "key.typeusr" : "$s9Extension4BaseCmD", + "key.usr" : "s:9Extension4BaseC" + }, + { + "key.annotated_decl" : "class Base<\/Type>.Nested<\/Declaration>", + "key.bodylength" : 1, + "key.bodyoffset" : 436, + "key.column" : 11, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Doc for Base.Nested", + "key.doc.column" : 11, + "key.doc.declaration" : "class Extension.Base.Nested", + "key.doc.file" : "Extension.swift", + "key.doc.full_as_xml" : "Nested<\/Name>s:9Extension4BaseC6NestedC<\/USR>class Extension.Base.Nested<\/Declaration>Doc for Base.Nested<\/Para><\/Abstract><\/CommentParts><\/Class>", + "key.doc.line" : 12, + "key.doc.name" : "Nested", + "key.doc.type" : "Class", + "key.filepath" : "Extension.swift", + "key.fully_annotated_decl" : "class<\/syntaxtype.keyword> Base<\/ref.class>.Nested<\/decl.name><\/decl.class>", + "key.is_dynamic" : true, + "key.kind" : "source.lang.swift.decl.extension", + "key.length" : 25, + "key.line" : 12, + "key.modulename" : "Extension", + "key.name" : "Base.Nested", + "key.namelength" : 11, + "key.nameoffset" : 423, + "key.offset" : 413, + "key.parsed_declaration" : "extension Base.Nested", + "key.parsed_scope.end" : 29, + "key.parsed_scope.start" : 28, + "key.receivers" : [ + { + "key.usr" : "s:9Extension4BaseC" + } + ], + "key.reusingastcontext" : false, + "key.typename" : "Base.Nested.Type", + "key.typeusr" : "$s9Extension4BaseC6NestedCmD", + "key.usr" : "s:9Extension4BaseC6NestedC" + }, + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "class 🐽<\/Declaration>", + "key.bodylength" : 25, + "key.bodyoffset" : 452, + "key.column" : 7, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "Extension.swift", + "key.fully_annotated_decl" : "class<\/syntaxtype.keyword> 🐽<\/decl.name><\/decl.class>", + "key.kind" : "source.lang.swift.decl.class", + "key.length" : 38, + "key.line" : 31, + "key.modulename" : "Extension", + "key.name" : "🐽", + "key.namelength" : 4, + "key.nameoffset" : 446, + "key.offset" : 440, + "key.parsed_declaration" : "class 🐽", + "key.parsed_scope.end" : 34, + "key.parsed_scope.start" : 31, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "struct 🐽<\/Type>.🐧<\/Declaration>", + "key.bodylength" : 5, + "key.bodyoffset" : 470, + "key.column" : 12, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "Extension.swift", + "key.fully_annotated_decl" : "struct<\/syntaxtype.keyword> 🐽<\/ref.class>.🐧<\/decl.name><\/decl.struct>", + "key.is_dynamic" : true, + "key.kind" : "source.lang.swift.decl.struct", + "key.length" : 19, + "key.line" : 32, + "key.modulename" : "Extension", + "key.name" : "🐧", + "key.namelength" : 4, + "key.nameoffset" : 464, + "key.offset" : 457, + "key.parsed_declaration" : "struct 🐧", + "key.parsed_scope.end" : 33, + "key.parsed_scope.start" : 32, + "key.receivers" : [ + { + "key.usr" : "s:9Extension004ipIhC" + } + ], + "key.reusingastcontext" : false, + "key.typename" : "🐽.🐧.Type", + "key.typeusr" : "$s9Extension004ipIhC004voIhVmD", + "key.usr" : "s:9Extension004ipIhC004voIhV" + } + ], + "key.typename" : "🐽.Type", + "key.typeusr" : "$s9Extension004ipIhCmD", + "key.usr" : "s:9Extension004ipIhC" + }, + { + "key.annotated_decl" : "struct 🐽<\/Type>.🐧<\/Declaration>", + "key.bodylength" : 1, + "key.bodyoffset" : 501, + "key.column" : 12, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "Extension.swift", + "key.fully_annotated_decl" : "struct<\/syntaxtype.keyword> 🐽<\/ref.class>.🐧<\/decl.name><\/decl.struct>", + "key.is_dynamic" : true, + "key.kind" : "source.lang.swift.decl.extension", + "key.length" : 23, + "key.line" : 32, + "key.modulename" : "Extension", + "key.name" : "🐽.🐧", + "key.namelength" : 9, + "key.nameoffset" : 490, + "key.offset" : 480, + "key.parsed_declaration" : "extension 🐽.🐧", + "key.parsed_scope.end" : 37, + "key.parsed_scope.start" : 36, + "key.receivers" : [ + { + "key.usr" : "s:9Extension004ipIhC" + } + ], + "key.reusingastcontext" : false, + "key.typename" : "🐽.🐧.Type", + "key.typeusr" : "$s9Extension004ipIhC004voIhVmD", + "key.usr" : "s:9Extension004ipIhC004voIhV" + } + ] + } +} \ No newline at end of file diff --git a/Tests/SourceKittenFrameworkTests/Fixtures/SimpleCodeCompletion@swift-6.0.json b/Tests/SourceKittenFrameworkTests/Fixtures/SimpleCodeCompletion@swift-6.0.json new file mode 100644 index 00000000..406df11e --- /dev/null +++ b/Tests/SourceKittenFrameworkTests/Fixtures/SimpleCodeCompletion@swift-6.0.json @@ -0,0 +1,861 @@ +[{ + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "self", + "kind" : "source.lang.swift.keyword", + "name" : "self", + "numBytesToErase" : 0, + "sourcetext" : "self", + "typeName" : "Int" +}, { + "associatedUSRs" : "s:Si23addingReportingOverflowySi12partialValue_Sb8overflowtSiF s:s17FixedWidthIntegerP23addingReportingOverflowyx12partialValue_Sb8overflowtxF", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "addingReportingOverflow(other: Int)", + "docBrief" : "Returns the sum of this value and the given value, along with a Boolean value indicating whether overflow occurred in the operation.", + "kind" : "source.lang.swift.decl.function.method.instance", + "moduleName" : "Swift", + "name" : "addingReportingOverflow(:)", + "numBytesToErase" : 0, + "sourcetext" : "addingReportingOverflow(<#T##other: Int##Int#>)", + "typeName" : "(partialValue: Int, overflow: Bool)" +}, { + "associatedUSRs" : "s:Si28subtractingReportingOverflowySi12partialValue_Sb8overflowtSiF s:s17FixedWidthIntegerP28subtractingReportingOverflowyx12partialValue_Sb8overflowtxF", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "subtractingReportingOverflow(other: Int)", + "docBrief" : "Returns the difference obtained by subtracting the given value from this value, along with a Boolean value indicating whether overflow occurred in the operation.", + "kind" : "source.lang.swift.decl.function.method.instance", + "moduleName" : "Swift", + "name" : "subtractingReportingOverflow(:)", + "numBytesToErase" : 0, + "sourcetext" : "subtractingReportingOverflow(<#T##other: Int##Int#>)", + "typeName" : "(partialValue: Int, overflow: Bool)" +}, { + "associatedUSRs" : "s:Si27multipliedReportingOverflow2bySi12partialValue_Sb8overflowtSi_tF s:s17FixedWidthIntegerP27multipliedReportingOverflow2byx12partialValue_Sb8overflowtx_tF", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "multipliedReportingOverflow(by: Int)", + "docBrief" : "Returns the product of this value and the given value, along with a Boolean value indicating whether overflow occurred in the operation.", + "kind" : "source.lang.swift.decl.function.method.instance", + "moduleName" : "Swift", + "name" : "multipliedReportingOverflow(by:)", + "numBytesToErase" : 0, + "sourcetext" : "multipliedReportingOverflow(by: <#T##Int#>)", + "typeName" : "(partialValue: Int, overflow: Bool)" +}, { + "associatedUSRs" : "s:Si24dividedReportingOverflow2bySi12partialValue_Sb8overflowtSi_tF s:s17FixedWidthIntegerP24dividedReportingOverflow2byx12partialValue_Sb8overflowtx_tF", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "dividedReportingOverflow(by: Int)", + "docBrief" : "Returns the quotient obtained by dividing this value by the given value, along with a Boolean value indicating whether overflow occurred in the operation.", + "kind" : "source.lang.swift.decl.function.method.instance", + "moduleName" : "Swift", + "name" : "dividedReportingOverflow(by:)", + "numBytesToErase" : 0, + "sourcetext" : "dividedReportingOverflow(by: <#T##Int#>)", + "typeName" : "(partialValue: Int, overflow: Bool)" +}, { + "associatedUSRs" : "s:Si26remainderReportingOverflow10dividingBySi12partialValue_Sb8overflowtSi_tF s:s17FixedWidthIntegerP26remainderReportingOverflow10dividingByx12partialValue_Sb8overflowtx_tF", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "remainderReportingOverflow(dividingBy: Int)", + "docBrief" : "Returns the remainder after dividing this value by the given value, along with a Boolean value indicating whether overflow occurred during division.", + "kind" : "source.lang.swift.decl.function.method.instance", + "moduleName" : "Swift", + "name" : "remainderReportingOverflow(dividingBy:)", + "numBytesToErase" : 0, + "sourcetext" : "remainderReportingOverflow(dividingBy: <#T##Int#>)", + "typeName" : "(partialValue: Int, overflow: Bool)" +}, { + "associatedUSRs" : "s:Si19leadingZeroBitCountSivp s:s17FixedWidthIntegerP19leadingZeroBitCountSivp", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "leadingZeroBitCount", + "docBrief" : "The number of leading zeros in this value’s binary representation.", + "kind" : "source.lang.swift.decl.var.instance", + "moduleName" : "Swift", + "name" : "leadingZeroBitCount", + "numBytesToErase" : 0, + "sourcetext" : "leadingZeroBitCount", + "typeName" : "Int" +}, { + "associatedUSRs" : "s:Si20trailingZeroBitCountSivp s:Sz20trailingZeroBitCountSivp", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "trailingZeroBitCount", + "docBrief" : "The number of trailing zeros in this value’s binary representation.", + "kind" : "source.lang.swift.decl.var.instance", + "moduleName" : "Swift", + "name" : "trailingZeroBitCount", + "numBytesToErase" : 0, + "sourcetext" : "trailingZeroBitCount", + "typeName" : "Int" +}, { + "associatedUSRs" : "s:Si15nonzeroBitCountSivp s:s17FixedWidthIntegerP15nonzeroBitCountSivp", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "nonzeroBitCount", + "docBrief" : "The number of bits equal to 1 in this value’s binary representation.", + "kind" : "source.lang.swift.decl.var.instance", + "moduleName" : "Swift", + "name" : "nonzeroBitCount", + "numBytesToErase" : 0, + "sourcetext" : "nonzeroBitCount", + "typeName" : "Int" +}, { + "associatedUSRs" : "s:Si5wordsSi5WordsVvp s:Sz5words5WordsQzvp", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "words", + "docBrief" : "A collection containing the words of this value’s binary representation, in order from the least significant to most significant.", + "kind" : "source.lang.swift.decl.var.instance", + "moduleName" : "Swift", + "name" : "words", + "numBytesToErase" : 0, + "sourcetext" : "words", + "typeName" : "Int.Words" +}, { + "associatedUSRs" : "s:Si9magnitudeSuvp s:Sj9magnitude9MagnitudeQzvp", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "magnitude", + "docBrief" : "The magnitude of this value.", + "kind" : "source.lang.swift.decl.var.instance", + "moduleName" : "Swift", + "name" : "magnitude", + "numBytesToErase" : 0, + "sourcetext" : "magnitude", + "typeName" : "UInt" +}, { + "associatedUSRs" : "s:Si19multipliedFullWidth2bySi4high_Su3lowtSi_tF s:s17FixedWidthIntegerP014multipliedFullB02byx4high_9MagnitudeQz3lowtx_tF", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "multipliedFullWidth(by: Int)", + "docBrief" : "Returns a tuple containing the high and low parts of the result of multiplying this value by the given value.", + "kind" : "source.lang.swift.decl.function.method.instance", + "moduleName" : "Swift", + "name" : "multipliedFullWidth(by:)", + "numBytesToErase" : 0, + "sourcetext" : "multipliedFullWidth(by: <#T##Int#>)", + "typeName" : "(high: Int, low: Int.Magnitude)" +}, { + "associatedUSRs" : "s:Si17dividingFullWidthySi8quotient_Si9remaindertSi4high_Su3lowt_tF s:s17FixedWidthIntegerP012dividingFullB0yx8quotient_x9remaindertx4high_9MagnitudeQz3lowt_tF", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "dividingFullWidth(dividend: (high: Int, low: Int.Magnitude))", + "docBrief" : "Returns a tuple containing the quotient and remainder of dividing the given value by this value.", + "kind" : "source.lang.swift.decl.function.method.instance", + "moduleName" : "Swift", + "name" : "dividingFullWidth(:)", + "numBytesToErase" : 0, + "sourcetext" : "dividingFullWidth(<#T##dividend: (high: Int, low: Int.Magnitude)##(high: Int, low: Int.Magnitude)#>)", + "typeName" : "(quotient: Int, remainder: Int)" +}, { + "associatedUSRs" : "s:Si11byteSwappedSivp s:s17FixedWidthIntegerP11byteSwappedxvp", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "byteSwapped", + "docBrief" : "A representation of this integer with the byte order swapped.", + "kind" : "source.lang.swift.decl.var.instance", + "moduleName" : "Swift", + "name" : "byteSwapped", + "numBytesToErase" : 0, + "sourcetext" : "byteSwapped", + "typeName" : "Int" +}, { + "associatedUSRs" : "s:Si6signumSiyF s:Sz6signumxyF", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "signum()", + "docBrief" : "Returns -1 if this value is negative and 1 if it’s positive; otherwise, 0.", + "kind" : "source.lang.swift.decl.function.method.instance", + "moduleName" : "Swift", + "name" : "signum()", + "numBytesToErase" : 0, + "sourcetext" : "signum()", + "typeName" : "Int" +}, { + "associatedUSRs" : "s:Si6encode2toys7Encoder_p_tKF s:SE6encode2toys7Encoder_p_tKF", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "encode(to: any Encoder) throws", + "docBrief" : "Encodes this value into the given encoder.", + "kind" : "source.lang.swift.decl.function.method.instance", + "moduleName" : "Swift", + "name" : "encode(to:)", + "numBytesToErase" : 0, + "sourcetext" : "encode(to: <#T##any Encoder#>)", + "typeName" : "Void" +}, { + "associatedUSRs" : "s:Si9codingKeys06CodingB0_pvp s:s22CodingKeyRepresentableP06codingB0s0aB0_pvp", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "codingKey", + "kind" : "source.lang.swift.decl.var.instance", + "moduleName" : "Swift", + "name" : "codingKey", + "numBytesToErase" : 0, + "sourcetext" : "codingKey", + "typeName" : "any CodingKey" +}, { + "associatedUSRs" : "s:Si12customMirrors0B0Vvp s:s17CustomReflectableP12customMirrors0D0Vvp", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "customMirror", + "docBrief" : "A mirror that reflects the Int instance.", + "kind" : "source.lang.swift.decl.var.instance", + "moduleName" : "Swift", + "name" : "customMirror", + "numBytesToErase" : 0, + "sourcetext" : "customMirror", + "typeName" : "Mirror" +}, { + "associatedUSRs" : "s:Si25customPlaygroundQuickLooks01_bcD0Ovp s:s30_CustomPlaygroundQuickLookableP06custombC4Looks01_bcF0Ovp", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "customPlaygroundQuickLook", + "docBrief" : "A custom playground Quick Look for the Int instance.", + "kind" : "source.lang.swift.decl.var.instance", + "moduleName" : "Swift", + "name" : "customPlaygroundQuickLook", + "numBytesToErase" : 0, + "sourcetext" : "customPlaygroundQuickLook", + "typeName" : "_PlaygroundQuickLook" +}, { + "associatedUSRs" : "s:Si4hash4intoys6HasherVz_tF s:SH4hash4intoys6HasherVz_tF", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "hash(into: &Hasher)", + "docBrief" : "Hashes the essential components of this value by feeding them into the given hasher.", + "kind" : "source.lang.swift.decl.function.method.instance", + "moduleName" : "Swift", + "name" : "hash(into:)", + "numBytesToErase" : 0, + "sourcetext" : "hash(into: &<#T##Hasher#>)", + "typeName" : "Void" +}, { + "associatedUSRs" : "s:Si9hashValueSivp s:SH9hashValueSivp", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "hashValue", + "docBrief" : "The hash value.", + "kind" : "source.lang.swift.decl.var.instance", + "moduleName" : "Swift", + "name" : "hashValue", + "numBytesToErase" : 0, + "sourcetext" : "hashValue", + "typeName" : "Int" +}, { + "associatedUSRs" : "s:Si8distance2toS2i_tF s:Sx8distance2to6StrideQzx_tF", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "distance(to: Int)", + "docBrief" : "Returns the distance from this value to the given value, expressed as a stride.", + "kind" : "source.lang.swift.decl.function.method.instance", + "moduleName" : "Swift", + "name" : "distance(to:)", + "numBytesToErase" : 0, + "sourcetext" : "distance(to: <#T##Int#>)", + "typeName" : "Int" +}, { + "associatedUSRs" : "s:Si8advanced2byS2i_tF s:Sx8advanced2byx6StrideQz_tF", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "advanced(by: Int)", + "docBrief" : "Returns a value that is offset the specified distance from this value.", + "kind" : "source.lang.swift.decl.function.method.instance", + "moduleName" : "Swift", + "name" : "advanced(by:)", + "numBytesToErase" : 0, + "sourcetext" : "advanced(by: <#T##Int#>)", + "typeName" : "Int" +}, { + "associatedUSRs" : "s:s17FixedWidthIntegerPsE03bitB0Sivp", + "context" : "source.codecompletion.context.superclass", + "descriptionKey" : "bitWidth", + "docBrief" : "The number of bits in the binary representation of this value.", + "kind" : "source.lang.swift.decl.var.instance", + "moduleName" : "Swift", + "name" : "bitWidth", + "numBytesToErase" : 0, + "sourcetext" : "bitWidth", + "typeName" : "Int" +}, { + "associatedUSRs" : "s:s17FixedWidthIntegerPsE12littleEndianxvp", + "context" : "source.codecompletion.context.superclass", + "descriptionKey" : "littleEndian", + "docBrief" : "The little-endian representation of this integer.", + "kind" : "source.lang.swift.decl.var.instance", + "moduleName" : "Swift", + "name" : "littleEndian", + "numBytesToErase" : 0, + "sourcetext" : "littleEndian", + "typeName" : "Int" +}, { + "associatedUSRs" : "s:s17FixedWidthIntegerPsE9bigEndianxvp", + "context" : "source.codecompletion.context.superclass", + "descriptionKey" : "bigEndian", + "docBrief" : "The big-endian representation of this integer.", + "kind" : "source.lang.swift.decl.var.instance", + "moduleName" : "Swift", + "name" : "bigEndian", + "numBytesToErase" : 0, + "sourcetext" : "bigEndian", + "typeName" : "Int" +}, { + "associatedUSRs" : "s:SZss17FixedWidthIntegerRzrlE10isMultiple2ofSbx_tF", + "context" : "source.codecompletion.context.superclass", + "descriptionKey" : "isMultiple(of: Int)", + "docBrief" : "Returns true if this value is a multiple of the given value, and false otherwise.", + "kind" : "source.lang.swift.decl.function.method.instance", + "moduleName" : "Swift", + "name" : "isMultiple(of:)", + "numBytesToErase" : 0, + "sourcetext" : "isMultiple(of: <#T##Int#>)", + "typeName" : "Bool" +}, { + "associatedUSRs" : "s:SzsE20quotientAndRemainder10dividingByx0A0_x9remaindertx_tF", + "context" : "source.codecompletion.context.superclass", + "descriptionKey" : "quotientAndRemainder(dividingBy: Int)", + "docBrief" : "Returns the quotient and remainder of this value divided by the given value.", + "kind" : "source.lang.swift.decl.function.method.instance", + "moduleName" : "Swift", + "name" : "quotientAndRemainder(dividingBy:)", + "numBytesToErase" : 0, + "sourcetext" : "quotientAndRemainder(dividingBy: <#T##Int#>)", + "typeName" : "(quotient: Int, remainder: Int)" +}, { + "associatedUSRs" : "s:SzsE11descriptionSSvp", + "context" : "source.codecompletion.context.superclass", + "descriptionKey" : "description", + "docBrief" : "A textual representation of this value.", + "kind" : "source.lang.swift.decl.var.instance", + "moduleName" : "Swift", + "name" : "description", + "numBytesToErase" : 0, + "sourcetext" : "description", + "typeName" : "String" +}, { + "associatedUSRs" : "s:s13SignedNumericPsE6negateyyF", + "context" : "source.codecompletion.context.superclass", + "descriptionKey" : "negate()", + "docBrief" : "Replaces this value with its additive inverse.", + "kind" : "source.lang.swift.decl.function.method.instance", + "moduleName" : "Swift", + "name" : "negate()", + "numBytesToErase" : 0, + "sourcetext" : "negate()", + "typeName" : "Void" +}, { + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "self", + "kind" : "source.lang.swift.keyword", + "name" : "self", + "numBytesToErase" : 0, + "sourcetext" : "self", + "typeName" : "Double" +}, { + "associatedUSRs" : "s:Sd6encode2toys7Encoder_p_tKF s:SE6encode2toys7Encoder_p_tKF", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "encode(to: any Encoder) throws", + "docBrief" : "Encodes this value into the given encoder.", + "kind" : "source.lang.swift.decl.function.method.instance", + "moduleName" : "Swift", + "name" : "encode(to:)", + "numBytesToErase" : 0, + "sourcetext" : "encode(to: <#T##any Encoder#>)", + "typeName" : "Void" +}, { + "associatedUSRs" : "s:Sd12customMirrors0B0Vvp s:s17CustomReflectableP12customMirrors0D0Vvp", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "customMirror", + "docBrief" : "A mirror that reflects the Double instance.", + "kind" : "source.lang.swift.decl.var.instance", + "moduleName" : "Swift", + "name" : "customMirror", + "numBytesToErase" : 0, + "sourcetext" : "customMirror", + "typeName" : "Mirror" +}, { + "associatedUSRs" : "s:Sd25customPlaygroundQuickLooks01_bcD0Ovp s:s30_CustomPlaygroundQuickLookableP06custombC4Looks01_bcF0Ovp", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "customPlaygroundQuickLook", + "docBrief" : "A custom playground Quick Look for the Double instance.", + "kind" : "source.lang.swift.decl.var.instance", + "moduleName" : "Swift", + "name" : "customPlaygroundQuickLook", + "numBytesToErase" : 0, + "sourcetext" : "customPlaygroundQuickLook", + "typeName" : "_PlaygroundQuickLook" +}, { + "associatedUSRs" : "s:Sd11descriptionSSvp s:s23CustomStringConvertibleP11descriptionSSvp", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "description", + "docBrief" : "A textual representation of the value.", + "kind" : "source.lang.swift.decl.var.instance", + "moduleName" : "Swift", + "name" : "description", + "numBytesToErase" : 0, + "sourcetext" : "description", + "typeName" : "String" +}, { + "associatedUSRs" : "s:Sd16debugDescriptionSSvp s:s28CustomDebugStringConvertibleP16debugDescriptionSSvp", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "debugDescription", + "docBrief" : "A textual representation of the value, suitable for debugging.", + "kind" : "source.lang.swift.decl.var.instance", + "moduleName" : "Swift", + "name" : "debugDescription", + "numBytesToErase" : 0, + "sourcetext" : "debugDescription", + "typeName" : "String" +}, { + "associatedUSRs" : "s:Sd5write2toyxz_ts16TextOutputStreamRzlF s:s20TextOutputStreamableP5write2toyqd__z_ts0aB6StreamRd__lF", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "write(to: &TextOutputStream)", + "docBrief" : "Writes a textual representation of this instance into the given output stream.", + "kind" : "source.lang.swift.decl.function.method.instance", + "moduleName" : "Swift", + "name" : "write(to:)", + "numBytesToErase" : 0, + "sourcetext" : "write(to: &<#T##TextOutputStream#>)", + "typeName" : "Void" +}, { + "associatedUSRs" : "s:Sd10bitPatterns6UInt64Vvp", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "bitPattern", + "docBrief" : "The bit pattern of the value’s encoding.", + "kind" : "source.lang.swift.decl.var.instance", + "moduleName" : "Swift", + "name" : "bitPattern", + "numBytesToErase" : 0, + "sourcetext" : "bitPattern", + "typeName" : "UInt64" +}, { + "associatedUSRs" : "s:Sd4signs17FloatingPointSignOvp s:SF4signs17FloatingPointSignOvp", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "sign", + "docBrief" : "The sign of the floating-point value.", + "kind" : "source.lang.swift.decl.var.instance", + "moduleName" : "Swift", + "name" : "sign", + "numBytesToErase" : 0, + "sourcetext" : "sign", + "typeName" : "FloatingPointSign" +}, { + "associatedUSRs" : "s:Sd18exponentBitPatternSuvp s:SB18exponentBitPattern11RawExponentQzvp", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "exponentBitPattern", + "docBrief" : "The raw encoding of the value’s exponent field.", + "kind" : "source.lang.swift.decl.var.instance", + "moduleName" : "Swift", + "name" : "exponentBitPattern", + "numBytesToErase" : 0, + "sourcetext" : "exponentBitPattern", + "typeName" : "UInt" +}, { + "associatedUSRs" : "s:Sd21significandBitPatterns6UInt64Vvp s:SB21significandBitPattern14RawSignificandQzvp", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "significandBitPattern", + "docBrief" : "The raw encoding of the value’s significand field.", + "kind" : "source.lang.swift.decl.var.instance", + "moduleName" : "Swift", + "name" : "significandBitPattern", + "numBytesToErase" : 0, + "sourcetext" : "significandBitPattern", + "typeName" : "UInt64" +}, { + "associatedUSRs" : "s:Sd11isCanonicalSbvp s:SF11isCanonicalSbvp", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "isCanonical", + "docBrief" : "A Boolean value indicating whether the instance’s representation is in its canonical form.", + "kind" : "source.lang.swift.decl.var.instance", + "moduleName" : "Swift", + "name" : "isCanonical", + "numBytesToErase" : 0, + "sourcetext" : "isCanonical", + "typeName" : "Bool" +}, { + "associatedUSRs" : "s:Sd3ulpSdvp s:SF3ulpxvp", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "ulp", + "docBrief" : "The unit in the last place of this value.", + "kind" : "source.lang.swift.decl.var.instance", + "moduleName" : "Swift", + "name" : "ulp", + "numBytesToErase" : 0, + "sourcetext" : "ulp", + "typeName" : "Double" +}, { + "associatedUSRs" : "s:Sd8exponentSivp s:SF8exponent8ExponentQzvp", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "exponent", + "docBrief" : "The exponent of the floating-point value.", + "kind" : "source.lang.swift.decl.var.instance", + "moduleName" : "Swift", + "name" : "exponent", + "numBytesToErase" : 0, + "sourcetext" : "exponent", + "typeName" : "Int" +}, { + "associatedUSRs" : "s:Sd11significandSdvp s:SF11significandxvp", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "significand", + "docBrief" : "The significand of the floating-point value.", + "kind" : "source.lang.swift.decl.var.instance", + "moduleName" : "Swift", + "name" : "significand", + "numBytesToErase" : 0, + "sourcetext" : "significand", + "typeName" : "Double" +}, { + "associatedUSRs" : "s:Sd6nextUpSdvp s:SF6nextUpxvp", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "nextUp", + "docBrief" : "The least representable value that compares greater than this value.", + "kind" : "source.lang.swift.decl.var.instance", + "moduleName" : "Swift", + "name" : "nextUp", + "numBytesToErase" : 0, + "sourcetext" : "nextUp", + "typeName" : "Double" +}, { + "associatedUSRs" : "s:Sd5roundyys25FloatingPointRoundingRuleOF s:SF5roundyys25FloatingPointRoundingRuleOF", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "round(rule: FloatingPointRoundingRule)", + "docBrief" : "Rounds the value to an integral value using the specified rounding rule.", + "kind" : "source.lang.swift.decl.function.method.instance", + "moduleName" : "Swift", + "name" : "round(:)", + "numBytesToErase" : 0, + "sourcetext" : "round(<#T##rule: FloatingPointRoundingRule##FloatingPointRoundingRule#>)", + "typeName" : "Void" +}, { + "associatedUSRs" : "s:Sd6negateyyF s:SF6negateyyF s:s13SignedNumericP6negateyyF", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "negate()", + "docBrief" : "Replaces this value with its additive inverse.", + "kind" : "source.lang.swift.decl.function.method.instance", + "moduleName" : "Swift", + "name" : "negate()", + "numBytesToErase" : 0, + "sourcetext" : "negate()", + "typeName" : "Void" +}, { + "associatedUSRs" : "s:Sd13formRemainder10dividingByySd_tF s:SF13formRemainder10dividingByyx_tF", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "formRemainder(dividingBy: Double)", + "docBrief" : "Replaces this value with the remainder of itself divided by the given value.", + "kind" : "source.lang.swift.decl.function.method.instance", + "moduleName" : "Swift", + "name" : "formRemainder(dividingBy:)", + "numBytesToErase" : 0, + "sourcetext" : "formRemainder(dividingBy: <#T##Double#>)", + "typeName" : "Void" +}, { + "associatedUSRs" : "s:Sd23formTruncatingRemainder10dividingByySd_tF s:SF23formTruncatingRemainder10dividingByyx_tF", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "formTruncatingRemainder(dividingBy: Double)", + "docBrief" : "Replaces this value with the remainder of itself divided by the given value using truncating division.", + "kind" : "source.lang.swift.decl.function.method.instance", + "moduleName" : "Swift", + "name" : "formTruncatingRemainder(dividingBy:)", + "numBytesToErase" : 0, + "sourcetext" : "formTruncatingRemainder(dividingBy: <#T##Double#>)", + "typeName" : "Void" +}, { + "associatedUSRs" : "s:Sd14formSquareRootyyF s:SF14formSquareRootyyF", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "formSquareRoot()", + "docBrief" : "Replaces this value with its square root, rounded to a representable value.", + "kind" : "source.lang.swift.decl.function.method.instance", + "moduleName" : "Swift", + "name" : "formSquareRoot()", + "numBytesToErase" : 0, + "sourcetext" : "formSquareRoot()", + "typeName" : "Void" +}, { + "associatedUSRs" : "s:Sd10addProductyySd_SdtF s:SF10addProductyyx_xtF", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "addProduct(lhs: Double, rhs: Double)", + "docBrief" : "Adds the product of the two given values to this value in place, computed without intermediate rounding.", + "kind" : "source.lang.swift.decl.function.method.instance", + "moduleName" : "Swift", + "name" : "addProduct(::)", + "numBytesToErase" : 0, + "sourcetext" : "addProduct(<#T##lhs: Double##Double#>, <#T##rhs: Double##Double#>)", + "typeName" : "Void" +}, { + "associatedUSRs" : "s:Sd7isEqual2toSbSd_tF s:SF7isEqual2toSbx_tF", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "isEqual(to: Double)", + "docBrief" : "Returns a Boolean value indicating whether this instance is equal to the given value.", + "kind" : "source.lang.swift.decl.function.method.instance", + "moduleName" : "Swift", + "name" : "isEqual(to:)", + "numBytesToErase" : 0, + "sourcetext" : "isEqual(to: <#T##Double#>)", + "typeName" : "Bool" +}, { + "associatedUSRs" : "s:Sd6isLess4thanSbSd_tF s:SF6isLess4thanSbx_tF", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "isLess(than: Double)", + "docBrief" : "Returns a Boolean value indicating whether this instance is less than the given value.", + "kind" : "source.lang.swift.decl.function.method.instance", + "moduleName" : "Swift", + "name" : "isLess(than:)", + "numBytesToErase" : 0, + "sourcetext" : "isLess(than: <#T##Double#>)", + "typeName" : "Bool" +}, { + "associatedUSRs" : "s:Sd19isLessThanOrEqualToySbSdF s:SF19isLessThanOrEqualToySbxF", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "isLessThanOrEqualTo(other: Double)", + "docBrief" : "Returns a Boolean value indicating whether this instance is less than or equal to the given value.", + "kind" : "source.lang.swift.decl.function.method.instance", + "moduleName" : "Swift", + "name" : "isLessThanOrEqualTo(:)", + "numBytesToErase" : 0, + "sourcetext" : "isLessThanOrEqualTo(<#T##other: Double##Double#>)", + "typeName" : "Bool" +}, { + "associatedUSRs" : "s:Sd8isNormalSbvp s:SF8isNormalSbvp", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "isNormal", + "docBrief" : "A Boolean value indicating whether this instance is normal.", + "kind" : "source.lang.swift.decl.var.instance", + "moduleName" : "Swift", + "name" : "isNormal", + "numBytesToErase" : 0, + "sourcetext" : "isNormal", + "typeName" : "Bool" +}, { + "associatedUSRs" : "s:Sd8isFiniteSbvp s:SF8isFiniteSbvp", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "isFinite", + "docBrief" : "A Boolean value indicating whether this instance is finite.", + "kind" : "source.lang.swift.decl.var.instance", + "moduleName" : "Swift", + "name" : "isFinite", + "numBytesToErase" : 0, + "sourcetext" : "isFinite", + "typeName" : "Bool" +}, { + "associatedUSRs" : "s:Sd6isZeroSbvp s:SF6isZeroSbvp", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "isZero", + "docBrief" : "A Boolean value indicating whether the instance is equal to zero.", + "kind" : "source.lang.swift.decl.var.instance", + "moduleName" : "Swift", + "name" : "isZero", + "numBytesToErase" : 0, + "sourcetext" : "isZero", + "typeName" : "Bool" +}, { + "associatedUSRs" : "s:Sd11isSubnormalSbvp s:SF11isSubnormalSbvp", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "isSubnormal", + "docBrief" : "A Boolean value indicating whether the instance is subnormal.", + "kind" : "source.lang.swift.decl.var.instance", + "moduleName" : "Swift", + "name" : "isSubnormal", + "numBytesToErase" : 0, + "sourcetext" : "isSubnormal", + "typeName" : "Bool" +}, { + "associatedUSRs" : "s:Sd10isInfiniteSbvp s:SF10isInfiniteSbvp", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "isInfinite", + "docBrief" : "A Boolean value indicating whether the instance is infinite.", + "kind" : "source.lang.swift.decl.var.instance", + "moduleName" : "Swift", + "name" : "isInfinite", + "numBytesToErase" : 0, + "sourcetext" : "isInfinite", + "typeName" : "Bool" +}, { + "associatedUSRs" : "s:Sd5isNaNSbvp s:SF5isNaNSbvp", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "isNaN", + "docBrief" : "A Boolean value indicating whether the instance is NaN (“not a number”).", + "kind" : "source.lang.swift.decl.var.instance", + "moduleName" : "Swift", + "name" : "isNaN", + "numBytesToErase" : 0, + "sourcetext" : "isNaN", + "typeName" : "Bool" +}, { + "associatedUSRs" : "s:Sd14isSignalingNaNSbvp s:SF14isSignalingNaNSbvp", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "isSignalingNaN", + "docBrief" : "A Boolean value indicating whether the instance is a signaling NaN.", + "kind" : "source.lang.swift.decl.var.instance", + "moduleName" : "Swift", + "name" : "isSignalingNaN", + "numBytesToErase" : 0, + "sourcetext" : "isSignalingNaN", + "typeName" : "Bool" +}, { + "associatedUSRs" : "s:Sd6binadeSdvp s:SB6binadexvp", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "binade", + "docBrief" : "The floating-point value with the same sign and exponent as this value, but with a significand of 1.0.", + "kind" : "source.lang.swift.decl.var.instance", + "moduleName" : "Swift", + "name" : "binade", + "numBytesToErase" : 0, + "sourcetext" : "binade", + "typeName" : "Double" +}, { + "associatedUSRs" : "s:Sd16significandWidthSivp s:SB16significandWidthSivp", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "significandWidth", + "docBrief" : "The number of bits required to represent the value’s significand.", + "kind" : "source.lang.swift.decl.var.instance", + "moduleName" : "Swift", + "name" : "significandWidth", + "numBytesToErase" : 0, + "sourcetext" : "significandWidth", + "typeName" : "Int" +}, { + "associatedUSRs" : "s:Sd4hash4intoys6HasherVz_tF s:SH4hash4intoys6HasherVz_tF", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "hash(into: &Hasher)", + "docBrief" : "Hashes the essential components of this value by feeding them into the given hasher.", + "kind" : "source.lang.swift.decl.function.method.instance", + "moduleName" : "Swift", + "name" : "hash(into:)", + "numBytesToErase" : 0, + "sourcetext" : "hash(into: &<#T##Hasher#>)", + "typeName" : "Void" +}, { + "associatedUSRs" : "s:Sd9hashValueSivp s:SH9hashValueSivp", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "hashValue", + "docBrief" : "The hash value.", + "kind" : "source.lang.swift.decl.var.instance", + "moduleName" : "Swift", + "name" : "hashValue", + "numBytesToErase" : 0, + "sourcetext" : "hashValue", + "typeName" : "Int" +}, { + "associatedUSRs" : "s:Sd9magnitudeSdvp s:Sj9magnitude9MagnitudeQzvp", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "magnitude", + "docBrief" : "The magnitude of this value.", + "kind" : "source.lang.swift.decl.var.instance", + "moduleName" : "Swift", + "name" : "magnitude", + "numBytesToErase" : 0, + "sourcetext" : "magnitude", + "typeName" : "Double" +}, { + "associatedUSRs" : "s:Sd8distance2toS2d_tF s:Sx8distance2to6StrideQzx_tF", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "distance(to: Double)", + "docBrief" : "Returns the distance from this value to the given value, expressed as a stride.", + "kind" : "source.lang.swift.decl.function.method.instance", + "moduleName" : "Swift", + "name" : "distance(to:)", + "numBytesToErase" : 0, + "sourcetext" : "distance(to: <#T##Double#>)", + "typeName" : "Double" +}, { + "associatedUSRs" : "s:Sd8advanced2byS2d_tF s:Sx8advanced2byx6StrideQz_tF", + "context" : "source.codecompletion.context.thisclass", + "descriptionKey" : "advanced(by: Double)", + "docBrief" : "Returns a value that is offset the specified distance from this value.", + "kind" : "source.lang.swift.decl.function.method.instance", + "moduleName" : "Swift", + "name" : "advanced(by:)", + "numBytesToErase" : 0, + "sourcetext" : "advanced(by: <#T##Double#>)", + "typeName" : "Double" +}, { + "associatedUSRs" : "s:SBsE16isTotallyOrdered14belowOrEqualToSbx_tF", + "context" : "source.codecompletion.context.superclass", + "descriptionKey" : "isTotallyOrdered(belowOrEqualTo: Double)", + "docBrief" : "Returns a Boolean value indicating whether this instance should precede or tie positions with the given value in an ascending sort.", + "kind" : "source.lang.swift.decl.function.method.instance", + "moduleName" : "Swift", + "name" : "isTotallyOrdered(belowOrEqualTo:)", + "numBytesToErase" : 0, + "sourcetext" : "isTotallyOrdered(belowOrEqualTo: <#T##Double#>)", + "typeName" : "Bool" +}, { + "associatedUSRs" : "s:SFsE7roundedyxs25FloatingPointRoundingRuleOF", + "context" : "source.codecompletion.context.superclass", + "descriptionKey" : "rounded(rule: FloatingPointRoundingRule)", + "docBrief" : "Returns this value rounded to an integral value using the specified rounding rule.", + "kind" : "source.lang.swift.decl.function.method.instance", + "moduleName" : "Swift", + "name" : "rounded(:)", + "numBytesToErase" : 0, + "sourcetext" : "rounded(<#T##rule: FloatingPointRoundingRule##FloatingPointRoundingRule#>)", + "typeName" : "Double" +}, { + "associatedUSRs" : "s:SFsE7roundedxyF", + "context" : "source.codecompletion.context.superclass", + "descriptionKey" : "rounded()", + "kind" : "source.lang.swift.decl.function.method.instance", + "moduleName" : "Swift", + "name" : "rounded()", + "numBytesToErase" : 0, + "sourcetext" : "rounded()", + "typeName" : "Double" +}, { + "associatedUSRs" : "s:SFsE5roundyyF", + "context" : "source.codecompletion.context.superclass", + "descriptionKey" : "round()", + "kind" : "source.lang.swift.decl.function.method.instance", + "moduleName" : "Swift", + "name" : "round()", + "numBytesToErase" : 0, + "sourcetext" : "round()", + "typeName" : "Void" +}, { + "associatedUSRs" : "s:SFsE8nextDownxvp", + "context" : "source.codecompletion.context.superclass", + "descriptionKey" : "nextDown", + "docBrief" : "The greatest representable value that compares less than this value.", + "kind" : "source.lang.swift.decl.var.instance", + "moduleName" : "Swift", + "name" : "nextDown", + "numBytesToErase" : 0, + "sourcetext" : "nextDown", + "typeName" : "Double" +}, { + "associatedUSRs" : "s:SFsE19truncatingRemainder10dividingByxx_tF", + "context" : "source.codecompletion.context.superclass", + "descriptionKey" : "truncatingRemainder(dividingBy: Double)", + "docBrief" : "Returns the remainder of this value divided by the given value using truncating division.", + "kind" : "source.lang.swift.decl.function.method.instance", + "moduleName" : "Swift", + "name" : "truncatingRemainder(dividingBy:)", + "numBytesToErase" : 0, + "sourcetext" : "truncatingRemainder(dividingBy: <#T##Double#>)", + "typeName" : "Double" +}, { + "associatedUSRs" : "s:SFsE9remainder10dividingByxx_tF", + "context" : "source.codecompletion.context.superclass", + "descriptionKey" : "remainder(dividingBy: Double)", + "docBrief" : "Returns the remainder of this value divided by the given value.", + "kind" : "source.lang.swift.decl.function.method.instance", + "moduleName" : "Swift", + "name" : "remainder(dividingBy:)", + "numBytesToErase" : 0, + "sourcetext" : "remainder(dividingBy: <#T##Double#>)", + "typeName" : "Double" +}, { + "associatedUSRs" : "s:SFsE10squareRootxyF", + "context" : "source.codecompletion.context.superclass", + "descriptionKey" : "squareRoot()", + "docBrief" : "Returns the square root of the value, rounded to a representable value.", + "kind" : "source.lang.swift.decl.function.method.instance", + "moduleName" : "Swift", + "name" : "squareRoot()", + "numBytesToErase" : 0, + "sourcetext" : "squareRoot()", + "typeName" : "Double" +}, { + "associatedUSRs" : "s:SFsE13addingProductyxx_xtF", + "context" : "source.codecompletion.context.superclass", + "descriptionKey" : "addingProduct(lhs: Double, rhs: Double)", + "docBrief" : "Returns the result of adding the product of the two given values to this value, computed without intermediate rounding.", + "kind" : "source.lang.swift.decl.function.method.instance", + "moduleName" : "Swift", + "name" : "addingProduct(::)", + "numBytesToErase" : 0, + "sourcetext" : "addingProduct(<#T##lhs: Double##Double#>, <#T##rhs: Double##Double#>)", + "typeName" : "Double" +}, { + "associatedUSRs" : "s:SFsE18floatingPointClasss08FloatingB14ClassificationOvp", + "context" : "source.codecompletion.context.superclass", + "descriptionKey" : "floatingPointClass", + "docBrief" : "The classification of this value.", + "kind" : "source.lang.swift.decl.var.instance", + "moduleName" : "Swift", + "name" : "floatingPointClass", + "numBytesToErase" : 0, + "sourcetext" : "floatingPointClass", + "typeName" : "FloatingPointClassification" +}] \ No newline at end of file diff --git a/Tests/SourceKittenFrameworkTests/Fixtures/Subscript@swift-6.0.json b/Tests/SourceKittenFrameworkTests/Fixtures/Subscript@swift-6.0.json new file mode 100644 index 00000000..6ed6a7c1 --- /dev/null +++ b/Tests/SourceKittenFrameworkTests/Fixtures/Subscript@swift-6.0.json @@ -0,0 +1,76 @@ +{ + "Subscript.swift" : { + "key.diagnostic_stage" : "source.diagnostic.stage.swift.parse", + "key.length" : 134, + "key.offset" : 0, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "struct VoidStruct<\/Declaration>", + "key.bodylength" : 113, + "key.bodyoffset" : 19, + "key.column" : 8, + "key.decl_lang" : "source.lang.swift", + "key.filepath" : "Subscript.swift", + "key.fully_annotated_decl" : "struct<\/syntaxtype.keyword> VoidStruct<\/decl.name><\/decl.struct>", + "key.kind" : "source.lang.swift.decl.struct", + "key.length" : 133, + "key.line" : 1, + "key.modulename" : "Subscript", + "key.name" : "VoidStruct", + "key.namelength" : 10, + "key.nameoffset" : 7, + "key.offset" : 0, + "key.parsed_declaration" : "struct VoidStruct", + "key.parsed_scope.end" : 7, + "key.parsed_scope.start" : 1, + "key.reusingastcontext" : false, + "key.substructure" : [ + { + "key.accessibility" : "source.lang.swift.accessibility.internal", + "key.annotated_decl" : "subscript(key: String<\/Type>) -> () { get set }<\/Declaration>", + "key.bodylength" : 46, + "key.bodyoffset" : 84, + "key.column" : 5, + "key.decl_lang" : "source.lang.swift", + "key.doc_comment" : "Returns or sets Void.", + "key.doc.column" : 5, + "key.doc.comment" : "Returns or sets Void.", + "key.doc.declaration" : "subscript(key: String) -> () { get set }", + "key.doc.file" : "Subscript.swift", + "key.doc.full_as_xml" : "subscript(_:)<\/Name>s:9Subscript10VoidStructVyySScip<\/USR>subscript(key: String) -> () { get set }<\/Declaration>Returns or sets Void.<\/Para><\/Abstract><\/CommentParts><\/Other>", + "key.doc.line" : 3, + "key.doc.name" : "subscript(_:)", + "key.doc.type" : "Other", + "key.doclength" : 26, + "key.docoffset" : 24, + "key.filepath" : "Subscript.swift", + "key.fully_annotated_decl" : "subscript<\/syntaxtype.keyword>(key<\/decl.var.parameter.name>: String<\/ref.struct><\/decl.var.parameter.type><\/decl.var.parameter>) -> ()<\/tuple><\/decl.function.returntype> { get<\/syntaxtype.keyword> set<\/syntaxtype.keyword> }<\/decl.function.subscript>", + "key.kind" : "source.lang.swift.decl.function.subscript", + "key.length" : 77, + "key.line" : 3, + "key.modulename" : "Subscript", + "key.name" : "subscript(_:)", + "key.namelength" : 22, + "key.nameoffset" : 54, + "key.offset" : 54, + "key.parsed_declaration" : "subscript(key: String) -> ()", + "key.parsed_scope.end" : 6, + "key.parsed_scope.start" : 3, + "key.reusingastcontext" : false, + "key.setter_accessibility" : "source.lang.swift.accessibility.internal", + "key.substructure" : [ + + ], + "key.typename" : "(String) -> ()", + "key.typeusr" : "$syySScD", + "key.usr" : "s:9Subscript10VoidStructVyySScip" + } + ], + "key.typename" : "VoidStruct.Type", + "key.typeusr" : "$s9Subscript10VoidStructVmD", + "key.usr" : "s:9Subscript10VoidStructV" + } + ] + } +} \ No newline at end of file diff --git a/Tests/SourceKittenFrameworkTests/LibraryWrapperGeneratorTests.swift b/Tests/SourceKittenFrameworkTests/LibraryWrapperGeneratorTests.swift index cbcc0afb..6ce2b60e 100644 --- a/Tests/SourceKittenFrameworkTests/LibraryWrapperGeneratorTests.swift +++ b/Tests/SourceKittenFrameworkTests/LibraryWrapperGeneratorTests.swift @@ -6,10 +6,7 @@ final class LibraryWrapperGeneratorTests: XCTestCase { func testLibraryWrappersAreUpToDate() throws { let sourceKittenFrameworkModule = Module(xcodeBuildArguments: sourcekittenXcodebuildArguments, name: "SourceKittenFramework", inPath: projectRoot)! - let docsJSON = sourceKittenFrameworkModule.docs.description - XCTAssert(docsJSON.range(of: "error type") == nil) - let jsonArray = try JSONSerialization.jsonObject(with: docsJSON.data(using: .utf8)!, options: []) as? NSArray - XCTAssertNotNil(jsonArray, "JSON should be properly parsed") + XCTAssert(try noTypeErrors(in: sourceKittenFrameworkModule.docs.description)) for wrapperConfig in LibraryWrapperGenerator.allCases { let wrapperURL = URL(fileURLWithPath: "\(projectRoot)/\(wrapperConfig.filePath)") let existingWrapper = try String(contentsOf: wrapperURL) @@ -21,5 +18,26 @@ final class LibraryWrapperGeneratorTests: XCTestCase { } } } + + private func noTypeErrors(in json: String) throws -> Bool { + let errorType = "<>" + let errorTypeRegex = try NSRegularExpression(pattern: errorType, options: []) + XCTAssertLessThanOrEqual( + errorTypeRegex.matches(in: json, range: NSRange(json.startIndex..=6.0) + // removed in Swift 6.0 + expected.subtract([.isolated, ._objcImplementation]) +#else + // added in Swift 6.0 + expected.subtract([._extern, ._resultDependsOnSelf, ._preInverseGenerics, .implementation, + ._allowFeatureSuppression, ._noRuntime, ._staticExclusiveOnly, .extractConstantsFromMembers, + ._unsafeNonescapableResult, ._noExistentials, ._noObjCBridging, ._nonescapable]) +#endif #if compiler(>=5.10) // removed in Swift 5.10 expected.subtract([.accesses, .runtimeMetadata, .initializes]) diff --git a/Tests/SourceKittenFrameworkTests/SwiftDocsTests.swift b/Tests/SourceKittenFrameworkTests/SwiftDocsTests.swift index 76b47f55..5899c5f2 100644 --- a/Tests/SourceKittenFrameworkTests/SwiftDocsTests.swift +++ b/Tests/SourceKittenFrameworkTests/SwiftDocsTests.swift @@ -69,7 +69,10 @@ private func compareDocs(withFixtureNamed name: String, file: StaticString = #fi } private func versionedExpectedFilename(for name: String) -> String { -#if compiler(>=5.10) +#if compiler(>=6) + let versions = ["swift-6.0", "swift-5.10", "swift-5.9", "swift-5.8", "swift-5.6", "swift-5.5.2", "swift-5.5", "swift-5.4", "swift-5.3.1", "swift-5.3", + "swift-5.2", "swift-5.1", "swift-5.0"] +#elseif compiler(>=5.10) let versions = ["swift-5.10", "swift-5.9", "swift-5.8", "swift-5.6", "swift-5.5.2", "swift-5.5", "swift-5.4", "swift-5.3.1", "swift-5.3", "swift-5.2", "swift-5.1", "swift-5.0"] #elseif compiler(>=5.9)