Mercurial > hg > graal-jvmci-8
diff graal/com.oracle.truffle.sl/src/com/oracle/truffle/sl/nodes/SLTypes.java @ 18782:3ea386a1036f
Truffle-DSL: breaking: @TypeCheck and @TypeCast now require casted/checked type as explicit parameter. Previously the type was parsed from the method name. (GRAAL-446 #resolve)
author | Christian Humer <christian.humer@gmail.com> |
---|---|
date | Mon, 05 Jan 2015 20:23:22 +0100 |
parents | 924bf48a5d6a |
children | 894f82515e38 |
line wrap: on
line diff
--- a/graal/com.oracle.truffle.sl/src/com/oracle/truffle/sl/nodes/SLTypes.java Mon Jan 05 20:23:22 2015 +0100 +++ b/graal/com.oracle.truffle.sl/src/com/oracle/truffle/sl/nodes/SLTypes.java Mon Jan 05 20:23:22 2015 +0100 @@ -45,7 +45,7 @@ * {@code instanceof} check, because we know that there is only a {@link SLNull#SINGLETON * singleton} instance. */ - @TypeCheck + @TypeCheck(SLNull.class) public static boolean isSLNull(Object value) { return value == SLNull.SINGLETON; } @@ -55,7 +55,7 @@ * that the Truffle DSL would generate. For {@link SLNull}, we do not need an actual cast, * because we know that there is only a {@link SLNull#SINGLETON singleton} instance. */ - @TypeCast + @TypeCast(SLNull.class) public static SLNull asSLNull(Object value) { assert isSLNull(value); return SLNull.SINGLETON;