JBoss Community

Re: Can JavaAssist change a static final field?

created by Shigeru Chiba in Javassist - View the full discussion

According to my memory, changing the value of a static field is not straightforward because

javac may inline the value of static constant field at occurrences of that field even in different

class files.  In that case, after compilation, Javassist cannot see where the original value is

embedded in class files and have to be modified.

Reply to this message by going to Community

Start a new discussion in Javassist at Community