Re[2]: Implicit 'this' return for void methods

2014-03-27 Thread Victor Polischuk
Ulf, I think that point leading style is something which can be easily mistreat. If we complicate the example: String mySub = myVeryLongNamedString.substring(.indexOf("C"),.indexOf("Q")); to something like: String mySub = myVeryLongNamedString.concat("BLAH").substring(.indexOf("C"),.ind

Re: Implicit 'this' return for void methods

2014-03-27 Thread Ulf Zibis
Am 27.03.2014 23:05, schrieb Eirik Lygre: With this suggested change, the only behavior that will change is that some code which used to not compile will start compiling, with a reasonable result. No code that used to compile will change. Yes, this is one of the great advantages of this "simpl

Re: Implicit 'this' return for void methods

2014-03-27 Thread Eirik Lygre
On Thu, Mar 27, 2014 at 10:02 PM, Jochen Theodorou wrote: > Am 27.03.2014 21:52, schrieb Eirik Lygre: > [...] > > The JavaBean specification, with it's "void setSomething()" functions >> are fundamental to so many things Java that they will never go away >> (good thing, too!).The suggested langua

Re: JDK-8038451: Incorrect initialization order of static fields in sun.nio.cs.ext.JISAutoDetect$Decoder

2014-03-27 Thread Xueming Shen
On 03/27/2014 01:49 PM, Mandy Chung wrote: This fixes the regression introduced by JDK-8038177 in which the osName field should be initialized before it's accessed in the class static initializer. https://bugs.openjdk.java.net/browse/JDK-8038451 Webrev at: http://cr.openjdk.java.net/~mchung/jd

Re: Implicit 'this' return for void methods

2014-03-27 Thread Jochen Theodorou
Am 27.03.2014 21:52, schrieb Eirik Lygre: [...] The JavaBean specification, with it's "void setSomething()" functions are fundamental to so many things Java that they will never go away (good thing, too!).The suggested language change builds on top of that, is beneficial to a large body of existi

Re: JDK-8038451: Incorrect initialization order of static fields in sun.nio.cs.ext.JISAutoDetect$Decoder

2014-03-27 Thread Alan Bateman
On 27/03/2014 20:49, Mandy Chung wrote: This fixes the regression introduced by JDK-8038177 in which the osName field should be initialized before it's accessed in the class static initializer. https://bugs.openjdk.java.net/browse/JDK-8038451 Webrev at: http://cr.openjdk.java.net/~mchung/jdk9

Re: Implicit 'this' return for void methods

2014-03-27 Thread Eirik Lygre
On Thu, Mar 27, 2014 at 5:35 PM, Jochen Theodorou wrote: > Am 26.03.2014 16:51, schrieb Guy Steele: > [...] > > I am wholeheartedly in favor of allowing "chaining" of dotted expressions >> such as >> >> CharBuffer.allocate(26).position(2).put("C").position(25).put("Z") >> > > this also shows

JDK-8038451: Incorrect initialization order of static fields in sun.nio.cs.ext.JISAutoDetect$Decoder

2014-03-27 Thread Mandy Chung
This fixes the regression introduced by JDK-8038177 in which the osName field should be initialized before it's accessed in the class static initializer. https://bugs.openjdk.java.net/browse/JDK-8038451 Webrev at: http://cr.openjdk.java.net/~mchung/jdk9/webrevs/8038451/webrev.00/ Thanks Mandy

Re: Implicit 'this' return for void methods

2014-03-27 Thread Jochen Theodorou
Am 27.03.2014 20:22, schrieb Steven Schlansker: On Mar 27, 2014, at 9:35 AM, Jochen Theodorou wrote: Am 26.03.2014 16:51, schrieb Guy Steele: [...] I am wholeheartedly in favor of allowing “chaining” of dotted expressions such as CharBuffer.allocate(26).position(2).put("C").position(25

Re: Implicit 'this' return for void methods

2014-03-27 Thread Remi Forax
On 03/27/2014 08:22 PM, Steven Schlansker wrote: On Mar 27, 2014, at 9:35 AM, Jochen Theodorou wrote: Am 26.03.2014 16:51, schrieb Guy Steele: [...] I am wholeheartedly in favor of allowing “chaining” of dotted expressions such as CharBuffer.allocate(26).position(2).put("C").position(25

Re: RFR(S) : 8038186 : [TESTBUG] improvements of test j.l.i.MethodHandles

2014-03-27 Thread Igor Ignatyev
After an offline conversation w/ VladimirI, I've done several changes: - placed all classes into one file (but I don't like it) - changed package name - extracted creating tests code from test execution code I hope the code's still quite readable and understandable. Also I've added array return

Re: Implicit 'this' return for void methods

2014-03-27 Thread Steven Schlansker
On Mar 27, 2014, at 9:35 AM, Jochen Theodorou wrote: > Am 26.03.2014 16:51, schrieb Guy Steele: > [...] >> I am wholeheartedly in favor of allowing “chaining” of dotted expressions >> such as >> >>CharBuffer.allocate(26).position(2).put("C").position(25).put("Z”) > > this also shows a pot

Re: RFR(S): 8038233 : Fix unsafe strcpy in Java_sun_tools_attach_{Aix, Bsd, Linux}VirtualMachine_connect()

2014-03-27 Thread Alan Bateman
On 27/03/2014 18:08, Volker Simonis wrote: Hi, a security audit for the PPC64/AIX port revealed an unsecure useage of 'strcpy' in Java_sun_tools_attach_AixVirtualMachine_connect(). Because the same coding is also used in the Linux and BSD implementations, the following change fixes them all toge

RFR(S): 8038233 : Fix unsafe strcpy in Java_sun_tools_attach_{Aix, Bsd, Linux}VirtualMachine_connect()

2014-03-27 Thread Volker Simonis
Hi, a security audit for the PPC64/AIX port revealed an unsecure useage of 'strcpy' in Java_sun_tools_attach_AixVirtualMachine_connect(). Because the same coding is also used in the Linux and BSD implementations, the following change fixes them all together: http://cr.openjdk.java.net/~simonis/we

Re: Implicit 'this' return for void methods

2014-03-27 Thread Jochen Theodorou
Am 26.03.2014 16:51, schrieb Guy Steele: [...] I am wholeheartedly in favor of allowing “chaining” of dotted expressions such as CharBuffer.allocate(26).position(2).put("C").position(25).put("Z”) this also shows a potential point of critic this proposal will have to find arguments agains

Re: Implicit 'this' return for void methods

2014-03-27 Thread Ulf Zibis
Hi Guy and Paul, thanks for liking my proposal. What can we do to convince the "officials" ? -Ulf Am 26.03.2014 17:20, schrieb Paul Benedict: It would be nice to make this language change. In the past years, it's pretty clear many JSR EE spec leads have gone on to make their APIs return the

Re: Improve timezone mapping for AIX platform

2014-03-27 Thread Masayoshi Okutsu
Hi Volker, You are right. The `tz' value needs to be given to getPlatformTimeZoneID() or the getenv() call should be moved to the function. Your mapPlatformToJavaTimzone(const char* tz) sounds good to me. In any case TimeZone_md.c has become too messy by accumulating platform/release-specifi

Re: RFR [8038333] java/lang/ref/EarlyTimeout.java failed

2014-03-27 Thread Ivan Gerasimov
On 27.03.2014 18:00, Peter Levart wrote: On 03/27/2014 02:36 PM, Ivan Gerasimov wrote: Thank you Peter! There could be a little delay (say half the timeout: 500ms) specified after main thread returns from the startedSignal.await(); and before setting referent = null; and doing System.gc(). T

Re: RFR [8038333] java/lang/ref/EarlyTimeout.java failed

2014-03-27 Thread Peter Levart
On 03/27/2014 02:36 PM, Ivan Gerasimov wrote: Thank you Peter! There could be a little delay (say half the timeout: 500ms) specified after main thread returns from the startedSignal.await(); and before setting referent = null; and doing System.gc(). This would decrease the chance that the ref

Re: RFR [8038333] java/lang/ref/EarlyTimeout.java failed

2014-03-27 Thread Ivan Gerasimov
Thank you Peter! There could be a little delay (say half the timeout: 500ms) specified after main thread returns from the startedSignal.await(); and before setting referent = null; and doing System.gc(). This would decrease the chance that the reference is enqueued before EarlyTimeout threads

Re: RFR [8038333] java/lang/ref/EarlyTimeout.java failed

2014-03-27 Thread Peter Levart
Hi Ivan, On 03/27/2014 08:26 AM, Ivan Gerasimov wrote: David, Mandy, thank you for comments! Here's what we want to achieve in the test: Two EarlyTimeout child threads should both be blocked in remove(TIMEOUT) at the moment the weakReference gets enqueued. This is the situation, when the bug

Re: RFR: 8000975: (process) Merge UNIXProcess.java.bsd & UNIXProcess.java.linux (& .solaris & .aix)

2014-03-27 Thread Volker Simonis
Hi Peter, thanks for applying these changes to the AIX files as well. With the additional line: if (osName.equals("AIX")) { return AIX; } in Os.get() your change compiles cleanly on AIX and runs the java/lang/ProcessBuilder tests without any errors. So from an AIX perspective, thum

Re: RFR [8038333] java/lang/ref/EarlyTimeout.java failed

2014-03-27 Thread Ivan Gerasimov
David, Mandy, thank you for comments! Here's what we want to achieve in the test: Two EarlyTimeout child threads should both be blocked in remove(TIMEOUT) at the moment the weakReference gets enqueued. This is the situation, when the bug 6853696 manifests itself. If we made sure the weakRefere