On Thu, 10 Sep 2026 11:09:10 GMT, Stefan Karlsson <[email protected]> wrote:

>> Ioi Lam has updated the pull request incrementally with one additional 
>> commit since the last revision:
>> 
>>   Restored ValuePayloadContext::klass() and added test case with abstract 
>> value class
>
> src/hotspot/share/runtime/fieldDescriptor.hpp line 172:
> 
>> 170:     _klass(klass), _offset_in_obj(offset_in_obj) {
>> 171:     precond(klass != nullptr);
>> 172:     precond(offset_in_obj > 0);
> 
> Putting the initialization list on the same indentation makes the flow harder 
> to read. In other parts of the JVM we take extra care to not do this by doing 
> either of:
> 
>   ValuePayloadContext(ValueKlass* klass, int offset_in_obj) :
>       _klass(klass), _offset_in_obj(offset_in_obj) {
>     precond(klass != nullptr);
>     precond(offset_in_obj > 0);
> 
> or
> 
>   ValuePayloadContext(ValueKlass* klass, int offset_in_obj)
>     : _klass(klass), _offset_in_obj(offset_in_obj) {
>     precond(klass != nullptr);
>     precond(offset_in_obj > 0);
> 
> or
> 
>   ValuePayloadContext(ValueKlass* klass, int offset_in_obj) :
>     _klass(klass), _offset_in_obj(offset_in_obj)
> {
>     precond(klass != nullptr);
>     precond(offset_in_obj > 0);
> 
> Maybe use one of these here?

Fixed.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/32565#discussion_r3981566993

Reply via email to