On Sun, 5 Feb 2023 18:13:35 GMT, ExE Boss <d...@openjdk.org> wrote:

>> Tagir F. Valeev has updated the pull request incrementally with one 
>> additional commit since the last revision:
>> 
>>   Typo in doc fixed
>
> src/java.base/share/classes/java/lang/Math.java line 2213:
> 
>> 2211:      * @since 21
>> 2212:      */
>> 2213:     public static int clamp(long value, int min, int max) {
> 
> There should probably also be a pure `int` overload:
> 
> public static int clamp(int value, int min, int max)

@ExE-Boss which problem such an overload would solve? It looks like, `int 
clamp(long, int, int)` can be used everywhere where proposed `int clamp(int, 
int, int)` could be useful.

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

PR: https://git.openjdk.org/jdk/pull/12428

Reply via email to