Re[2]: RFR(m): 8140281 deprecate Optional.get()

2016-04-28 Thread Victor Polischuk
I am sorry if my comment would be inappropriate, but is there a reason not to introduce "Optional ifAbsent(Runnable emptyAction)" and change signature of ifPresent to "Optional ifPresent(Consumer consumer)"? In that case method chaining would be more natural and it will give a decent way to ha

Re: RFR: 8072379: Implement jdk.Version and jdk.OracleVersion

2016-01-14 Thread Victor Polischuk
Hi Iris, Do you consider an option to let community reuse JDK versioning style for their own purposes. Probably defining an interface with basic default methods which can be extended by various libraries to provide unified way to gather version information from MANIFEST.MF, ClassLoader's jars a

Re: Implicit 'this' return for void methods

2014-03-29 Thread Victor Polischuk
g like: LOG.error("An error occurs: " + e.getMessage()).debug("Print stack trace: ", e); Regards, Victor Polischuk

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

2014-03-27 Thread Victor Polischuk
is implemented). However, I totally agree that the "chaining" feature should be done as a compiler time AST modification to allow using legacy APIs without recompilation and keep byte-code, existing APIs and various conventions untouched. --- Regards, Victor Polischuk --- Orig

Implicit 'this' return for void methods

2014-03-25 Thread Victor Polischuk
e. I have not found any mentions in JEPs and just wonder if the idea is rejected or still somewhere in pipeline for Java 1.x. (or perhaps it is just waiting to be filed by someone in brand new JEP). --- Regards, Victor Polischuk

Re: Memory leak in j.l.ThreadLocal

2013-10-26 Thread Victor Polischuk
r libraries will be used. In their turn lib users do not know details of implementation of a stack they are using. Unfortunately, it is nearly impossible to avoid leaks in the setup and ThreadLocal leaks one of them because (talking of PermGen/Metaspace leaks) it's absolutely unknown to the library when an application/plugin/module is going to be unloaded. Sincerely Yours, Victor Polischuk

Memory leak in j.l.ThreadLocal

2013-10-26 Thread Victor Polischuk
cular references - I believe that the fix should be applied to the issue with ThreadLocal. Please let me know what do you think of it. Sincerely Yours, Victor Polischuk

Re: RFR 4641897: Faster string conversion of large integers

2013-06-20 Thread Victor Polischuk
for (int i=s.length(); i 0) for (int i = digits - s.length(); i > 0; i -= 63) sb.append(i > 63 ? zeros[63] : zeros[i]); Regards, Victor Polischuk --- Original message --- From: "Brian Burkhalter" Date: 19 June 2013, 22:59:03 > Continuing on from this th

Re: Inefficient use StringBuffer or StringBuilder[Optimization|clean-up] {Package: con.sun. * java.lang*}

2013-06-07 Thread Victor Polischuk
Excuse me for asking something stupid but do empty appends in "com.sun.tools.hat.internal.model.JavaValueArray" make any sense? result.append("").append(val); //Victor --- Original message --- From: "Ot�vio Gon�alves de Santana" Date: 7 June 2013, 16:20:02 > Inefficient use StringBuffer

Re[2]: Fw: Generics in enums

2013-05-30 Thread Victor Polischuk
ecify type parameters for each enum value independently. Sincerely yours, Victor Polischuk --- Original message --- From: "Joe Darcy" Date: 30 May 2013, 09:44:57 > Hello Victor, > > On 5/29/2013 11:25 PM, Victor Polischuk wrote: > > Greetings, > > > > I beg

Fw: Generics in enums

2013-05-29 Thread Victor Polischuk
}; private Color(String color) {...} public boolean filter(T pixel) {...} public T make() {...} } //-- Thank you in advance. Sincerely yours, Victor Polischuk

Generics in enums

2013-05-29 Thread Victor Polischuk
e() {...} > }; private Color(String color) {...} > > public boolean filter(T pixel) {...} > > public T make() {...} } > //-- Thank you in advance. > > > Sincerely yours, > Victor Polischuk >