This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
Build: NetBeans IDE 8.1 (Build 201510222201) VM: Java HotSpot(TM) 64-Bit Server VM, 25.51-b03, Java(TM) SE Runtime Environment, 1.8.0_51-b16 OS: Linux User Comments: FiruzzZ: trying to "change method signature", adding a parameter at the beginning of it The method is private and called just from one place. rcasha: Created a new class "X" without a constructor Created a static main method In the main method, call "new X(args);" From the hints, selected "change constructor" option This error was generated. bht: Adding a parameter to a method call then trying to change method signature to add the parameter. peterhull90: Refactoring - changing method signature GUEST: Using IDE, trying to refactor method signature. Stacktrace: java.lang.IndexOutOfBoundsException: Index: -1, Size: 0 at java.util.LinkedList.checkElementIndex(LinkedList.java:555) at java.util.LinkedList.get(LinkedList.java:476) at org.netbeans.modules.refactoring.java.ui.ChangeParametersPanel.initTableData(ChangeParametersPanel.java:799) at org.netbeans.modules.refactoring.java.ui.ChangeParametersPanel.access$800(ChangeParametersPanel.java:92) at org.netbeans.modules.refactoring.java.ui.ChangeParametersPanel$2.run(ChangeParametersPanel.java:236) at org.netbeans.modules.refactoring.java.ui.ChangeParametersPanel$2.run(ChangeParametersPanel.java:195)
Created attachment 157429 [details] stacktrace
Created attachment 157445 [details] stacktrace On refactoring - change method parameters
Created attachment 157610 [details] stacktrace trying to Change method signature from this: private void calcularCoberturaPostBajaOS() to: calcularCoberturaPostBajaOS(TipoBaja tb, Date fechaBaja)
Created attachment 157643 [details] stacktrace trying to change method signature (using hint) from one parameter to 2 params
Created attachment 157920 [details] stacktrace An attempt to change method's parameters. (Accepted a proposed refactoring hint).
This bug already has 10 duplicates see http://statistics.netbeans.org/exceptions/detail.do?id=219793
Created attachment 158344 [details] stacktrace Update method via hint
Created attachment 158403 [details] stacktrace Change method parameter
This bug already has 20 duplicates see http://statistics.netbeans.org/exceptions/detail.do?id=219793
changeset: 587d78c734ce user: Ralph Benjamin Ruijs <ralphbenjamin@netbeans.org> date: Thu Mar 03 13:23:58 2016 +0100 summary: #256710 - New parameters can be added by clients
Integrated into 'main-silver', will be available in build *201603040002* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main-silver/rev/587d78c734ce User: Ralph Benjamin Ruijs <ralphbenjamin@netbeans.org> Log: #256710 - New parameters can be added by clients
Can somebody from reporters of this bug please verify the fix in the latest development build [1]? Thanks! [1] http://bits.netbeans.org/dev/nightly/latest/
(In reply to Jiri Kovalsky from comment #12) > Can somebody from reporters of this bug please verify the fix in the latest > development build [1]? Thanks! > > [1] http://bits.netbeans.org/dev/nightly/latest/ Using the steps: rcasha: Created a new class "X" without a constructor Created a static main method In the main method, call "new X(args);" From the hints, selected "change constructor" option This error was generated. Producible using Product Version: NetBeans IDE 8.1 (Build 201510222201) Not producible anymore using Product Version: NetBeans IDE Dev (Build 201603200001)