RFR: 8292921: Rewrite object field printer [v3]
Stefan Karlsson
stefank at openjdk.org
Fri Aug 26 08:38:41 UTC 2022
On Fri, 26 Aug 2022 01:46:12 GMT, David Holmes <dholmes at openjdk.org> wrote:
>> Stefan Karlsson has updated the pull request incrementally with one additional commit since the last revision:
>>
>> Fix macOS sensitivity to format specifier for jlong
>
> src/hotspot/share/runtime/fieldDescriptor.cpp line 230:
>
>> 228: case T_CHAR: st->print(" (" PTR16_FORMAT ")", obj->char_field(offset())); break;
>> 229: case T_FLOAT: st->print(" (" PTR32_FORMAT ")", obj->int_field(offset())); break;
>> 230: case T_INT: st->print(" (" PTR32_FORMAT ")", obj->int_field(offset())); break;
>
> Should these be collapsed into one case, as implicitly done for long/double?
I see your point. I think I prefer to change the long/double cases to look like the rest of the block of primitives. I think this gets easier to read if we remove that if/else. Take a look and see if you agree.
-------------
PR: https://git.openjdk.org/jdk/pull/10028
More information about the hotspot-dev
mailing list