Integrated: 8242451: ensure semantics of non-capturing lambdas are preserved independent of execution mode

2020-09-25 Thread Gilles Duboscq
On Wed, 9 Sep 2020 08:18:11 GMT, Gilles Duboscq wrote: > [JDK-8232806](https://bugs.openjdk.java.net/browse/JDK-8232806) introduced the > jdk.internal.lambda.disableEagerInitialization system property to be able to > disable eager initialization of lambda > classes. This w

Re: RFR: 8242451: ensure semantics of non-capturing lambdas are preserved independent of execution mode [v4]

2020-09-22 Thread Gilles Duboscq
On Tue, 22 Sep 2020 18:17:49 GMT, Mandy Chung wrote: >> Gilles Duboscq has refreshed the contents of this pull request, and previous >> commits have been removed. The incremental >> views will show differences compared to the previous content of the PR. The >> pull

Re: RFR: 8242451: ensure semantics of non-capturing lambdas are preserved independent of execution mode [v4]

2020-09-22 Thread Gilles Duboscq
agerInitialization` shouldn't > influence the singleton vs. fresh instance > behaviour of lambdas in either direction. Gilles Duboscq has refreshed the contents of this pull request, and previous commits have been removed. The incremental views will show differences compared to the previous c

Re: RFR: 8242451: ensure semantics of non-capturing lambdas are preserved independent of execution mode [v3]

2020-09-11 Thread Gilles Duboscq
On Thu, 10 Sep 2020 16:34:02 GMT, Mandy Chung wrote: >> Gilles Duboscq has updated the pull request incrementally with one >> additional commit since the last revision: >> >> Remove disableEagerInitialization concerns from BridgeMethod.java > > tes

Re: RFR: 8242451: ensure semantics of non-capturing lambdas are preserved independent of execution mode [v3]

2020-09-11 Thread Gilles Duboscq
agerInitialization` shouldn't > influence the singleton vs. fresh instance > behaviour of lambdas in either direction. Gilles Duboscq has updated the pull request incrementally with one additional commit since the last revision: Remove disableEagerInitialization concerns from BridgeMet

Re: RFR: 8242451: ensure semantics of non-capturing lambdas are preserved independent of execution mode [v2]

2020-09-10 Thread Gilles Duboscq
On Thu, 10 Sep 2020 11:50:04 GMT, Gilles Duboscq wrote: >> It's a good suggestion as `disableEagerInitialization` support is not part >> of javac. > > OK makes sense. I guess it's still good to clean the test comments of the old > `disableEagerInitialization` references?

Re: RFR: 8242451: ensure semantics of non-capturing lambdas are preserved independent of execution mode [v2]

2020-09-10 Thread Gilles Duboscq
agerInitialization` shouldn't > influence the singleton vs. fresh instance > behaviour of lambdas in either direction. Gilles Duboscq has updated the pull request incrementally with three additional commits since the last revision: - Remove extra field test from LambdaTest6 - Wrap

Re: RFR: 8242451: ensure semantics of non-capturing lambdas are preserved independent of execution mode [v2]

2020-09-10 Thread Gilles Duboscq
On Wed, 9 Sep 2020 16:36:43 GMT, Mandy Chung wrote: >> Gilles Duboscq has updated the pull request incrementally with three >> additional commits since the last revision: >> >> - Remove extra field test from LambdaTest6 >> - Wrap long lines >> - Add de

Re: RFR: 8242451: ensure semantics of non-capturing lambdas are preserved independent of execution mode

2020-09-10 Thread Gilles Duboscq
On Wed, 9 Sep 2020 16:39:25 GMT, Mandy Chung wrote: >> test/langtools/tools/javac/lambda/lambdaExpression/LambdaTest6.java line 29: >> >>> 27: * @summary Add lambda tests >>> 28: * Test bridge methods for certain SAM conversions >>> 29: * Test the set of generate fields >> >> I would

RFR: 8242451: ensure semantics of non-capturing lambdas are preserved independent of execution mode

2020-09-09 Thread Gilles Duboscq
[JDK-8232806](https://bugs.openjdk.java.net/browse/JDK-8232806) introduced the jdk.internal.lambda.disableEagerInitialization system property to be able to disable eager initialization of lambda classes. This was necessary to prevent side effects of class initializers triggered by such

Re: RFR: JDK-8242451 : ensure semantics of non-capturing lambdas are preserved independent of execution mode

2020-08-26 Thread Gilles Duboscq
Hi Mandy, Thanks for your review. I have added a test as you suggested and switched to `.descriptorString()`. https://cr.openjdk.java.net/~gdub/8242451/webrev.2/ Gilles On 25/08/2020 19:23, Mandy Chung wrote: On 8/25/20 3:16 AM, Gilles Duboscq wrote: Since this patch caches a singleton

Re: RFR: JDK-8242451 : ensure semantics of non-capturing lambdas are preserved independent of execution mode

2020-08-25 Thread Gilles Duboscq
this patch is being discussed? Gilles Mandy On 6/23/20 11:08 AM, Gilles Duboscq wrote: In 8232806, a system property was introduce to disable eager initialization of the classes generated by the InnerClassLambdaMetafactory (`jdk.internal.lambda.disableEagerInitialization`). However, w

RFR: JDK-8242451 : ensure semantics of non-capturing lambdas are preserved independent of execution mode

2020-06-23 Thread Gilles Duboscq
In 8232806, a system property was introduce to disable eager initialization of the classes generated by the InnerClassLambdaMetafactory (`jdk.internal.lambda.disableEagerInitialization`). However, when `disableEagerInitialization` is true, even for non-capturing lambdas, the capturing lambda