RFR: 8312121: Fix -Wconversion warnings in tribool.hpp [v4]
Coleen Phillimore
coleenp at openjdk.org
Thu Jul 27 12:58:51 UTC 2023
On Tue, 25 Jul 2023 15:16:06 GMT, Coleen Phillimore <coleenp at openjdk.org> wrote:
>> Assigning _value first, and then doing _value | 2 doesn't get -Wconversion warnings. Also, reduced include file inclusion a little.
>> Tested with tier1 on linux-x64-debug, windows-x64-debug, macos-aarch64-debug
>
> Coleen Phillimore has updated the pull request incrementally with one additional commit since the last revision:
>
> Add some more u1 casts to keep Windows compiler happy hopefully.
My first version did the explicit | 2 separately and if you don't like all the casts, I think that's the most explicit version. It sets the value, then sets the top bit that says it's not the default value.
-------------
PR Comment: https://git.openjdk.org/jdk/pull/14892#issuecomment-1653568693
More information about the hotspot-dev
mailing list