Skip to content

Instantly share code, notes, and snippets.

@pcantrell
Created September 14, 2015 04:29
Show Gist options
  • Save pcantrell/3ea68cf9268cf28600f6 to your computer and use it in GitHub Desktop.
Save pcantrell/3ea68cf9268cf28600f6 to your computer and use it in GitHub Desktop.
[{
"\/tmp\/KittenTest\/KittenTest\/KittenTest.swift" : {
"key.substructure" : [
{
"key.kind" : "source.lang.swift.decl.class",
"key.offset" : 194,
"key.doc.comment" : "Foo class comment",
"key.namelength" : 3,
"key.doc.line" : 12,
"key.bodylength" : 51,
"key.length" : 3,
"key.doc.column" : 14,
"key.usr" : "s:C10KittenTest3Foo",
"key.doc.file" : "\/private\/tmp\/KittenTest\/KittenTest\/KittenTest.swift",
"key.nameoffset" : 194,
"key.annotated_decl" : "<Declaration>public class Foo<\/Declaration>",
"key.accessibility" : "source.lang.swift.accessibility.public",
"key.runtime_name" : "_TtC8__main__3Foo",
"key.filepath" : "\/private\/tmp\/KittenTest\/KittenTest\/KittenTest.swift",
"key.bodyoffset" : 199,
"key.doc.declaration" : "public class Foo",
"key.name" : "Foo",
"key.typename" : "Foo.Type",
"key.doc.type" : "Class",
"key.attributes" : [
{
"key.attribute" : "source.decl.attribute.__raw_doc_comment"
}
],
"key.doc.full_as_xml" : "<Class file=\"\/private\/tmp\/KittenTest\/KittenTest\/KittenTest.swift\" line=\"12\" column=\"14\"><Name>Foo<\/Name><USR>s:C10KittenTest3Foo<\/USR><Declaration>public class Foo<\/Declaration><Abstract><Para>Foo class comment<\/Para><\/Abstract><\/Class>",
"key.doc.name" : "Foo",
"key.substructure" : [
{
"key.kind" : "source.lang.swift.decl.function.method.instance",
"key.offset" : 236,
"key.doc.comment" : "bar comment",
"key.namelength" : 5,
"key.bodyoffset" : 243,
"key.bodylength" : 5,
"key.length" : 5,
"key.doc.line" : 14,
"key.name" : "bar()",
"key.typename" : "Foo -> () -> ()",
"key.doc.declaration" : "public func bar()",
"key.doc.column" : 17,
"key.usr" : "s:FC10KittenTest3Foo3barFS0_FT_T_",
"key.doc.type" : "Function",
"key.attributes" : [
{
"key.attribute" : "source.decl.attribute.__raw_doc_comment"
}
],
"key.doc.full_as_xml" : "<Function file=\"\/private\/tmp\/KittenTest\/KittenTest\/KittenTest.swift\" line=\"14\" column=\"17\"><Name>bar()<\/Name><USR>s:FC10KittenTest3Foo3barFS0_FT_T_<\/USR><Declaration>public func bar()<\/Declaration><Abstract><Para>bar comment<\/Para><\/Abstract><\/Function>",
"key.nameoffset" : 236,
"key.doc.file" : "\/private\/tmp\/KittenTest\/KittenTest\/KittenTest.swift",
"key.annotated_decl" : "<Declaration>public func bar()<\/Declaration>",
"key.doc.name" : "bar()",
"key.accessibility" : "source.lang.swift.accessibility.public",
"key.doc.usr" : "s:FC10KittenTest3Foo3barFS0_FT_T_",
"key.filepath" : "\/private\/tmp\/KittenTest\/KittenTest\/KittenTest.swift"
}
],
"key.doc.usr" : "s:C10KittenTest3Foo"
},
{
"key.kind" : "source.lang.swift.decl.function.method.instance",
"key.offset" : 236,
"key.doc.comment" : "bar comment",
"key.doc.declaration" : "public func bar()",
"key.doc.line" : 14,
"key.length" : 5,
"key.typename" : "Foo -> () -> ()",
"key.name" : "bar()",
"key.doc.column" : 17,
"key.usr" : "s:FC10KittenTest3Foo3barFS0_FT_T_",
"key.doc.type" : "Function",
"key.doc.file" : "\/private\/tmp\/KittenTest\/KittenTest\/KittenTest.swift",
"key.doc.full_as_xml" : "<Function file=\"\/private\/tmp\/KittenTest\/KittenTest\/KittenTest.swift\" line=\"14\" column=\"17\"><Name>bar()<\/Name><USR>s:FC10KittenTest3Foo3barFS0_FT_T_<\/USR><Declaration>public func bar()<\/Declaration><Abstract><Para>bar comment<\/Para><\/Abstract><\/Function>",
"key.doc.name" : "bar()",
"key.annotated_decl" : "<Declaration>public func bar()<\/Declaration>",
"key.doc.usr" : "s:FC10KittenTest3Foo3barFS0_FT_T_",
"key.filepath" : "\/private\/tmp\/KittenTest\/KittenTest\/KittenTest.swift"
},
{
"key.kind" : "source.lang.swift.decl.class",
"key.offset" : 194,
"key.doc.comment" : "Foo class comment",
"key.doc.declaration" : "public class Foo",
"key.doc.line" : 12,
"key.length" : 3,
"key.typename" : "Foo.Type",
"key.name" : "Foo",
"key.doc.column" : 14,
"key.usr" : "s:C10KittenTest3Foo",
"key.doc.type" : "Class",
"key.doc.file" : "\/private\/tmp\/KittenTest\/KittenTest\/KittenTest.swift",
"key.doc.full_as_xml" : "<Class file=\"\/private\/tmp\/KittenTest\/KittenTest\/KittenTest.swift\" line=\"12\" column=\"14\"><Name>Foo<\/Name><USR>s:C10KittenTest3Foo<\/USR><Declaration>public class Foo<\/Declaration><Abstract><Para>Foo class comment<\/Para><\/Abstract><\/Class>",
"key.doc.name" : "Foo",
"key.annotated_decl" : "<Declaration>public class Foo<\/Declaration>",
"key.doc.usr" : "s:C10KittenTest3Foo",
"key.filepath" : "\/private\/tmp\/KittenTest\/KittenTest\/KittenTest.swift"
},
{
"key.kind" : "source.lang.swift.decl.function.method.instance",
"key.offset" : 338,
"key.doc.comment" : "baz comment",
"key.doc.declaration" : "public func baz()",
"key.doc.line" : 21,
"key.length" : 5,
"key.typename" : "Foo -> () -> ()",
"key.name" : "baz()",
"key.doc.column" : 17,
"key.usr" : "s:FC10KittenTest3Foo3bazFS0_FT_T_",
"key.doc.type" : "Function",
"key.doc.file" : "\/private\/tmp\/KittenTest\/KittenTest\/KittenTest.swift",
"key.doc.full_as_xml" : "<Function file=\"\/private\/tmp\/KittenTest\/KittenTest\/KittenTest.swift\" line=\"21\" column=\"17\"><Name>baz()<\/Name><USR>s:FC10KittenTest3Foo3bazFS0_FT_T_<\/USR><Declaration>public func baz()<\/Declaration><Abstract><Para>baz comment<\/Para><\/Abstract><\/Function>",
"key.doc.name" : "baz()",
"key.annotated_decl" : "<Declaration>public func baz()<\/Declaration>",
"key.doc.usr" : "s:FC10KittenTest3Foo3bazFS0_FT_T_",
"key.filepath" : "\/private\/tmp\/KittenTest\/KittenTest\/KittenTest.swift"
},
{
"key.kind" : "source.lang.swift.decl.extension",
"key.offset" : 194,
"key.doc.comment" : "Foo class comment",
"key.namelength" : 3,
"key.bodyoffset" : 301,
"key.bodylength" : 51,
"key.length" : 3,
"key.doc.line" : 12,
"key.name" : "Foo",
"key.typename" : "Foo.Type",
"key.doc.declaration" : "public class Foo",
"key.doc.column" : 14,
"key.usr" : "s:C10KittenTest3Foo",
"key.doc.type" : "Class",
"key.attributes" : [
{
"key.attribute" : "source.decl.attribute.__raw_doc_comment"
}
],
"key.doc.full_as_xml" : "<Class file=\"\/private\/tmp\/KittenTest\/KittenTest\/KittenTest.swift\" line=\"12\" column=\"14\"><Name>Foo<\/Name><USR>s:C10KittenTest3Foo<\/USR><Declaration>public class Foo<\/Declaration><Abstract><Para>Foo class comment<\/Para><\/Abstract><\/Class>",
"key.nameoffset" : 296,
"key.doc.file" : "\/private\/tmp\/KittenTest\/KittenTest\/KittenTest.swift",
"key.annotated_decl" : "<Declaration>public class Foo<\/Declaration>",
"key.doc.name" : "Foo",
"key.substructure" : [
{
"key.kind" : "source.lang.swift.decl.function.method.instance",
"key.offset" : 338,
"key.doc.comment" : "baz comment",
"key.namelength" : 5,
"key.bodyoffset" : 345,
"key.bodylength" : 5,
"key.length" : 5,
"key.doc.line" : 21,
"key.name" : "baz()",
"key.typename" : "Foo -> () -> ()",
"key.doc.declaration" : "public func baz()",
"key.doc.column" : 17,
"key.usr" : "s:FC10KittenTest3Foo3bazFS0_FT_T_",
"key.doc.type" : "Function",
"key.attributes" : [
{
"key.attribute" : "source.decl.attribute.__raw_doc_comment"
}
],
"key.doc.full_as_xml" : "<Function file=\"\/private\/tmp\/KittenTest\/KittenTest\/KittenTest.swift\" line=\"21\" column=\"17\"><Name>baz()<\/Name><USR>s:FC10KittenTest3Foo3bazFS0_FT_T_<\/USR><Declaration>public func baz()<\/Declaration><Abstract><Para>baz comment<\/Para><\/Abstract><\/Function>",
"key.nameoffset" : 338,
"key.doc.file" : "\/private\/tmp\/KittenTest\/KittenTest\/KittenTest.swift",
"key.annotated_decl" : "<Declaration>public func baz()<\/Declaration>",
"key.doc.name" : "baz()",
"key.accessibility" : "source.lang.swift.accessibility.public",
"key.doc.usr" : "s:FC10KittenTest3Foo3bazFS0_FT_T_",
"key.filepath" : "\/private\/tmp\/KittenTest\/KittenTest\/KittenTest.swift"
}
],
"key.doc.usr" : "s:C10KittenTest3Foo",
"key.filepath" : "\/private\/tmp\/KittenTest\/KittenTest\/KittenTest.swift"
}
],
"key.offset" : 0,
"key.diagnostic_stage" : "source.diagnostic.stage.swift.parse",
"key.length" : 354
}
}]
//
// KittenTest.swift
// KittenTest
//
// Created by Paul on 2015/9/13.
// Copyright © 2015 Kodama Software. All rights reserved.
//
import Foundation
/// Foo class comment
public class Foo {
/// bar comment
public func bar() {
}
}
/// Foo extension comment
public extension Foo {
/// baz comment
public func baz() {
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment