Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8245959

Extend String concat testing to account for folded constants

XMLWordPrintable

    • Icon: Enhancement Enhancement
    • Resolution: Fixed
    • Icon: P4 P4
    • 15
    • None
    • core-libs
    • None

      Since JDK-8222852 the default String concat strategy aggressively folds string constants into prepender method handles, which means an expression like foo + bar and one like "x" + foo + "y" + bar + "z" will have similar shape, but take slightly different paths through generated code. This could mean slightly reduced code coverage in tests like String/concat/ImplicitStringConcatShapes. Consider extending this test to explicitly include surrounding String constants, which should cover more cases and put a bit more stress on the implementation strategy.

            redestad Claes Redestad
            redestad Claes Redestad
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: