On Mon, 28 Apr 2025 11:29:46 GMT, Maurizio Cimadamore
wrote:
>> Yeah, that was what I was thinking too.
>
> Note - the JEP uses the word `content` (which has, I think, been "vetted").
> So I believe it would be ok (and, preferrable) to leave it as is. Unless you
> are suggesting to also update
On Wed, 23 Apr 2025 07:38:00 GMT, Viktor Klang wrote:
>> I asked around/looked this up, and it seems 'contents' would be more correct
>> here, since a StableValue is primarily a container of things (you put things
>> into it, get things out).
>
> Yeah, that was what I was thinking too.
Note -
On Thu, 3 Apr 2025 01:19:18 GMT, Chen Liang wrote:
>> Seconded
>
> I personally think this is more of an implementation artifact for
> `StableValue::supplier` and doesn't merit its own API (as no other
> StableValue API utilizes the object monitor of a StableValue), but maybe we
> can adjust t
On Fri, 18 Apr 2025 14:17:37 GMT, Jorn Vernee wrote:
>> I'm definitely not an expert here, so I'll defer to someone more
>> knowledgable :)
>
> I asked around/looked this up, and it seems 'contents' would be more correct
> here, since a StableValue is primarily a container of things (you put th
On Thu, 3 Apr 2025 09:47:15 GMT, Viktor Klang wrote:
>> I think it should be "content" as only one element can be set?
>
> I'm definitely not an expert here, so I'll defer to someone more knowledgable
> :)
I asked around/looked this up, and it seems 'contents' would be more correct
here, since
On Thu, 3 Apr 2025 14:26:15 GMT, Quan Anh Mai wrote:
>> I don't think we should promise this even though it might be the case.
>
> What is the benefit of not promising it? Promising helps the supplier to have
> a well-defined order of execution. Furthermore, even if you do not promise
> it, it
On Wed, 2 Apr 2025 14:04:52 GMT, Alan Bateman wrote:
>> Per Minborg has updated the pull request incrementally with one additional
>> commit since the last revision:
>>
>> Add info that Map#values and Map#entrySet are stable
>
> src/java.base/share/classes/java/lang/StableValue.java line 649:
On Thu, 3 Apr 2025 08:22:47 GMT, Per Minborg wrote:
> "A stable value is a holder of content that can be lazily computed at most
> once"
I'd replace `computed` with `set` (as that's the term we use in the API).
-
PR Review Comment: https://git.openjdk.org/jdk/pull/23972#discussion
> Implement JEP 502.
>
> The PR passes tier1-tier3 tests.
Per Minborg has updated the pull request incrementally with one additional
commit since the last revision:
Add info that Map#values and Map#entrySet are stable
-
Changes:
- all: https://git.openjdk.org/jdk/pull/23972/fi
On Thu, 3 Apr 2025 08:39:47 GMT, Per Minborg wrote:
>> src/java.base/share/classes/java/lang/StableValue.java line 377:
>>
>>> 375: *
>>> 376: * Thread Safety
>>> 377: * The content of a stable value is guaranteed to be set at most once.
>>> If competing
>>
>> Suggestion:
>>
>> * The cont
On Wed, 2 Apr 2025 14:42:17 GMT, Viktor Klang wrote:
>> Per Minborg has updated the pull request incrementally with one additional
>> commit since the last revision:
>>
>> Add info that Map#values and Map#entrySet are stable
>
> src/java.base/share/classes/java/lang/StableValue.java line 567:
On Thu, 3 Apr 2025 12:54:01 GMT, Per Minborg wrote:
>> src/java.base/share/classes/java/lang/StableValue.java line 402:
>>
>>> 400: * race. Since stable functions and stable collections are built on
>>> top of
>>> 401: * {@linkplain StableValue#orElseSet(Supplier) orElseSet()} they too
>>> a
On Thu, 3 Apr 2025 12:07:03 GMT, Maurizio Cimadamore
wrote:
>> There is a problem here: If we say it is "immutable content" people might
>> think that passing mutable data makes it immutable. If we say it is
>> "shallowly immutable content" people might think they cannot pass immutable
>> dat
On Wed, 2 Apr 2025 18:46:06 GMT, Viktor Klang wrote:
>> Per Minborg has updated the pull request incrementally with one additional
>> commit since the last revision:
>>
>> Add info that Map#values and Map#entrySet are stable
>
> test/jdk/java/lang/StableValue/StableValueFactoriesTest.java lin
On Wed, 2 Apr 2025 18:49:31 GMT, Viktor Klang wrote:
>> Per Minborg has updated the pull request incrementally with one additional
>> commit since the last revision:
>>
>> Add info that Map#values and Map#entrySet are stable
>
> test/jdk/java/lang/StableValue/StableValueTest.java line 262:
>
On Wed, 2 Apr 2025 19:22:28 GMT, Quan Anh Mai wrote:
>> Per Minborg has updated the pull request incrementally with one additional
>> commit since the last revision:
>>
>> Add info that Map#values and Map#entrySet are stable
>
> src/java.base/share/classes/java/lang/StableValue.java line 402:
On Wed, 2 Apr 2025 14:30:05 GMT, Viktor Klang wrote:
>> Per Minborg has updated the pull request incrementally with one additional
>> commit since the last revision:
>>
>> Add info that Map#values and Map#entrySet are stable
>
> src/java.base/share/classes/java/lang/StableValue.java line 426:
On Wed, 2 Apr 2025 18:42:06 GMT, Viktor Klang wrote:
>> Per Minborg has updated the pull request incrementally with one additional
>> commit since the last revision:
>>
>> Add info that Map#values and Map#entrySet are stable
>
> test/jdk/java/lang/StableValue/StableMapTest.java line 143:
>
>
On Wed, 2 Apr 2025 18:33:39 GMT, Viktor Klang wrote:
>> Per Minborg has updated the pull request incrementally with one additional
>> commit since the last revision:
>>
>> Add info that Map#values and Map#entrySet are stable
>
> test/jdk/java/lang/StableValue/StableFunctionTest.java line 147:
On Wed, 2 Apr 2025 18:33:22 GMT, Viktor Klang wrote:
>> Per Minborg has updated the pull request incrementally with one additional
>> commit since the last revision:
>>
>> Add info that Map#values and Map#entrySet are stable
>
> test/jdk/java/lang/StableValue/StableFunctionTest.java line 136:
On Wed, 2 Apr 2025 18:29:06 GMT, Viktor Klang wrote:
>> Per Minborg has updated the pull request incrementally with one additional
>> commit since the last revision:
>>
>> Add info that Map#values and Map#entrySet are stable
>
> test/jdk/java/lang/StableValue/StableFunctionTest.java line 86:
On Wed, 2 Apr 2025 16:31:03 GMT, Viktor Klang wrote:
>> Per Minborg has updated the pull request incrementally with one additional
>> commit since the last revision:
>>
>> Add info that Map#values and Map#entrySet are stable
>
> src/java.base/share/classes/jdk/internal/lang/stable/StableValue
On Wed, 2 Apr 2025 15:24:47 GMT, Viktor Klang wrote:
>> Per Minborg has updated the pull request incrementally with one additional
>> commit since the last revision:
>>
>> Add info that Map#values and Map#entrySet are stable
>
> src/java.base/share/classes/jdk/internal/lang/stable/StableEnumF
On Wed, 2 Apr 2025 14:24:20 GMT, Viktor Klang wrote:
>> Per Minborg has updated the pull request incrementally with one additional
>> commit since the last revision:
>>
>> Add info that Map#values and Map#entrySet are stable
>
> src/java.base/share/classes/java/lang/StableValue.java line 377:
On Wed, 2 Apr 2025 14:25:45 GMT, Viktor Klang wrote:
>> Per Minborg has updated the pull request incrementally with one additional
>> commit since the last revision:
>>
>> Add info that Map#values and Map#entrySet are stable
>
> src/java.base/share/classes/java/lang/StableValue.java line 384:
On Wed, 2 Apr 2025 14:24:04 GMT, Viktor Klang wrote:
>> Per Minborg has updated the pull request incrementally with one additional
>> commit since the last revision:
>>
>> Add info that Map#values and Map#entrySet are stable
>
> src/java.base/share/classes/java/lang/StableValue.java line 374:
On Wed, 2 Apr 2025 21:37:25 GMT, Maurizio Cimadamore
wrote:
>> Or "observably immutable"? 🤔
>
> or... "immutable"
There is a problem here: If we say it is "immutable content" people might think
that passing mutable data makes it immutable. If we say it is "shallowly
immutable content" people
On Wed, 2 Apr 2025 14:31:46 GMT, Viktor Klang wrote:
>> src/java.base/share/classes/java/lang/StableValue.java line 455:
>>
>>> 453: * provided to the {@link #orElseSet(Supplier)} method.
>>> 454: */
>>> 455: boolean trySet(T content);
>>
>> I assume the intent is that try
On Wed, 2 Apr 2025 14:07:45 GMT, Viktor Klang wrote:
>> src/java.base/share/classes/java/lang/StableValue.java line 50:
>>
>>> 48:
>>> 49: /**
>>> 50: * A stable value is a holder of shallowly immutable content that can
>>> be lazily computed.
>>
>> This reads as if the content can only be s
On Wed, 2 Apr 2025 13:22:44 GMT, Per Minborg wrote:
>> Implement JEP 502.
>>
>> The PR passes tier1-tier3 tests.
>
> Per Minborg has updated the pull request incrementally with one additional
> commit since the last revision:
>
> Add info that Map#values and Map#entrySet are stable
src/java
On Wed, 2 Apr 2025 13:44:47 GMT, Alan Bateman wrote:
>> Per Minborg has updated the pull request incrementally with one additional
>> commit since the last revision:
>>
>> Add info that Map#values and Map#entrySet are stable
>
> src/java.base/share/classes/java/lang/StableValue.java line 455:
On Wed, 2 Apr 2025 13:22:44 GMT, Per Minborg wrote:
>> Implement JEP 502.
>>
>> The PR passes tier1-tier3 tests.
>
> Per Minborg has updated the pull request incrementally with one additional
> commit since the last revision:
>
> Add info that Map#values and Map#entrySet are stable
Thanks f
On Wed, 2 Apr 2025 13:22:44 GMT, Per Minborg wrote:
>> Implement JEP 502.
>>
>> The PR passes tier1-tier3 tests.
>
> Per Minborg has updated the pull request incrementally with one additional
> commit since the last revision:
>
> Add info that Map#values and Map#entrySet are stable
src/java
On Wed, 2 Apr 2025 13:22:44 GMT, Per Minborg wrote:
>> Implement JEP 502.
>>
>> The PR passes tier1-tier3 tests.
>
> Per Minborg has updated the pull request incrementally with one additional
> commit since the last revision:
>
> Add info that Map#values and Map#entrySet are stable
src/java
On Wed, 2 Apr 2025 14:06:22 GMT, Viktor Klang wrote:
>> Per Minborg has updated the pull request incrementally with one additional
>> commit since the last revision:
>>
>> Add info that Map#values and Map#entrySet are stable
>
> src/java.base/share/classes/java/lang/StableValue.java line 50:
On Wed, 2 Apr 2025 13:22:44 GMT, Per Minborg wrote:
>> Implement JEP 502.
>>
>> The PR passes tier1-tier3 tests.
>
> Per Minborg has updated the pull request incrementally with one additional
> commit since the last revision:
>
> Add info that Map#values and Map#entrySet are stable
src/java
On Wed, 2 Apr 2025 13:22:44 GMT, Per Minborg wrote:
>> Implement JEP 502.
>>
>> The PR passes tier1-tier3 tests.
>
> Per Minborg has updated the pull request incrementally with one additional
> commit since the last revision:
>
> Add info that Map#values and Map#entrySet are stable
src/java
On Wed, 2 Apr 2025 13:22:44 GMT, Per Minborg wrote:
>> Implement JEP 502.
>>
>> The PR passes tier1-tier3 tests.
>
> Per Minborg has updated the pull request incrementally with one additional
> commit since the last revision:
>
> Add info that Map#values and Map#entrySet are stable
src/java
38 matches
Mail list logo