use known list size

master
Egor.Ushakov 8 years ago
parent 5e45e5ac40
commit abbf2daf30
  1. 4
      src/org/jetbrains/java/decompiler/main/rels/NestedClassProcessor.java

@ -1,5 +1,5 @@
/* /*
* Copyright 2000-2015 JetBrains s.r.o. * Copyright 2000-2017 JetBrains s.r.o.
* *
* Licensed under the Apache License, Version 2.0 (the "License"); * Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License. * you may not use this file except in compliance with the License.
@ -605,7 +605,7 @@ public class NestedClassProcessor {
DirectGraph graph = method.getOrBuildGraph(); DirectGraph graph = method.getOrBuildGraph();
if (graph != null) { // something gone wrong, should not be null if (graph != null) { // something gone wrong, should not be null
List<VarFieldPair> fields = new ArrayList<>(); List<VarFieldPair> fields = new ArrayList<>(md.params.length);
int varIndex = 1; int varIndex = 1;
for (int i = 0; i < md.params.length; i++) { // no static methods allowed for (int i = 0; i < md.params.length; i++) { // no static methods allowed

Loading…
Cancel
Save