From 1db7052464d8956d7ebe303b15729a7c0be557bf Mon Sep 17 00:00:00 2001 From: Roel Spilker Date: Wed, 22 Mar 2017 22:02:12 +0100 Subject: [jdk9] Workaround for a weird casting issue that shows up for singularizer support. --- test/transform/resource/after-delombok/BuilderSingularMaps.java | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'test/transform') diff --git a/test/transform/resource/after-delombok/BuilderSingularMaps.java b/test/transform/resource/after-delombok/BuilderSingularMaps.java index 257a2ec2..6520568b 100644 --- a/test/transform/resource/after-delombok/BuilderSingularMaps.java +++ b/test/transform/resource/after-delombok/BuilderSingularMaps.java @@ -166,11 +166,11 @@ class BuilderSingularMaps { break; default: women = new java.util.LinkedHashMap(this.women$key.size() < 1073741824 ? 1 + this.women$key.size() + (this.women$key.size() - 3) / 3 : Integer.MAX_VALUE); - for (int $i = 0; $i < this.women$key.size(); $i++) women.put(this.women$key.get($i), this.women$value.get($i)); + for (int $i = 0; $i < this.women$key.size(); $i++) women.put(this.women$key.get($i), (V) this.women$value.get($i)); women = java.util.Collections.unmodifiableMap(women); } java.util.SortedMap men = new java.util.TreeMap(); - if (this.men$key != null) for (int $i = 0; $i < (this.men$key == null ? 0 : this.men$key.size()); $i++) men.put(this.men$key.get($i), this.men$value.get($i)); + if (this.men$key != null) for (int $i = 0; $i < (this.men$key == null ? 0 : this.men$key.size()); $i++) men.put(this.men$key.get($i), (Number) this.men$value.get($i)); men = java.util.Collections.unmodifiableSortedMap(men); java.util.Map rawMap; switch (this.rawMap$key == null ? 0 : this.rawMap$key.size()) { @@ -182,7 +182,7 @@ class BuilderSingularMaps { break; default: rawMap = new java.util.LinkedHashMap(this.rawMap$key.size() < 1073741824 ? 1 + this.rawMap$key.size() + (this.rawMap$key.size() - 3) / 3 : Integer.MAX_VALUE); - for (int $i = 0; $i < this.rawMap$key.size(); $i++) rawMap.put(this.rawMap$key.get($i), this.rawMap$value.get($i)); + for (int $i = 0; $i < this.rawMap$key.size(); $i++) rawMap.put(this.rawMap$key.get($i), (Object) this.rawMap$value.get($i)); rawMap = java.util.Collections.unmodifiableMap(rawMap); } java.util.Map stringMap; @@ -195,7 +195,7 @@ class BuilderSingularMaps { break; default: stringMap = new java.util.LinkedHashMap(this.stringMap$key.size() < 1073741824 ? 1 + this.stringMap$key.size() + (this.stringMap$key.size() - 3) / 3 : Integer.MAX_VALUE); - for (int $i = 0; $i < this.stringMap$key.size(); $i++) stringMap.put(this.stringMap$key.get($i), this.stringMap$value.get($i)); + for (int $i = 0; $i < this.stringMap$key.size(); $i++) stringMap.put(this.stringMap$key.get($i), (V) this.stringMap$value.get($i)); stringMap = java.util.Collections.unmodifiableMap(stringMap); } return new BuilderSingularMaps(women, men, rawMap, stringMap); -- cgit