[Soot-list] For the assignment obj1 = staticInvoke(obj2); what parameter should I give to the Grimp.v().newAssignStmt function?

Eric Bodden bodden at st.informatik.tu-darmstadt.de
Wed May 5 09:14:27 EDT 2010


On behalf of Patrick Lam:

On 04/05/10 08:51 PM, Cristina Ilie wrote:
>Hello,
>
>I want to insert the assignment:
>z = AppSource.g_nested_compute($d0);

Hi Cristina,

Sounds like you need to pass Locals to your assignment constructor;
$d0 and z would normally be Locals.

pat

On 04/05/2010, Cristina Ilie <crysgirlro at yahoo.com> wrote:
> Hello,
>
> I want to insert the assignment:
>           z = AppSource.g_nested_compute($d0);
> where z and $d0 are instances of a class, MyClass, for example.
> I don't know what parameter I should to give to the method
> Grimp.v().newAssignStmt - this receive classes that implements the interface
> Value. I tried also with MyClass.getType which returns a RefType which
> doesn't implement the interface Value and it doesn't work...
>
> If I insert the assignment:
>         z.field = AppSource.g_nested_compute($d0.field);
> is simple. I do so:
>         assignmentStmt2 =
>             Grimp.v().newAssignStmt(
>                     Grimp.v().newInstanceFieldRef(locSExprDTLHS,
>                             derivTypeClass.getField(
>                                     "grad",
>                                     DoubleType.v()).makeRef()),
>                     gstaticInv2);
>
> Can you tell me please how I obtain a reference to an Object(type = a class
> defined by me)?
>
> Thanks,
> Cristina
>
>
>
>


-- 
Eric

--
Dr. Eric Bodden
Software Technology Group, Technische Universität Darmstadt, Germany
Tel: +49 6151 16-5478    Fax: +49 6151 16-5410
Mailing Address: S2|02 A209, Hochschulstraße 10, 64289 Darmstadt


More information about the Soot-list mailing list