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

test failing due to self-assign-overloaded

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: P4
    • Resolution: Fixed
    • Affects Version/s: 11, 12, 13
    • Fix Version/s: 13
    • Component/s: infrastructure
    • Labels:
    • Subcomponent:
    • Resolved In Build:
      b20

      Description

      building on macosx 10.14.4 using Xcode 10.2.1 fails:

      /Users/johan/openjdk/jdk/test/hotspot/gtest/classfile/test_symbolTable.cpp:62:6: error: explicitly assigning value of variable of type 'TempNewSymbol' to itself [-Werror,-Wself-assign-overloaded]
        s1 = s1; // self assignment
        ~~ ^ ~~
      1 error generated.

      The following patch fixes this:

      diff -r 0907dce4b90e make/hotspot/lib/CompileGtest.gmk
      --- a/make/hotspot/lib/CompileGtest.gmk Thu May 02 22:52:51 2019 +0100
      +++ b/make/hotspot/lib/CompileGtest.gmk Fri May 03 14:39:01 2019 +0200
      @@ -76,7 +76,7 @@
           DISABLED_WARNINGS_gcc := $(DISABLED_WARNINGS_gcc) \
               undef, \
           DISABLED_WARNINGS_clang := $(DISABLED_WARNINGS_clang) \
      - undef switch format-nonliteral tautological-undefined-compare, \
      + undef switch format-nonliteral tautological-undefined-compare self-assign-overloaded, \
           DISABLED_WARNINGS_solstudio := $(DISABLED_WARNINGS_solstudio) \
               identexpected, \
           DISABLED_WARNINGS_microsoft := $(DISABLED_WARNINGS_microsoft) \

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              erikj Erik Joelsson
              Reporter:
              jvos Johan Vos
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: