On Wed, 19 Jan 2022 15:53:57 GMT, Daniel Fuchs <dfu...@openjdk.org> wrote:
>> IIRC this was a request from an earlier review. (long being the standard >> throughout other new public apis) I'm happy with either, but int does avoid >> the trouble of casting. > > Well I guess the request was "why not use long everywhere to avoid casting to > int" ;-) > But I'm happy with either too - as long as the place where you have a long > (e.g obtained by substracting two nano times) and call a method that takes an > int has the proper guards in place, and either assert/throws/floor or ceil if > the assumptions are not met - provided that a comment explains why that > particular alternative is selected. Good point. I think its better to deal with the casts at the edges since the timeout handling will use long by default. ------------- PR: https://git.openjdk.java.net/jdk/pull/6568