ForgeFlower
ForgeFlower copied to clipboard
Forge's modifications to FernFlower. Fixing various bugs/inconsistencies. Main Repo: https://github.com/MinecraftForge/FernFlower
MC 1.16-pre1 `BackupList.func_230753_a_` ```java ... try { JsonElement jsonelement = jsonparser.parse(p_230753_0_).getAsJsonObject().get("backups"); if (jsonelement.isJsonArray()) { Iterator iterator = jsonelement.getAsJsonArray().iterator(); while(iterator.hasNext()) { backuplist.field_230560_a_.add(Backup.func_230750_a_(iterator.next())); } } } catch (Exception exception) { field_230561_b_.error("Could not...
1.16-pre1 RealmsSelectWorldTemplate.func_224497_a ``` WorldTemplatePaginatedList worldtemplatepaginatedlist = p_224497_1_; Either either; for(RealmsClient realmsclient = RealmsClient.func_224911_a(); worldtemplatepaginatedlist != null; worldtemplatepaginatedlist = RealmsSelectWorldTemplateScreen.this.field_230706_i_.func_213169_a(() -> { if (either.right().isPresent()) { ... } else { ... }...
1.16-pre1 net\minecraft\client\gui\widget\list\OptionsRowList ``` public Optional func_238518_c_(double p_238518_1_, double p_238518_3_) { label21: for(OptionsRowList.Row optionsrowlist$row : this.func_230969_at__()) { Iterator iterator = optionsrowlist$row.field_214385_a.iterator(); Widget widget; while(true) { if (!iterator.hasNext()) { continue label21; }...
The point of this is to make generics and type information better. However it has a major memory cost as it reads ALL the classes in the classpath and parses...
With @JDLogic's pr to inline simple lambdas, some complex minecraft classes are producing lines in the 1000+ characters, so we need to introduce max line lengths.
Posting this because I think this patch is solid as is, and it fixes almost all the casting bugs that require patches. With that said, it also brings out some...
``` public void func_216099_a(ValidationResults p_216099_1_, Function p_216099_2_, Set p_216099_3_, LootParameterSet p_216099_4_) { for(int i = 0; i < this.poolConditions.size(); ++i) { this.poolConditions.get(i).func_215856_a(p_216099_1_.func_216108_b(".condition[" + i + "]"), p_216099_2_, p_216099_3_, p_216099_4_); }...
See 1.13.1 EntityPlayerSP func_71007_a ``` Iterator iterator = this.field_70170_p.func_212388_b(this, axisalignedbb).flatMap((p_212329_0_) -> { return p_212329_0_.func_197756_d().stream(); }).iterator(); float f11 = Float.MIN_VALUE; while(iterator.hasNext()) { AxisAlignedBB axisalignedbb1 = iterator.next(); ```
1.13.1 TextureGlyphProviderUnicode constructor ``` public TextureGlyphProviderUnicode(IResourceManager p_i49737_1_, byte[] p_i49737_2_, String p_i49737_3_) { this.field_211257_b = p_i49737_1_; this.field_211258_c = p_i49737_2_; this.field_211259_d = p_i49737_3_; label322: for(int i = 0; i < 256; ++i)...
Could it be FernFlower causing this bug? https://github.com/MinecraftForge/MinecraftForge/issues/2321 The `(int)` cast needs to be applied to the entire `p_181663_1_ * 127` expression, but the parentheses are left out so that...