[OpenJDK 2D-Dev] RFR: 8252999: Cleanup: replace .equals("") with .isEmpty() within all codebase

Dmitriy Dumanskiy github.com+1536494+doom369 at openjdk.java.net
Fri Sep 18 11:07:46 UTC 2020


On Fri, 18 Sep 2020 02:48:15 GMT, Stuart Marks <smarks at openjdk.org> wrote:

>> Our local Santuario maintainer says:
>> 
>> In general, changes to Apache Santuario should also be made at Apache so we stay in sync.
>
> Hi @doom369, I hope we didn't end up wasting too much of your time with this. I wanted to respond to a comment you made
> earlier in this PR,
>> I have in mind dozens of improvements all over the code like this one.
> 
> It's hard to see, but as you discovered, the JDK has different groups of people maintaining different areas, and
> sometimes there are hidden constraints on those different areas, for example, to avoid divergence with upstream source
> bases. And as you discovered, sometimes those source bases might need to maintain compatibility with an older JDK ...
> so we don't want to update this code even though it's IN the JDK.  Those kind of constraints generally don't apply to
> code in the java.base module, since there's nothing upstream of it, and by definition it cannot depend on anything
> outside the JDK. Generally -- though there are exceptions -- we're more receptive to keeping stuff in java.base (and
> sometimes related modules close to the core) on the latest and greatest stuff. There are some constraints, however.
> There are some things we can't use too early during initialization of the JDK, such as lambdas. Also, there is some
> code lurking around that is sometimes executed by the boot JDK, which is typically one release behind. (This is
> definitely the case for tools like javac, but I think it might also apply to some things in base.)  Anyway, if you'd
> like to pursue some of these improvements, drop a note to core-libs-dev at openjdk and we can talk about it.  Thanks.

@stuart-marks thanks. Sure, I understand that maintaining OpenJDK is not a simple task. I thought as change is super
simple without any side effects it can go through. But I was wrong. That's fine. I'll focus on `java.base` when I have
some free time.

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

PR: https://git.openjdk.java.net/jdk/pull/29


More information about the 2d-dev mailing list