Re: RFR: 8342650: Move getChars to DecimalDigits

2024-11-11 Thread David Holmes
On Tue, 12 Nov 2024 01:25:16 GMT, Shaojin Wen wrote: > This PR is a resubmission after PR #21593 was rolled back, and the unsafe > offset overflow issue has been fixed. > > Move getChars methods of StringLatin1 and StringUTF16 to DecimalDigits to > reduce duplication > > HexDigits and OctalDi

RFR: 8342650: Move getChars to DecimalDigits

2024-11-11 Thread Shaojin Wen
This PR is a resubmission after PR #21593 was rolled back, and the unsafe offset overflow issue has been fixed. Move getChars methods of StringLatin1 and StringUTF16 to DecimalDigits to reduce duplication HexDigits and OctalDigits also include getCharsLatin1 and getCharsUTF16 Putting these two

Re: RFR: 8342650: Move getChars to DecimalDigits [v4]

2024-11-11 Thread Shaojin Wen
On Sun, 10 Nov 2024 08:58:18 GMT, Shaojin Wen wrote: >> Move getChars methods of StringLatin1 and StringUTF16 to DecimalDigits to >> reduce duplication >> >> 1. HexDigits and OctalDigits also include getCharsLatin1 and getCharsUTF16 >> 2. Putting these two methods into DecimalDigits can avoid t

Re: RFR: 8342650: Move getChars to DecimalDigits [v4]

2024-11-11 Thread Chen Liang
On Sun, 10 Nov 2024 08:58:18 GMT, Shaojin Wen wrote: >> Move getChars methods of StringLatin1 and StringUTF16 to DecimalDigits to >> reduce duplication >> >> 1. HexDigits and OctalDigits also include getCharsLatin1 and getCharsUTF16 >> 2. Putting these two methods into DecimalDigits can avoid t

Re: RFR: 8342650: Move getChars to DecimalDigits [v4]

2024-11-11 Thread Alan Bateman
On Sun, 10 Nov 2024 08:58:18 GMT, Shaojin Wen wrote: >> Move getChars methods of StringLatin1 and StringUTF16 to DecimalDigits to >> reduce duplication >> >> 1. HexDigits and OctalDigits also include getCharsLatin1 and getCharsUTF16 >> 2. Putting these two methods into DecimalDigits can avoid t

Re: RFR: 8342650: Move getChars to DecimalDigits [v4]

2024-11-11 Thread Tobias Hartmann
On Sun, 10 Nov 2024 08:58:18 GMT, Shaojin Wen wrote: >> Move getChars methods of StringLatin1 and StringUTF16 to DecimalDigits to >> reduce duplication >> >> 1. HexDigits and OctalDigits also include getCharsLatin1 and getCharsUTF16 >> 2. Putting these two methods into DecimalDigits can avoid t

Re: RFR: 8342650: Move getChars to DecimalDigits [v4]

2024-11-11 Thread Shaojin Wen
On Sun, 20 Oct 2024 17:33:09 GMT, j3graham wrote: >> Shaojin Wen has updated the pull request incrementally with one additional >> commit since the last revision: >> >> add benchmark > > src/java.base/share/classes/java/math/BigDecimal.java line 4216: > >> 4214: // Get the significan

Re: RFR: 8342650: Move getChars to DecimalDigits [v4]

2024-11-10 Thread Shaojin Wen
On Sun, 10 Nov 2024 08:58:18 GMT, Shaojin Wen wrote: >> Move getChars methods of StringLatin1 and StringUTF16 to DecimalDigits to >> reduce duplication >> >> 1. HexDigits and OctalDigits also include getCharsLatin1 and getCharsUTF16 >> 2. Putting these two methods into DecimalDigits can avoid t

Re: RFR: 8342650: Move getChars to DecimalDigits [v4]

