Hello, Ivan! > The check > if (((n << i) & 0x8000_0000) != 0) { > might be written as > if ((n << i) < 0 ) { > to save one bit-wise operation and avoid using extra constant.
Nice catch, thanks! When I switch my mind to bitwise thinking mode, I forget about normal arithmetic properties like sign :-) Webrev is posted: http://mail.openjdk.java.net/pipermail/core-libs-dev/2018-December/057038.html With best regards Tagir Valeev.