[Soot-list] annotating an existing .class file

Marc-André Laverdière marc-andre.laverdiere-papineau at polymtl.ca
Tue Jul 23 15:22:34 EDT 2013


Hi Quentin,

As far as I know, Soot always will generate a new file. It is possible
that this option changes things - I never heard of it before.

It is possible to add Java annotations that are runtime-preserved,
meaning that they get written in the bytecode.
But I don't know if that's going to hurt the bytecode offset. Java
annotations are stored in the constant pool apparently.

http://stackoverflow.com/questions/5432611/how-compiler-deals-with-annotations


On 07/22/2013 12:41 PM, Quentin Sabah wrote:
> Hi all,
> Does Soot features something to help adding annotations into an existing .class file ? 
> 
> I'd like to run some annotation analysis with -keep-bytecode-offset enabled, so that I could annotate the input .class files instead of generating a new one (which would certainly have a different bytecode code array).
> 
> Thanks.
> 

-- 
Marc-André Laverdière-Papineau
Doctorant - PhD Candidate


More information about the Soot-list mailing list