Skip to content

Commit a19101a

Browse files
committed
Streamline code.
1 parent 5d6ccf7 commit a19101a

File tree

1 file changed

+4
-7
lines changed

1 file changed

+4
-7
lines changed

substratevm/src/com.oracle.graal.pointsto/src/com/oracle/graal/pointsto/results/ReachabilitySimplifier.java

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -326,29 +326,26 @@ private Stamp strengthenStamp(Stamp s) {
326326
return null;
327327
}
328328

329-
Stamp newStamp;
330329
if (strengthenType == null) {
331330
/* The type and its subtypes are not instantiated. */
332331
if (stamp.nonNull()) {
333332
/* We must be in dead code. */
334-
newStamp = StampFactory.empty(JavaKind.Object);
333+
return StampFactory.empty(JavaKind.Object);
335334
} else {
336-
newStamp = StampFactory.alwaysNull();
335+
return StampFactory.alwaysNull();
337336
}
338-
339337
} else {
340338
if (stamp.isExactType()) {
341339
/* We must be in dead code. */
342-
newStamp = StampFactory.empty(JavaKind.Object);
340+
return StampFactory.empty(JavaKind.Object);
343341
} else {
344342
ResolvedJavaType targetType = toTargetFunction.apply(strengthenType);
345343
if (targetType == null) {
346344
return null;
347345
}
348346
TypeReference typeRef = TypeReference.createTrustedWithoutAssumptions(targetType);
349-
newStamp = StampFactory.object(typeRef, stamp.nonNull());
347+
return StampFactory.object(typeRef, stamp.nonNull());
350348
}
351349
}
352-
return newStamp;
353350
}
354351
}

0 commit comments

Comments
 (0)