On Thu, 20 Aug 2026 05:53:20 GMT, Johan Sjölen <[email protected]> wrote:

>> When creating a new array of type T, the type T should not be initialized. 
>> This is the case for all types (classes and value classes). The reason that 
>> this code was added is probably because in a previous Valhalla model, the VM 
>> filled in a default value for each flattened array element, which 
>> necessitated the initialization of the class.
>> 
>> ---------
>> - [X] I confirm that I make this contribution in accordance with the 
>> [OpenJDK Interim AI Policy](https://openjdk.org/legal/ai).
>
> Johan Sjölen has updated the pull request incrementally with one additional 
> commit since the last revision:
> 
>   Update src/java.base/share/classes/jdk/internal/misc/Unsafe.java
>   
>   Co-authored-by: David Holmes <[email protected]>

Hi,

The discussions regarding documentation of this Unsafe method has gone beyond 
the intent of this PR, which was to fix a bug on the JVM side. I have now 
created a new ticket ( https://bugs.openjdk.org/browse/JDK-8390757 ) for the 
lack of a docstring and removed my docstring from this PR.

-------------

PR Comment: https://git.openjdk.org/jdk/pull/32193#issuecomment-5352995799

Reply via email to