72e21518bc098f731965d530a82aea38eff807cc
[cacao.git] / tests / regression / jasmin / test_verify_fail_getfield_basic_type_lookup.j
1 .class public test_verify_fail_getfield_basic_type_lookup
2 .super java/lang/Object
3
4 .field public "f" Ljava/lang/String;
5
6 ; ======================================================================
7
8 .method public <init>()V
9    .limit stack 2
10
11    aload_0
12    invokenonvirtual java/lang/Object/<init>()V
13
14    aload_0
15    ldc "test"
16    putfield test_verify_fail_getfield_basic_type_lookup/f Ljava/lang/String;
17
18    return
19 .end method
20
21 ; ======================================================================
22
23 .method public static check(I)V
24         .limit locals 1
25         .limit stack 10
26         getstatic java/lang/System/out Ljava/io/PrintStream;
27         iload_0
28         invokevirtual java/io/PrintStream/println(I)V
29         return
30 .end method
31
32 ; ======================================================================
33
34 .method public static main([Ljava/lang/String;)V
35         .limit stack 2
36         .limit locals 2
37
38         new test_verify_fail_getfield_basic_type_lookup
39         dup
40         invokespecial test_verify_fail_getfield_basic_type_lookup/<init>()V
41
42         getfield test_verify_fail_getfield_basic_type_lookup/f I
43         ; ERROR: NoSuchFieldError
44
45         invokestatic test_verify_fail_getfield_basic_type_lookup/check(I)V
46
47         return
48 .end method
49