Mercurial > hg > graal-jvmci-8
comparison graal/com.oracle.truffle.sl/src/com/oracle/truffle/sl/nodes/ArithmeticNode.java @ 8240:33e08aca06ff
Codegen API change. Simplified definition of guards.
author | Christian Humer <christian.humer@gmail.com> |
---|---|
date | Fri, 01 Mar 2013 18:04:23 +0100 |
parents | 5e3d1a68664e |
children | d81ff782fa1a |
comparison
equal
deleted
inserted
replaced
8239:8fa2eed07f81 | 8240:33e08aca06ff |
---|---|
66 @Specialization | 66 @Specialization |
67 String doStringDirect(String left, String right) { | 67 String doStringDirect(String left, String right) { |
68 return left + right; | 68 return left + right; |
69 } | 69 } |
70 | 70 |
71 @Specialization | 71 @Specialization(guards = "isString") |
72 @SpecializationGuard(methodName = "isString") | |
73 String doString(Object left, Object right) { | 72 String doString(Object left, Object right) { |
74 return left.toString() + right.toString(); | 73 return left.toString() + right.toString(); |
75 } | 74 } |
76 } | 75 } |
77 | 76 |