2024-11-10 Thread Chen Liang
On Sun, 10 Nov 2024 08:58:18 GMT, Shaojin Wen wrote: >> Move getChars methods of StringLatin1 and StringUTF16 to DecimalDigits to >> reduce duplication >> >> 1. HexDigits and OctalDigits also include getCharsLatin1 and getCharsUTF16 >> 2. Putting these two methods into DecimalDigits can avoid t

Re: RFR: 8342650: Move getChars to DecimalDigits [v4]

2024-11-10 Thread Shaojin Wen
> Move getChars methods of StringLatin1 and StringUTF16 to DecimalDigits to > reduce duplication > > 1. HexDigits and OctalDigits also include getCharsLatin1 and getCharsUTF16 > 2. Putting these two methods into DecimalDigits can avoid the need to expose > them in JavaLangAccess > 3. Eliminate d

Re: RFR: 8342650: Move getChars to DecimalDigits [v3]

2024-11-05 Thread Shaojin Wen
> Move getChars methods of StringLatin1 and StringUTF16 to DecimalDigits to > reduce duplication > > 1. HexDigits and OctalDigits also include getCharsLatin1 and getCharsUTF16 > 2. Putting these two methods into DecimalDigits can avoid the need to expose > them in JavaLangAccess > 3. Eliminate d

Re: RFR: 8342650: Move getChars to DecimalDigits [v2]

2024-11-05 Thread Shaojin Wen
On Wed, 6 Nov 2024 01:44:38 GMT, Chen Liang wrote: >> Shaojin Wen has updated the pull request with a new target base due to a >> merge or a rebase. The incremental webrev excludes the unrelated changes >> brought in by the merge/rebase. The pull request contains 11 additional >> commits since

Re: RFR: 8342650: Move getChars to DecimalDigits [v2]

2024-11-05 Thread Chen Liang
On Tue, 5 Nov 2024 15:47:00 GMT, Shaojin Wen wrote: >> Move getChars methods of StringLatin1 and StringUTF16 to DecimalDigits to >> reduce duplication >> >> 1. HexDigits and OctalDigits also include getCharsLatin1 and getCharsUTF16 >> 2. Putting these two methods into DecimalDigits can avoid th

Re: RFR: 8342650: Move getChars to DecimalDigits [v2]

2024-11-05 Thread Shaojin Wen
> Move getChars methods of StringLatin1 and StringUTF16 to DecimalDigits to > reduce duplication > > 1. HexDigits and OctalDigits also include getCharsLatin1 and getCharsUTF16 > 2. Putting these two methods into DecimalDigits can avoid the need to expose > them in JavaLangAccess > 3. Eliminate d

Re: RFR: 8342650: Move getChars to DecimalDigits

2024-10-20 Thread Shaojin Wen
On Sun, 20 Oct 2024 17:33:09 GMT, j3graham wrote: >> Move getChars methods of StringLatin1 and StringUTF16 to DecimalDigits to >> reduce duplication >> >> 1. HexDigits and OctalDigits also include getCharsLatin1 and getCharsUTF16 >> 2. Putting these two methods into DecimalDigits can avoid the

Re: RFR: 8342650: Move getChars to DecimalDigits

2024-10-20 Thread j3graham
On Sun, 20 Oct 2024 00:19:25 GMT, Shaojin Wen wrote: > Move getChars methods of StringLatin1 and StringUTF16 to DecimalDigits to > reduce duplication > > 1. HexDigits and OctalDigits also include getCharsLatin1 and getCharsUTF16 > 2. Putting these two methods into DecimalDigits can avoid the ne

RFR: 8342650: Move getChars to DecimalDigits

2024-10-20 Thread Shaojin Wen
Move getChars methods of StringLatin1 and StringUTF16 to DecimalDigits to reduce duplication 1. HexDigits and OctalDigits also include getCharsLatin1 and getCharsUTF16 2. Putting these two methods into DecimalDigits can avoid the need to expose them in JavaLangAccess 3. Eliminate duplicate code