@@ -2268,27 +2268,27 @@ public abstract static class SetByteNode extends RubyBaseNode {
2268
2268
public abstract int execute (Node node , RubyString string , int index , int value );
2269
2269
2270
2270
@ Specialization (guards = "tstring.isMutable()" )
2271
- protected static int mutable (RubyString string , int index , int value ,
2271
+ protected static int mutable (Node node , RubyString string , int index , int value ,
2272
2272
@ Cached @ Shared StringHelperNodes .CheckIndexNode checkIndexNode ,
2273
2273
@ Cached @ Shared RubyStringLibrary libString ,
2274
2274
@ Bind ("string.tstring" ) AbstractTruffleString tstring ,
2275
2275
@ Cached @ Shared MutableTruffleString .WriteByteNode writeByteNode ) {
2276
2276
var tencoding = libString .getTEncoding (string );
2277
- final int normalizedIndex = checkIndexNode .executeCheck ( index , tstring .byteLength (tencoding ));
2277
+ final int normalizedIndex = checkIndexNode .execute ( node , index , tstring .byteLength (tencoding ));
2278
2278
2279
2279
writeByteNode .execute ((MutableTruffleString ) tstring , normalizedIndex , (byte ) value , tencoding );
2280
2280
return value ;
2281
2281
}
2282
2282
2283
2283
@ Specialization (guards = "!tstring.isMutable()" )
2284
- protected static int immutable (RubyString string , int index , int value ,
2284
+ protected static int immutable (Node node , RubyString string , int index , int value ,
2285
2285
@ Cached @ Shared StringHelperNodes .CheckIndexNode checkIndexNode ,
2286
2286
@ Cached @ Shared RubyStringLibrary libString ,
2287
2287
@ Bind ("string.tstring" ) AbstractTruffleString tstring ,
2288
2288
@ Cached MutableTruffleString .AsMutableTruffleStringNode asMutableTruffleStringNode ,
2289
2289
@ Cached @ Shared MutableTruffleString .WriteByteNode writeByteNode ) {
2290
2290
var tencoding = libString .getTEncoding (string );
2291
- final int normalizedIndex = checkIndexNode .executeCheck ( index , tstring .byteLength (tencoding ));
2291
+ final int normalizedIndex = checkIndexNode .execute ( node , index , tstring .byteLength (tencoding ));
2292
2292
2293
2293
MutableTruffleString mutableTString = asMutableTruffleStringNode .execute (tstring , tencoding );
2294
2294
writeByteNode .execute (mutableTString , normalizedIndex , (byte ) value , tencoding );
0 commit comments