From 546566d34b37fb5a028bcbe6bafa8248877f06ca Mon Sep 17 00:00:00 2001 From: Nobuyoshi Nakada Date: Sun, 9 Oct 2022 17:43:16 +0900 Subject: Do not set `$!` to `SyntaxError` when error tolerant --- test/ruby/test_ast.rb | 2 ++ 1 file changed, 2 insertions(+) (limited to 'test/ruby') diff --git a/test/ruby/test_ast.rb b/test/ruby/test_ast.rb index faa989c2fb..b91880be6d 100644 --- a/test/ruby/test_ast.rb +++ b/test/ruby/test_ast.rb @@ -576,6 +576,7 @@ dummy end end STR + assert_nil($!) assert_equal(:SCOPE, node.type) end @@ -965,6 +966,7 @@ dummy def assert_error_tolerant(src, expected) node = RubyVM::AbstractSyntaxTree.parse(src, error_tolerant: true) + assert_nil($!) str = "" PP.pp(node, str, 80) assert_equal(expected, str) -- cgit v1.2.3