[Soot-list] How to get the base of an InvokeExpr?
Bernhard Berger
berber at tzi.de
Thu Jun 28 08:07:27 EDT 2018
Hi Sep,
InvokeExpr does not necessarily have a base object, for instance for static invokes (StaticInvokeExpr). You have to check if your expr is an instance of InstanceInvokeExpr. After casting it you can call getBas().
Cheers, Bernhard
> On 28. Jun 2018, at 11:00, 周书林 <zhoushulin1992 at gmail.com> wrote:
>
> Hello everyone,
> I am new in Soot. In my experiment, I want to get the information of an InvokeExpr, including its base argument and method arguments.
>
> For instance, for the following InvokeExpr, I want to get the argument "$r10" and "r1", but I can only get the "r1" with API "getArg(int index)". There is no API "getBase()" in InvokeExpr to get the "$r10".
>
> $r11 = virtualinvoke $r10.<java.lang.StringBuilder: java.lang.StringBuilder append(java.lang.String)>(r1);
>
> So, Could you please guide me how to get the base of an InvokeExpr?
>
> Thank you very much,
> Sincerely.
>
> Sep
> _______________________________________________
> Soot-list mailing list
> Soot-list at CS.McGill.CA
> https://mailman.CS.McGill.CA/mailman/listinfo/soot-list
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mailman.CS.McGill.CA/pipermail/soot-list/attachments/20180628/b5d91c3d/attachment.html>
More information about the Soot-list
mailing list