 }
 extension JSON : Sequence {
     public enum IteratorKey {
+        case None
         case Index(Int)
         case Key(String)
         public var index:Int?  { switch self { case .Index(let v): return v default: return nil } }
         public var key:String? { switch self { case .Key(let v):   return v default: return nil } }
     }
-    public typealias Element = (IteratorKey,JSON)  // for Sequence conformance
+    public typealias Element = (key:IteratorKey,value:JSON)  // for Sequence conformance
     public typealias Iterator = AnyIterator<Element>
     public func makeIterator() -> AnyIterator<JSON.Element> {
         switch self {

        default:
            return AnyIterator { nil }
        }
    }
}
extension JSON : Codable {

        case .Number(let v):    return v.description
        case .String(let v):    return v.debugDescription
        case .Array(let a):
            return "[" + t
                + a.map{ $0.toString(depth:d+1, separator:s, terminator:t, sortedKey:sortedKey) }
                    .map{ i + s + $0 }.joined(separator:","+t) + t
                + i + "]" + (d == 0 ? t : "")
        case .Object(let o):
            let a = sortedKey ? o.map{ $0 }.sorted{ $0.0 < $1.0 } : o.map{ $0 }
            return "{" + t
                + a.map { $0.debugDescription + g + ":" + g + $1.toString(depth:d+1, separator:s, terminator:t, sortedKey:sortedKey) }
                    .map{ i + s + $0 }.joined(separator:"," + t) + t
                + i + "}" + (d == 0 ? t : "")
        }
    }
    public func toString(space:Int=0)->String {
        return space == 0
            ? toString(depth:0, separator:"", terminator:"")
            : toString(depth:0, separator:Swift.String(repeating:" ", count:space), terminator:"\n", sortedKey:true)
    }
    public var description:String {
        return self.toString()
    }
}
// Inits
