 
 public func ==(lhs: JSON, rhs: JSON) -> Bool {
     switch (lhs, rhs) {
-    case (.jsonNull, .jsonNull):
+    case (.null, .null):
         return true
         
-    case (.jsonBool(let lhsValue), .jsonBool(let rhsValue)):
-        return lhsValue == rhsValue
-
-    case (.jsonString(let lhsValue), .jsonString(let rhsValue)):
-        return lhsValue == rhsValue
-
-    case (.jsonNumber(let lhsValue), .jsonNumber(let rhsValue)):
-        return lhsValue == rhsValue
-
-    case (.jsonArray(let lhsValue), .jsonArray(let rhsValue)):
-        return lhsValue == rhsValue
-
-    case (.jsonObject(let lhsValue), .jsonObject(let rhsValue)):
+    case (.bool(let lhsValue), .bool(let rhsValue)):
+        return lhsValue == rhsValue
+
+    case (.string(let lhsValue), .string(let rhsValue)):
+        return lhsValue == rhsValue
+
+    case (.number(let lhsValue), .number(let rhsValue)):
+        return lhsValue == rhsValue
+
+    case (.array(let lhsValue), .array(let rhsValue)):
+        return lhsValue == rhsValue
+
+    case (.object(let lhsValue), .object(let rhsValue)):
         return lhsValue == rhsValue
         
     default:

    }

    func stringify(_ indent: String = "  ") -> String? {
        guard self != .jsonInvalid else {
            assert(true, "The JSON value is invalid")
            return nil
        }

        let nextIndent = currentIndent + "  "
        
        switch self {
        case .bool(let bool):
            return bool ? "true" : "false"
            
        case .number(let number):
            return "\(number)"
            
        case .string(let string):
            return "\"\(string)\""
            
        case .array(let array):
            return "[\n" + array.map { "\(nextIndent)\($0.prettyPrint(indent, level + 1))" }.joined(separator: ",\n") + "\n\(currentIndent)]"
            
        case .object(let dict):
            return "{\n" + dict.map { "\(nextIndent)\"\($0)\" : \($1.prettyPrint(indent, level + 1))"}.joined(separator: ",\n") + "\n\(currentIndent)}"
            
        case .null:
            return "null"
            
        case .invalid:
            assert(true, "This should never be reached")
            return ""
        }
