diff graal/com.oracle.max.graal.nodes/src/com/oracle/max/graal/nodes/java/MethodCallTargetNode.java @ 4411:cd2b68ef8e23

cleanup around filter and predicates : remove duplicate compiler.util.NodeIterators add contains to NodeIterable support isNotA(Class).nor(Class) filtering support filtering on interfaces remove and/or(Class) from FilteredNodeIterable replace with isA(Class).or(Class) lower the cost on extending NodeIterable (remove the until field) NodeList is a NodeIterable Use NodeIterable functions where possible
author Gilles Duboscq <duboscq@ssw.jku.at>
date Mon, 30 Jan 2012 13:06:11 +0100
parents 4a609a685fa4
children 1827e00c87b9 eb6df44a1374
line wrap: on
line diff
--- a/graal/com.oracle.max.graal.nodes/src/com/oracle/max/graal/nodes/java/MethodCallTargetNode.java	Fri Jan 27 00:40:26 2012 +0100
+++ b/graal/com.oracle.max.graal.nodes/src/com/oracle/max/graal/nodes/java/MethodCallTargetNode.java	Mon Jan 30 13:06:11 2012 +0100
@@ -106,10 +106,7 @@
     }
 
     public Invoke invoke() {
-        if (this.usages().size() == 0) {
-            return null;
-        }
-        return (Invoke) this.usages().iterator().next();
+        return (Invoke) this.usages().first();
     }