diff --git a/src/org/jetbrains/java/decompiler/main/ClassWriter.java b/src/org/jetbrains/java/decompiler/main/ClassWriter.java index 8d862c8..5d90668 100644 --- a/src/org/jetbrains/java/decompiler/main/ClassWriter.java +++ b/src/org/jetbrains/java/decompiler/main/ClassWriter.java @@ -716,8 +716,8 @@ public class ClassWriter { appendParameterAnnotations(buffer, mt, paramCount); - if (methodParameters != null && paramCount < methodParameters.size()) { - appendModifiers(buffer, methodParameters.get(paramCount).myAccessFlags, CodeConstants.ACC_FINAL, isInterface, 0); + if (methodParameters != null && i < methodParameters.size()) { + appendModifiers(buffer, methodParameters.get(i).myAccessFlags, CodeConstants.ACC_FINAL, isInterface, 0); } else if (methodWrapper.varproc.getVarFinal(new VarVersionPair(index, 0)) == VarTypeProcessor.VAR_EXPLICIT_FINAL) { buffer.append("final "); @@ -755,8 +755,8 @@ public class ClassWriter { buffer.append(' '); String parameterName; - if (methodParameters != null && paramCount < methodParameters.size()) { - parameterName = methodParameters.get(paramCount).myName; + if (methodParameters != null && i < methodParameters.size()) { + parameterName = methodParameters.get(i).myName; } else { parameterName = methodWrapper.varproc.getVarName(new VarVersionPair(index, 0)); diff --git a/testData/results/TestMethodParametersAttr.dec b/testData/results/TestMethodParametersAttr.dec index ba00341..a48380b 100644 --- a/testData/results/TestMethodParametersAttr.dec +++ b/testData/results/TestMethodParametersAttr.dec @@ -12,7 +12,7 @@ public class TestMethodParametersAttr { void local() { class Local { - Local(final int this$0) { + Local(int p31) { }// 36 void m(int p32) { @@ -51,7 +51,7 @@ public class TestMethodParametersAttr { } class C1 { - C1(final int this$0) { + C1(int p11) { }// 24 void m(int p12) {