Re: Remove redundant calls of toString()

2014-04-27 Thread Otávio Gonçalves de Santana
In my opinion not, because Objects.requireNonNull is more readable than just string.toString. This way is more understandable which field is required and doesn't impact on performance. On Sun, Apr 27, 2014 at 11:33 PM, David Holmes wrote: > On 28/04/2014 3:41 AM, Otávio Gonçalves de Santana wrot

Re: Remove redundant calls of toString()

2014-04-27 Thread David Holmes
On 28/04/2014 3:41 AM, Otávio Gonçalves de Santana wrote: sorry. I tried answer and the message was twice. But Yes when has null pointer possibility I replaced to Objects.requireNonNull. In my opinion that is making the code worse not better. David - I am review the code again. The cod

Re: Covariant overrides on the Buffer Hierachy

2014-04-27 Thread Richard Warburton
Hi, There are multiple possible targets for invokevirtual >> position:(I)Ljava/nio/Buffer; - all the methods that override it in all >> subclasses loaded. It doesn't matter if they are final or not (only if >> they are effectively final or not). The non-finality of a method has a >> performance im

Re: Remove redundant calls of toString()

2014-04-27 Thread Otávio Gonçalves de Santana
sorry. I tried answer and the message was twice. But Yes when has null pointer possibility I replaced to Objects.requireNonNull. I am review the code again. The code below: diff -r e323c74edabd src/share/classes/com/sun/tools/example/debug/tty/Commands.java --- a/src/share/classes/com/sun/tools/e

Remove redundant calls of toString()

2014-04-27 Thread Otávio Gonçalves de Santana
There is an issue that was opened to remove redundant calls of toString() on String objects. [1] I went deep on all JVM sources and I found all, 32 changes. [1]https://bugs.openjdk.java.net/browse/JDK-8015470 diff -r e323c74edabd src/share/classes/com/sun/tools/example/debug/tty/Commands.java -

Re: Remove redundant calls of toString()

2014-04-27 Thread Remi Forax
On 04/27/2014 03:15 PM, Otávio Gonçalves de Santana wrote: There is an issue that was opened to remove redundant calls of toString() on String objects. [1] I went deep on all JVM sources and I found all, 32 changes. [1]https://bugs.openjdk.java.net/browse/JDK-8015470 Otavio, calling toString(

Remove redundant calls of toString()

2014-04-27 Thread Otávio Gonçalves de Santana
There is an issue that was opened to remove redundant calls of toString() on String objects. [1] I went deep on all JVM sources and I found all, 32 changes. [1]https://bugs.openjdk.java.net/browse/JDK-8015470 diff -r e323c74edabd src/share/classes/com/sun/tools/example/debug/tty/Commands.java -