java.lang.IllegalAccessError: tried to access method java.lang.Object.clone()Ljava/lang/Object; from class TestCloneInterface

JDK Bug System | Balchandra Vaidya | 3 years ago
  1. 0

    [JDK-8026845] Exception in thread "main" java.lang.IllegalAccessError: tried to access method java.lang.Object.clone()Ljava/lang/Object - Java Bug System

    java.net | 1 year ago
    java.lang.IllegalAccessError: tried to access method java.lang.Object.clone()Ljava/lang/Object; from class TestCloneInterface
  2. 0

    Apache reported the following regression issue with jdk 8 ea b111: Exception in thread "main" java.lang.IllegalAccessError: tried to access method java.lang.Object.clone()Ljava/lang/Object; from class TestCloneInterface at TestCloneInterface.test(TestCloneInterface.java:15) at TestCloneInterface.main(TestCloneInterface.java:19) The testcase TestCloneInterface.java is attached. Testcase appear to pass with jdk 8 ea b109 (and b110). Below is email from Apache: ---------------------------------------------------------------------------------------------------- Hi, I was able to reproduce with a simple test case that emulates the UIMA code. See attached test case, just compile it with any JDK and run with b111: With Java 7 or JDK8b109: > javac TestCloneInterface.java > java TestCloneInterface > With JDK8b111: > java TestCloneInterface Exception in thread "main" java.lang.IllegalAccessError: tried to access method java.lang.Object.clone()Ljava/lang/Object; from class TestCloneInterface at TestCloneInterface.test(TestCloneInterface.java:15) at TestCloneInterface.main(TestCloneInterface.java:19) > The bug happens if the clone() method is declared in a superinterface only. Without the additional interface inbetween, test passes. Instead of the real interface (the "o" local variable, which is of type "FoobarIntf") it checks access flags on "this", which is of type "TestCloneInterface". Uwe ----- Uwe Schindler uschindler@apache.org Apache Lucene PMC Chair / Committer Bremen, Germany http://lucene.apache.org/ -----------------------------------------------------------------------------------------------------------------

    JDK Bug System | 3 years ago | Balchandra Vaidya
    java.lang.IllegalAccessError: tried to access method java.lang.Object.clone()Ljava/lang/Object; from class TestCloneInterface
  3. 0

    tried to access method java.lang.Object.clone()Ljava/lang/Object; from class ar.com.fdvs.dj.util.Utils

    Stack Overflow | 3 years ago | Nauman Rafique
    java.lang.IllegalAccessError: tried to access method java.lang.Object.clone()Ljava/lang /Object; from class ar.com.fdvs.dj.util.Utils
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    install.db.schema: IllegalAccessError

    xplanner | 1 decade ago | n-space
    java.lang.IllegalAccessError: tried to access method java.lang.Object.clone()Ljava/lang/Object; from class org.apache.xerces.impl.XMLEntityManager
  6. 0

    Cloneable

    Coderanch | 3 years ago | meeta gaur
    java.lang.IllegalAccessError: tried to access method java.lang.Object.clone()Ljava/lang/Object; from class Test

    Not finding the right solution?
    Take a tour to get the most out of Samebug.

    Tired of useless tips?

    Automated exception search integrated into your IDE

    Root Cause Analysis

    1. java.lang.IllegalAccessError

      tried to access method java.lang.Object.clone()Ljava/lang/Object; from class TestCloneInterface

      at TestCloneInterface.test()
    2. Unknown
      TestCloneInterface.main
      1. TestCloneInterface.test(TestCloneInterface.java:15)
      2. TestCloneInterface.main(TestCloneInterface.java:19)
      2 frames