I have an instance of the object VMemRead (let's call it r). The constructor for VMemRead looks like
VMemRead(SourcePos sourcePos, VVarRef dest, VMemRef source)
with fields dest and source. I know when I want to access dest, I can just do r.dest. However, I want to go "deeper" into source.
VMRef has two nested classes VMemRef.Global and VMemRef.Stack. VMemRef.Global has the constructor
VMemRef.Global(SourcePos sourcePos, VAddr<VDataSegment> base, int byteOffset)
I want to access the int byteOffset. In effect, I want to do something like r.source.Global.byteOffset but Java doesn't let me do this.
Is there any way I can access that value?
Documentation: VMemRead: http://cs.ucla.edu/classes/spring11/cs132/kannan/vapor-parser/vapor-parser-javadoc/cs132/vapor/ast/VMemRead.html#source
VMemRef.Global: http://cs.ucla.edu/classes/spring11/cs132/kannan/vapor-parser/vapor-parser-javadoc/cs132/vapor/ast/VMemRef.Global.html
Thank you very much!
extends VMemRef...? Because sayingr.source.Global.byteOffsetis definitely wrong no matter which way it is. Just don't know which you exactly you have it.