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.
I'm currently evaluating NetBeans against Eclipse. One awesome thing that Eclipse does and NetBeans doesn't is this: - I'm typing a method call "A.method(" - Both Eclipse and Netbeans auto-close the parenthesis to "A.method()" Now, this is great in case the parenthesis gets forgotten. But I often WANT to type the parenthesis, because that's how I think about code. So, when I do type it, here's the output (cursor illustrated as |) - For Eclipse: Still "A.method()|" - For Netbeans: "A.method())|" That's rather annoying, and if I don't notice, and I'm deeply nesting lambdas and chained method calls, it's very hard to debug the excess parenthesis. It would be great if closing parentheses are ignored iff: - I have just typed an open parenthesis - Netbeans has auto-generated the closing parenthesis - I have not typed anything else in the meantime
In fact, this doesn't always happen, but it seems to happen very often in the code I'm currently writing. Here's a way to reproduce the issue: ------------------------------------------ public class Test { public void x() { assertEquals( asList( new BigDecimal ) ) } } ------------------------------------------ Now, place the cursor after "BigDecimal" and type "()". The result is: ------------------------------------------ public class Test { public void x() { assertEquals( asList( new BigDecimal()) ) ) } } ------------------------------------------
This indeed looks like a bug to me and I can reproduce it with 8.0.2. Normally this just works as you say. E.g. this works: public class Test { public void x() { new BigDecimal } }