Skip to content

Commit bc27661

Browse files
committed
Avoid eager boxing in Sst2ObjVisitorBase
1 parent 243265b commit bc27661

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

graalpython/com.oracle.graal.python/src/com/oracle/graal/python/builtins/modules/ast/Sst2ObjVisitorBase.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ abstract class Sst2ObjVisitorBase implements SSTreeVisitor<Object> {
7070
factory = PythonObjectFactory.getUncached();
7171
}
7272

73-
static Object visitNullable(int i) {
73+
static int visitNullable(int i) {
7474
return i;
7575
}
7676

@@ -86,15 +86,15 @@ final Object visitNullable(SSTNode node) {
8686
return node == null ? PNone.NONE : node.accept(this);
8787
}
8888

89-
static Object visitNonNull(boolean i) {
89+
static int visitNonNull(boolean i) {
9090
return i ? 1 : 0;
9191
}
9292

93-
static Object visitNonNull(int i) {
93+
static int visitNonNull(int i) {
9494
return i;
9595
}
9696

97-
static Object visitNonNull(String str) {
97+
static TruffleString visitNonNull(String str) {
9898
return toTruffleStringUncached(str);
9999
}
100100

0 commit comments

Comments
 (0)