Re: getting type information from this code

"Dave Brosius" <[email protected]>
Newsgroups gmane.comp.jakarta.bcel.user
Message-ID <002e01c4f934$8abdd9d0$2c7496d1@MBFG>
No, all you know is what local variable slot the variable is found in. Then 
you can look in the LocalVariableTable to find the information out (assuming 
it is in the class file) [compiled with -g]

the byte code would be something like

aconst_null
astore_1

----- Original Message ----- 
From: "Dean Hiller" <[email protected]>
To: <[email protected]>
Sent: Thursday, January 13, 2005 12:36 AM
Subject: getting type information from this code


Am I correct in saying the byte code will not contain information on the 
type for line 2 in the following code


line 1: public void someMethod() {
line 2:           DummyClass c = null;
line 3:  }

Is it correct to say that the byte code will not contain info that the 
variable c is of type DummyClass?  If I am incorrect, how do I get the type 
information?
thanks,
dean
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.