Skip to content

Commit e8fee35

Browse files
committed
Use static import.
1 parent e41f567 commit e8fee35

File tree

1 file changed

+4
-8
lines changed

1 file changed

+4
-8
lines changed

com.ibm.wala.cast.python.ml/source/com/ibm/wala/cast/python/ml/client/TensorGenerator.java

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
import static com.ibm.wala.cast.python.ml.types.TensorFlowTypes.DType.STRING;
66
import static com.ibm.wala.cast.python.ml.types.TensorFlowTypes.FIELD_REFERENCE_TO_DTYPE;
77
import static com.ibm.wala.cast.python.ml.types.TensorFlowTypes.TENSORFLOW;
8+
import static com.ibm.wala.cast.python.types.PythonTypes.Root;
89
import static com.ibm.wala.cast.python.types.PythonTypes.list;
910
import static com.ibm.wala.cast.python.types.PythonTypes.tuple;
1011
import static com.ibm.wala.cast.python.util.Util.getAllocationSiteInNode;
@@ -121,8 +122,7 @@ protected Set<List<Dimension<?>>> getShapesFromShapeArgument(
121122
Integer fieldIndex = (Integer) constantKeyValue;
122123

123124
FieldReference subscript =
124-
FieldReference.findOrCreate(
125-
PythonTypes.Root, findOrCreateAsciiAtom(fieldIndex.toString()), PythonTypes.Root);
125+
FieldReference.findOrCreate(Root, findOrCreateAsciiAtom(fieldIndex.toString()), Root);
126126

127127
IField f = builder.getClassHierarchy().resolveField(subscript);
128128
LOGGER.fine("Found field: " + f);
@@ -330,9 +330,7 @@ else if (valueIK instanceof AllocationSiteInNode) {
330330

331331
FieldReference subscript =
332332
FieldReference.findOrCreate(
333-
PythonTypes.Root,
334-
findOrCreateAsciiAtom(fieldIndex.toString()),
335-
PythonTypes.Root);
333+
Root, findOrCreateAsciiAtom(fieldIndex.toString()), Root);
336334

337335
IField f = builder.getClassHierarchy().resolveField(subscript);
338336
LOGGER.fine("Found field: " + f);
@@ -623,9 +621,7 @@ private EnumSet<DType> getDTypesOfValue(
623621

624622
FieldReference subscript =
625623
FieldReference.findOrCreate(
626-
PythonTypes.Root,
627-
findOrCreateAsciiAtom(fieldIndex.toString()),
628-
PythonTypes.Root);
624+
Root, findOrCreateAsciiAtom(fieldIndex.toString()), Root);
629625

630626
IField f = builder.getClassHierarchy().resolveField(subscript);
631627
LOGGER.fine("Found field: " + f);

0 commit comments

Comments
 (0)