[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Dava imports and static fields and methods
Static fields and methods need to have the correct classes imported.
This is a simple patch to DavaBody.java:
574,576c574,575
< if (r instanceof StaticFieldRef) {
< addPackage(((StaticFieldRef)
r).getField().getDeclaringClass().getJavaPackageName());
< vb.setValue( new DStaticFieldRef( ((StaticFieldRef)
r).getField(), getMethod().getDeclaringClass().getName()));
---
> if (r instanceof StaticFieldRef)
> vb.setValue( new DStaticFieldRef( ((StaticFieldRef)
r).getField(), getMethod().getDeclaringClass().getName()));
578c577
< } else if (r instanceof ArrayRef) {
---
> else if (r instanceof ArrayRef) {
757,759c756,757
<
addPackage(sie.getMethod().getDeclaringClass().getJavaPackageName());
< vb.setValue( new DStaticInvokeExpr( sie.getMethod(),
sie.getArgs()));
< }
---
>
> vb.setValue( new DStaticInvokeExpr( sie.getMethod(),
sie.getArgs()));