On Wed, 20 Aug 2025 15:41:25 GMT, Shaojin Wen <[email protected]> wrote:
>> Since FloatToDecimal and DoubleToDecimal are used in Float.toString and
>> Double.toString, some code in FloatingDecimal is not used.
>>
>> This PR refactors `FloatingDecimal` and `DigitList` to improve efficiency
>> and reduce code duplication.
>>
>> Key changes:
>> * Convert internal digit storage from `char[]` to `byte[]` for reduced
>> memory footprint.
>> * Remove unused code and methods that are no longer needed.
>
> Shaojin Wen has updated the pull request incrementally with one additional
> commit since the last revision:
>
> without copy digits, from @j3graham
src/java.base/share/classes/jdk/internal/math/FloatingDecimal.java line 105:
> 103: */
> 104: public interface BinaryToASCIIConverter {
> 105: int getChars(byte[] result);
Can you add javadoc comments to this new method, like what is the return value,
and any caution for the size of the result array before passing etc.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/23311#discussion_r2291159227