mirror of
https://github.com/github/semantic.git
synced 2024-11-25 11:04:00 +03:00
commit
db6d485f82
@ -27,7 +27,6 @@
|
||||
D432D4711BA9AC0B00F3FABC /* SESTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = D432D4701BA9AC0B00F3FABC /* SESTests.swift */; };
|
||||
D4413FEF1BB06D4C00E3C3C1 /* Dictionary.swift in Sources */ = {isa = PBXBuildFile; fileRef = D4413FEE1BB06D4C00E3C3C1 /* Dictionary.swift */; };
|
||||
D4413FF11BB08FDC00E3C3C1 /* JSON.swift in Sources */ = {isa = PBXBuildFile; fileRef = D4413FF01BB08FDC00E3C3C1 /* JSON.swift */; };
|
||||
D45A36C91BBC667D00BE3DDE /* Category.swift in Sources */ = {isa = PBXBuildFile; fileRef = D45A36C81BBC667D00BE3DDE /* Category.swift */; settings = {ASSET_TAGS = (); }; };
|
||||
D49FCBC41BBEF98E00C5E9C3 /* Free.swift in Sources */ = {isa = PBXBuildFile; fileRef = D49FCBC31BBEF98E00C5E9C3 /* Free.swift */; settings = {ASSET_TAGS = (); }; };
|
||||
D49FCBC61BBF214300C5E9C3 /* Patch.swift in Sources */ = {isa = PBXBuildFile; fileRef = D49FCBC51BBF214300C5E9C3 /* Patch.swift */; settings = {ASSET_TAGS = (); }; };
|
||||
D49FCBC81BBF2C4300C5E9C3 /* Algorithm.swift in Sources */ = {isa = PBXBuildFile; fileRef = D49FCBC71BBF2C4300C5E9C3 /* Algorithm.swift */; settings = {ASSET_TAGS = (); }; };
|
||||
@ -68,7 +67,6 @@
|
||||
D435B7521BB31BBC000902F6 /* BoundsCheckedArray.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = BoundsCheckedArray.swift; sourceTree = "<group>"; };
|
||||
D4413FEE1BB06D4C00E3C3C1 /* Dictionary.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = Dictionary.swift; sourceTree = "<group>"; };
|
||||
D4413FF01BB08FDC00E3C3C1 /* JSON.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = JSON.swift; sourceTree = "<group>"; };
|
||||
D45A36C81BBC667D00BE3DDE /* Category.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = Category.swift; sourceTree = "<group>"; };
|
||||
D49FCBC31BBEF98E00C5E9C3 /* Free.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = Free.swift; sourceTree = "<group>"; };
|
||||
D49FCBC51BBF214300C5E9C3 /* Patch.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = Patch.swift; sourceTree = "<group>"; };
|
||||
D49FCBC71BBF2C4300C5E9C3 /* Algorithm.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = Algorithm.swift; sourceTree = "<group>"; };
|
||||
@ -160,7 +158,6 @@
|
||||
D4413FF01BB08FDC00E3C3C1 /* JSON.swift */,
|
||||
D40B89C31BC319070078E098 /* Matrix.swift */,
|
||||
D4D7F3161BBB22E500AAB0C0 /* Hash.swift */,
|
||||
D45A36C81BBC667D00BE3DDE /* Category.swift */,
|
||||
D49FCBC31BBEF98E00C5E9C3 /* Free.swift */,
|
||||
D42F097B1BCE914A00B95610 /* Cofree.swift */,
|
||||
D49FCBC51BBF214300C5E9C3 /* Patch.swift */,
|
||||
@ -345,7 +342,6 @@
|
||||
D4413FEF1BB06D4C00E3C3C1 /* Dictionary.swift in Sources */,
|
||||
D4D7F3171BBB22E500AAB0C0 /* Hash.swift in Sources */,
|
||||
D42F097E1BCEAEDA00B95610 /* Operation.swift in Sources */,
|
||||
D45A36C91BBC667D00BE3DDE /* Category.swift in Sources */,
|
||||
D4DF96ED1BC46B630040F41F /* SES.swift in Sources */,
|
||||
D42F09801BCECB7900B95610 /* TermType.swift in Sources */,
|
||||
D4AAE5401B5AE2D0004E581F /* RangeReplaceableCollectionType.swift in Sources */,
|
||||
|
@ -1,52 +0,0 @@
|
||||
public enum Category: AlgebraicHashable, Comparable, CustomDebugStringConvertible, CustomJSONConvertible {
|
||||
case Tag(String)
|
||||
|
||||
|
||||
public var tag: String {
|
||||
switch self {
|
||||
case let .Tag(s):
|
||||
return s
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// MARK: AlgebraicHashable
|
||||
|
||||
public var hash: Hash {
|
||||
return Hash("Tag", Hash(tag))
|
||||
}
|
||||
|
||||
|
||||
// MARK: CustomDebugStringConvertible
|
||||
|
||||
public var debugDescription: String {
|
||||
switch self {
|
||||
case let .Tag(s):
|
||||
return ".Tag(\(s))"
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// MARK: CustomJSONConvertible
|
||||
|
||||
public var JSON: Doubt.JSON {
|
||||
switch self {
|
||||
case let .Tag(s):
|
||||
return [ "tag": .String(s) ]
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// MARK: - Equatable
|
||||
|
||||
public func == (left: Category, right: Category) -> Bool {
|
||||
return left.tag == right.tag
|
||||
}
|
||||
|
||||
|
||||
// MARK: - Comparable
|
||||
|
||||
public func < (left: Category, right: Category) -> Bool {
|
||||
return left.tag < right.tag
|
||||
}
|
Loading…
Reference in New Issue
Block a user