                 }
                 let propertyInit = renderPropertyInit(currentTmp, currentObj, keyPath: keyPath + ["?".objcLiteral()], schema: itemType, firstName: firstName, counter: counter + 1).joined(separator: "\n")
                 return renderTypeCheck { [
-                    "NSArray *items = \(rawObjectName);",
-                    "NSMutableArray *\(currentResult) = [NSMutableArray arrayWithCapacity:items.count];",
-                    ObjCIR.forStmt("id \(currentObj) in items") { [
+                    "NSArray *\(currentItems) = \(rawObjectName);",
+                    "NSMutableArray *\(currentResult) = [NSMutableArray arrayWithCapacity:\(currentItems).count];",
+                    ObjCIR.forStmt("id \(currentObj) in \(currentItems)") { [
                         ObjCIR.ifStmt("\(currentObj) != (id)kCFNull") { [
                             "id \(currentTmp) = nil;",
                             propertyInit,

                let currentResult = "result\(counter)"
                let currentTmp = "tmp\(counter)"
                let currentObj = "obj\(counter)"
                if itemType.isPrimitiveType {
                    return renderTypeCheck { [
                        "\(propertyToAssign) = \(rawObjectName);",

                let currentResult = "result\(counter)"
                let currentTmp = "tmp\(counter)"
                let currentObj = "obj\(counter)"
                let currentItems = "items\(counter)"
                if itemType.isPrimitiveType {
                    return renderTypeCheck { [
                        "NSArray *\(currentItems) = \(rawObjectName);",
                        "\(propertyToAssign) = [NSSet setWithArray:\(currentItems)];",
                    ] }
                }
                let propertyInit = renderPropertyInit(currentTmp, currentObj, keyPath: keyPath + ["?".objcLiteral()], schema: itemType, firstName: firstName, counter: counter + 1).joined(separator: "\n")
                return renderTypeCheck { [
                    "NSArray *\(currentItems) = \(rawObjectName);",
                    "NSMutableSet *\(currentResult) = [NSMutableSet setWithCapacity:\(currentItems).count];",
                    ObjCIR.forStmt("id \(currentObj) in \(currentItems)") { [
                        ObjCIR.ifStmt("\(currentObj) != (id)kCFNull") { [
                            "id \(currentTmp) = nil;",
                            propertyInit,
