RFR: 7903727: Remove the reliance on String Templates feature [v5]
Maurizio Cimadamore
mcimadamore at openjdk.org
Tue Jun 4 16:31:40 UTC 2024
On Tue, 4 Jun 2024 10:13:12 GMT, Nizar Benalla <nbenalla at openjdk.org> wrote:
>> This PR aims to replace the usage of string templates with `String::format`, since there will be no string template feature in JDK 23.
>> I tried to keep similar indentation and convert them in-place, to make reviewing the changes easier.
>
> Nizar Benalla has updated the pull request incrementally with one additional commit since the last revision:
>
> Remove space, to not appear in the diff
Overall, it seems to me that we need to decide on a policy on when to use numbering, as the current patch seems inconsistent. I see three options:
1. don't use numbering
2. only use numbering when there are repeated occurrences of same format argument
3. use numbering everywhere
I think (1) is where we started from. The current patch seems to be a mix between (2) and (3). In general, (2) might be enough, as it avoids repetition on very long format calls, while not making readability of simple cases overly complex. But I'm also ok with (3) if we prefer keeping same style for all calls.
-------------
PR Comment: https://git.openjdk.org/jextract/pull/244#issuecomment-2147496012
More information about the jextract-dev
mailing list