RFR: 8369828: Generalize share/utilities/bytes.hpp [v2]

Justin King jcking at openjdk.org
Thu Oct 16 13:44:47 UTC 2025


On Wed, 15 Oct 2025 17:33:50 GMT, Kim Barrett <kbarrett at openjdk.org> wrote:

>> This is more just for language correctness, in case somebody tries to use this with a class or struct that is non-trivial.
>
> I agree the `std::is_trivially_copyable` test should be there.
> It's the `std::is_trivially_default_constructible` test that I'm questioning. I don't see anything in this code
> that has that as a requirement. So I find it confusing.

I think `std::is_trivially_copyable` should be enough, on second look. Removed it.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/27801#discussion_r2435958855


More information about the hotspot-dev mailing list