From 89802078f9f406be411032814e1960e62dbc7ce2 Mon Sep 17 00:00:00 2001 From: Nobuyoshi Nakada Date: Fri, 15 Sep 2023 15:39:58 +0900 Subject: [Bug #19882] Reject tokens invalid as symbols --- test/ruby/test_parse.rb | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'test/ruby') diff --git a/test/ruby/test_parse.rb b/test/ruby/test_parse.rb index 2f1a522dc2..34a8848c52 100644 --- a/test/ruby/test_parse.rb +++ b/test/ruby/test_parse.rb @@ -661,6 +661,7 @@ class TestParse < Test::Unit::TestCase assert_syntax_error(':@@1', /is not allowed/) assert_syntax_error(':@', /is not allowed/) assert_syntax_error(':@1', /is not allowed/) + assert_syntax_error(':$01234', /is not allowed/) end def test_parse_string @@ -1478,8 +1479,8 @@ x = __ENCODING__ end def test_ungettable_gvar - assert_syntax_error('$01234', /not valid to get/) - assert_syntax_error('"#$01234"', /not valid to get/) + assert_syntax_error('$01234', /not allowed/) + assert_syntax_error('"#$01234"', /not allowed/) end =begin -- cgit v1.2.3