Uploaded image for project: 'Harmony'
  1. Harmony
  2. HARMONY-5181

[ibm vme] Annotated class can't be loaded

Add voteWatch issue
    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Major
    • Resolution: Unresolved
    • None
    • None
    • VM
    • None

    Description

      Consider the following simple test:

      import java.lang.annotation.*;
      public class Test {
      public static void main(String[] args) {
      try

      { Foo.class.getDeclaredAnnotations(); System.out.println("SUCCESS"); }

      catch (Exception e)

      { e.printStackTrace(System.out); }

      }
      }

      @Retention(RetentionPolicy.RUNTIME)
      @interface Ann {}

      @Ann class Foo {}

      Output on RI:

      SUCCESS

      Output on DRLVM:

      SUCCESS

      Output on IBM VME:

      Exception in thread "main" java.lang.ClassFormatError: (/$Proxy0) class name is invalid at offset=0
      at java.lang.reflect.Proxy.defineClassImpl(Native Method)
      at java.lang.reflect.Proxy.getProxyClass(Proxy.java:157)
      at java.lang.reflect.Proxy.newProxyInstance(Proxy.java:21)
      at com.ibm.oti.reflect.AnnotationHelper.getAnnotation(AnnotationHelper.java:34)
      at com.ibm.oti.reflect.AnnotationHelper.getDeclaredAnnotations(AnnotationHelper.java:50)
      at java.lang.Class.getDeclaredAnnotations(Class.java:1458)
      at Test.main(Test.java:6)

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              vmz Vasily Zakharov

              Dates

                Created:
                Updated:

                Slack

                  Issue deployment