Skip to content

Commit 55930c7

Browse files
committed
Fix SetBasicWordBreakCharactersNode to use right value in guards
1 parent cbd0cb3 commit 55930c7

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/main/java/org/truffleruby/stdlib/readline/ReadlineNodes.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -78,12 +78,12 @@ protected RubyString basicWordBreakCharacters() {
7878
public abstract static class SetBasicWordBreakCharactersNode extends CoreMethodNode {
7979

8080
@TruffleBoundary
81-
@Specialization(guards = "strings.isRubyString(characters)", limit = "1")
81+
@Specialization(guards = "strings.isRubyString(charactersAsString)", limit = "1")
8282
protected static Object setBasicWordBreakCharacters(Object characters,
8383
@Cached ToStrNode toStrNode,
8484
@Cached RubyStringLibrary strings,
85-
@Bind("this") Node node) {
86-
final var charactersAsString = toStrNode.execute(node, characters);
85+
@Bind("this") Node node,
86+
@Bind("toStrNode.execute(node, characters)") Object charactersAsString) {
8787
final String delimiters = RubyGuards.getJavaString(charactersAsString);
8888
getContext(node).getConsoleHolder().getParser().setDelimiters(delimiters);
8989
return charactersAsString;

0 commit comments

Comments
 (0)