RFR (XS) 8210347 : Combine subsequent calls to Set.contains() and Set.add()
Hello! It's a pico-optimization. In a few places a call to Set.contains() can be merged with the following Set.add(). BUGURL: https://bugs.openjdk.java.net/browse/JDK-8210347 WEBREV: http://cr.openjdk.java.net/~igerasim/8210347/00/webrev/ Would you please help review the trivial fix? -- With kind regards, Ivan Gerasimov
Hello Ivan, This looks all right to me. Thanks, Brian On Sep 11, 2018, at 1:09 PM, Ivan Gerasimov <ivan.gerasimov@oracle.com> wrote:
It's a pico-optimization.
In a few places a call to Set.contains() can be merged with the following Set.add().
BUGURL: https://bugs.openjdk.java.net/browse/JDK-8210347
WEBREV:http://cr.openjdk.java.net/~igerasim/8210347/00/webrev/
Would you please help review the trivial fix?
A meeting of the minds? http://hg.openjdk.java.net/jdk/jdk/rev/745ce8f5efc8 Looks good! On Tue, Sep 11, 2018 at 1:09 PM, Ivan Gerasimov <ivan.gerasimov@oracle.com> wrote:
Hello!
It's a pico-optimization.
In a few places a call to Set.contains() can be merged with the following Set.add().
BUGURL: https://bugs.openjdk.java.net/browse/JDK-8210347
WEBREV: http://cr.openjdk.java.net/~igerasim/8210347/00/webrev/
Would you please help review the trivial fix?
-- With kind regards, Ivan Gerasimov
participants (3)
-
Brian Burkhalter
-
Ivan Gerasimov
-
Martin Buchholz