jakarta-bcel-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Abel Wang" <ab...@nvisionsoftware.net>
Subject checking
Date Tue, 01 Oct 2002 18:39:04 GMT
Hi guys, I want to check to see if this really is a bug or if I'm doing
something wrong.

I have a class with a method like this

public void test {
    System.out.println("hello 1");
    try {
        System.out.println("hello 2");

    }
    catch(Exception e) {
        System.out.println("hello 3");
    }
    System.out.println("hello 4");
}


here's the instruction list for that particular method that I got:

[0] getstatic[178](3) 14
[1] ldc[18](2) 45
[2] invokevirtual[182](3) 18
[3] getstatic[178](3) 14
[4] ldc[18](2) 46
[5] invokevirtual[182](3) 18
[6] goto[167](3) -> null
[7] astore_1[76](1)
[8] getstatic[178](3) 14
[9] ldc[18](2) 47
[10] invokevirtual[182](3) 18
[11] getstatic[178](3) 14
[12] ldc[18](2) 48
[13] invokevirtual[182](3) 18
[14] return[177](1)

Why does index 6 (the branch instruction)  point to null?  shouldn't it
point to 11?  Is this a bug in BCEL or do I need to do something different
to get the index of where the branch instruciton points to?

Thanks,

--Abel


--
To unsubscribe, e-mail:   <mailto:bcel-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:bcel-user-help@jakarta.apache.org>


Mime
View raw message