parser 3.3.7.3 → 3.3.7.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/parser/builders/default.rb +18 -5
- data/lib/parser/lexer-F0.rb +306 -297
- data/lib/parser/lexer-F1.rb +571 -562
- data/lib/parser/lexer-strings.rb +89 -80
- data/lib/parser/ruby27.rb +2 -1
- data/lib/parser/ruby30.rb +2 -1
- data/lib/parser/ruby31.rb +2 -1
- data/lib/parser/ruby32.rb +2 -1
- data/lib/parser/ruby33.rb +2 -1
- data/lib/parser/ruby34.rb +2 -1
- data/lib/parser/version.rb +1 -1
- metadata +5 -5
data/lib/parser/lexer-strings.rb
CHANGED
@@ -3419,7 +3419,7 @@ begin # ragel flat
|
|
3419
3419
|
_acts += 1
|
3420
3420
|
case _lex_actions[_acts - 1]
|
3421
3421
|
when 0 then
|
3422
|
-
# line
|
3422
|
+
# line 534 "lib/parser/lexer-strings.rl"
|
3423
3423
|
begin
|
3424
3424
|
|
3425
3425
|
# Record position of a newline for precise location reporting on tNL
|
@@ -3430,116 +3430,116 @@ begin # ragel flat
|
|
3430
3430
|
@newline_s = p
|
3431
3431
|
end
|
3432
3432
|
when 1 then
|
3433
|
-
# line
|
3433
|
+
# line 590 "lib/parser/lexer-strings.rl"
|
3434
3434
|
begin
|
3435
3435
|
|
3436
3436
|
unicode_points(p)
|
3437
3437
|
end
|
3438
3438
|
when 2 then
|
3439
|
-
# line
|
3439
|
+
# line 594 "lib/parser/lexer-strings.rl"
|
3440
3440
|
begin
|
3441
3441
|
|
3442
3442
|
unescape_char(p)
|
3443
3443
|
end
|
3444
3444
|
when 3 then
|
3445
|
-
# line
|
3445
|
+
# line 598 "lib/parser/lexer-strings.rl"
|
3446
3446
|
begin
|
3447
3447
|
|
3448
3448
|
diagnostic :fatal, :invalid_escape
|
3449
3449
|
end
|
3450
3450
|
when 4 then
|
3451
|
-
# line
|
3451
|
+
# line 602 "lib/parser/lexer-strings.rl"
|
3452
3452
|
begin
|
3453
3453
|
|
3454
3454
|
read_post_meta_or_ctrl_char(p)
|
3455
3455
|
end
|
3456
3456
|
when 5 then
|
3457
|
-
# line
|
3457
|
+
# line 606 "lib/parser/lexer-strings.rl"
|
3458
3458
|
begin
|
3459
3459
|
|
3460
3460
|
slash_c_char
|
3461
3461
|
end
|
3462
3462
|
when 6 then
|
3463
|
-
# line
|
3463
|
+
# line 610 "lib/parser/lexer-strings.rl"
|
3464
3464
|
begin
|
3465
3465
|
|
3466
3466
|
slash_m_char
|
3467
3467
|
end
|
3468
3468
|
when 7 then
|
3469
|
-
# line
|
3469
|
+
# line 616 "lib/parser/lexer-strings.rl"
|
3470
3470
|
begin
|
3471
3471
|
encode_escaped_char(p) end
|
3472
3472
|
when 8 then
|
3473
|
-
# line
|
3473
|
+
# line 622 "lib/parser/lexer-strings.rl"
|
3474
3474
|
begin
|
3475
3475
|
@escape = "\x7f" end
|
3476
3476
|
when 9 then
|
3477
|
-
# line
|
3477
|
+
# line 623 "lib/parser/lexer-strings.rl"
|
3478
3478
|
begin
|
3479
3479
|
encode_escaped_char(p) end
|
3480
3480
|
when 10 then
|
3481
|
-
# line
|
3481
|
+
# line 630 "lib/parser/lexer-strings.rl"
|
3482
3482
|
begin
|
3483
3483
|
@escape = encode_escape(tok(@escape_s, p).to_i(8) % 0x100) end
|
3484
3484
|
when 11 then
|
3485
|
-
# line
|
3485
|
+
# line 634 "lib/parser/lexer-strings.rl"
|
3486
3486
|
begin
|
3487
3487
|
@escape = encode_escape(tok(@escape_s + 1, p).to_i(16)) end
|
3488
3488
|
when 12 then
|
3489
|
-
# line
|
3489
|
+
# line 638 "lib/parser/lexer-strings.rl"
|
3490
3490
|
begin
|
3491
3491
|
|
3492
3492
|
diagnostic :fatal, :invalid_hex_escape, nil, range(@escape_s - 1, p + 2)
|
3493
3493
|
end
|
3494
3494
|
when 13 then
|
3495
|
-
# line
|
3495
|
+
# line 644 "lib/parser/lexer-strings.rl"
|
3496
3496
|
begin
|
3497
3497
|
@escape = tok(@escape_s + 1, p).to_i(16).chr(Encoding::UTF_8) end
|
3498
3498
|
when 14 then
|
3499
|
-
# line
|
3499
|
+
# line 648 "lib/parser/lexer-strings.rl"
|
3500
3500
|
begin
|
3501
3501
|
|
3502
3502
|
check_invalid_escapes(p)
|
3503
3503
|
end
|
3504
3504
|
when 15 then
|
3505
|
-
# line
|
3505
|
+
# line 654 "lib/parser/lexer-strings.rl"
|
3506
3506
|
begin
|
3507
3507
|
|
3508
3508
|
check_invalid_escapes(p)
|
3509
3509
|
end
|
3510
3510
|
when 16 then
|
3511
|
-
# line
|
3511
|
+
# line 668 "lib/parser/lexer-strings.rl"
|
3512
3512
|
begin
|
3513
3513
|
|
3514
3514
|
diagnostic :fatal, :unterminated_unicode, nil, range(p - 1, p)
|
3515
3515
|
end
|
3516
3516
|
when 17 then
|
3517
|
-
# line
|
3517
|
+
# line 694 "lib/parser/lexer-strings.rl"
|
3518
3518
|
begin
|
3519
3519
|
|
3520
3520
|
diagnostic :fatal, :escape_eof, nil, range(p - 1, p)
|
3521
3521
|
end
|
3522
3522
|
when 18 then
|
3523
|
-
# line
|
3523
|
+
# line 700 "lib/parser/lexer-strings.rl"
|
3524
3524
|
begin
|
3525
3525
|
|
3526
3526
|
@escape_s = p
|
3527
3527
|
@escape = nil
|
3528
3528
|
end
|
3529
3529
|
when 19 then
|
3530
|
-
# line
|
3530
|
+
# line 817 "lib/parser/lexer-strings.rl"
|
3531
3531
|
begin
|
3532
3532
|
interp_var_kind = :gvar end
|
3533
3533
|
when 20 then
|
3534
|
-
# line
|
3534
|
+
# line 818 "lib/parser/lexer-strings.rl"
|
3535
3535
|
begin
|
3536
3536
|
interp_var_kind = :cvar end
|
3537
3537
|
when 21 then
|
3538
|
-
# line
|
3538
|
+
# line 819 "lib/parser/lexer-strings.rl"
|
3539
3539
|
begin
|
3540
3540
|
interp_var_kind = :ivar end
|
3541
3541
|
when 22 then
|
3542
|
-
# line
|
3542
|
+
# line 953 "lib/parser/lexer-strings.rl"
|
3543
3543
|
begin
|
3544
3544
|
@escape = nil end
|
3545
3545
|
when 25 then
|
@@ -3548,7 +3548,7 @@ begin # ragel flat
|
|
3548
3548
|
@te = p+1
|
3549
3549
|
end
|
3550
3550
|
when 26 then
|
3551
|
-
# line
|
3551
|
+
# line 851 "lib/parser/lexer-strings.rl"
|
3552
3552
|
begin
|
3553
3553
|
@te = p+1
|
3554
3554
|
begin
|
@@ -3565,7 +3565,7 @@ begin # ragel flat
|
|
3565
3565
|
end
|
3566
3566
|
end
|
3567
3567
|
when 27 then
|
3568
|
-
# line
|
3568
|
+
# line 770 "lib/parser/lexer-strings.rl"
|
3569
3569
|
begin
|
3570
3570
|
@te = p+1
|
3571
3571
|
begin
|
@@ -3616,7 +3616,7 @@ begin # ragel flat
|
|
3616
3616
|
end
|
3617
3617
|
end
|
3618
3618
|
when 28 then
|
3619
|
-
# line
|
3619
|
+
# line 740 "lib/parser/lexer-strings.rl"
|
3620
3620
|
begin
|
3621
3621
|
@te = p+1
|
3622
3622
|
begin
|
@@ -3649,7 +3649,7 @@ begin # ragel flat
|
|
3649
3649
|
end
|
3650
3650
|
end
|
3651
3651
|
when 29 then
|
3652
|
-
# line
|
3652
|
+
# line 833 "lib/parser/lexer-strings.rl"
|
3653
3653
|
begin
|
3654
3654
|
@te = p
|
3655
3655
|
p = p - 1; begin
|
@@ -3657,7 +3657,7 @@ p = p - 1; begin
|
|
3657
3657
|
end
|
3658
3658
|
end
|
3659
3659
|
when 30 then
|
3660
|
-
# line
|
3660
|
+
# line 822 "lib/parser/lexer-strings.rl"
|
3661
3661
|
begin
|
3662
3662
|
@te = p
|
3663
3663
|
p = p - 1; begin
|
@@ -3667,7 +3667,7 @@ p = p - 1; begin
|
|
3667
3667
|
end
|
3668
3668
|
end
|
3669
3669
|
when 31 then
|
3670
|
-
# line
|
3670
|
+
# line 763 "lib/parser/lexer-strings.rl"
|
3671
3671
|
begin
|
3672
3672
|
@te = p
|
3673
3673
|
p = p - 1; begin
|
@@ -3675,7 +3675,7 @@ p = p - 1; begin
|
|
3675
3675
|
end
|
3676
3676
|
end
|
3677
3677
|
when 32 then
|
3678
|
-
# line
|
3678
|
+
# line 805 "lib/parser/lexer-strings.rl"
|
3679
3679
|
begin
|
3680
3680
|
@te = p
|
3681
3681
|
p = p - 1; begin
|
@@ -3683,7 +3683,7 @@ p = p - 1; begin
|
|
3683
3683
|
end
|
3684
3684
|
end
|
3685
3685
|
when 33 then
|
3686
|
-
# line
|
3686
|
+
# line 740 "lib/parser/lexer-strings.rl"
|
3687
3687
|
begin
|
3688
3688
|
@te = p
|
3689
3689
|
p = p - 1; begin
|
@@ -3716,7 +3716,7 @@ p = p - 1; begin
|
|
3716
3716
|
end
|
3717
3717
|
end
|
3718
3718
|
when 34 then
|
3719
|
-
# line
|
3719
|
+
# line 763 "lib/parser/lexer-strings.rl"
|
3720
3720
|
begin
|
3721
3721
|
begin p = (( @te))-1; end
|
3722
3722
|
begin
|
@@ -3724,7 +3724,7 @@ p = p - 1; begin
|
|
3724
3724
|
end
|
3725
3725
|
end
|
3726
3726
|
when 35 then
|
3727
|
-
# line
|
3727
|
+
# line 740 "lib/parser/lexer-strings.rl"
|
3728
3728
|
begin
|
3729
3729
|
begin p = (( @te))-1; end
|
3730
3730
|
begin
|
@@ -3757,7 +3757,7 @@ p = p - 1; begin
|
|
3757
3757
|
end
|
3758
3758
|
end
|
3759
3759
|
when 36 then
|
3760
|
-
# line
|
3760
|
+
# line 851 "lib/parser/lexer-strings.rl"
|
3761
3761
|
begin
|
3762
3762
|
@te = p+1
|
3763
3763
|
begin
|
@@ -3774,7 +3774,7 @@ p = p - 1; begin
|
|
3774
3774
|
end
|
3775
3775
|
end
|
3776
3776
|
when 37 then
|
3777
|
-
# line
|
3777
|
+
# line 770 "lib/parser/lexer-strings.rl"
|
3778
3778
|
begin
|
3779
3779
|
@te = p+1
|
3780
3780
|
begin
|
@@ -3825,7 +3825,7 @@ p = p - 1; begin
|
|
3825
3825
|
end
|
3826
3826
|
end
|
3827
3827
|
when 38 then
|
3828
|
-
# line
|
3828
|
+
# line 740 "lib/parser/lexer-strings.rl"
|
3829
3829
|
begin
|
3830
3830
|
@te = p+1
|
3831
3831
|
begin
|
@@ -3858,7 +3858,7 @@ p = p - 1; begin
|
|
3858
3858
|
end
|
3859
3859
|
end
|
3860
3860
|
when 39 then
|
3861
|
-
# line
|
3861
|
+
# line 833 "lib/parser/lexer-strings.rl"
|
3862
3862
|
begin
|
3863
3863
|
@te = p
|
3864
3864
|
p = p - 1; begin
|
@@ -3866,7 +3866,7 @@ p = p - 1; begin
|
|
3866
3866
|
end
|
3867
3867
|
end
|
3868
3868
|
when 40 then
|
3869
|
-
# line
|
3869
|
+
# line 822 "lib/parser/lexer-strings.rl"
|
3870
3870
|
begin
|
3871
3871
|
@te = p
|
3872
3872
|
p = p - 1; begin
|
@@ -3876,7 +3876,7 @@ p = p - 1; begin
|
|
3876
3876
|
end
|
3877
3877
|
end
|
3878
3878
|
when 41 then
|
3879
|
-
# line
|
3879
|
+
# line 763 "lib/parser/lexer-strings.rl"
|
3880
3880
|
begin
|
3881
3881
|
@te = p
|
3882
3882
|
p = p - 1; begin
|
@@ -3884,7 +3884,7 @@ p = p - 1; begin
|
|
3884
3884
|
end
|
3885
3885
|
end
|
3886
3886
|
when 42 then
|
3887
|
-
# line
|
3887
|
+
# line 740 "lib/parser/lexer-strings.rl"
|
3888
3888
|
begin
|
3889
3889
|
@te = p
|
3890
3890
|
p = p - 1; begin
|
@@ -3917,7 +3917,7 @@ p = p - 1; begin
|
|
3917
3917
|
end
|
3918
3918
|
end
|
3919
3919
|
when 43 then
|
3920
|
-
# line
|
3920
|
+
# line 763 "lib/parser/lexer-strings.rl"
|
3921
3921
|
begin
|
3922
3922
|
begin p = (( @te))-1; end
|
3923
3923
|
begin
|
@@ -3925,7 +3925,7 @@ p = p - 1; begin
|
|
3925
3925
|
end
|
3926
3926
|
end
|
3927
3927
|
when 44 then
|
3928
|
-
# line
|
3928
|
+
# line 740 "lib/parser/lexer-strings.rl"
|
3929
3929
|
begin
|
3930
3930
|
begin p = (( @te))-1; end
|
3931
3931
|
begin
|
@@ -3958,7 +3958,7 @@ p = p - 1; begin
|
|
3958
3958
|
end
|
3959
3959
|
end
|
3960
3960
|
when 45 then
|
3961
|
-
# line
|
3961
|
+
# line 763 "lib/parser/lexer-strings.rl"
|
3962
3962
|
begin
|
3963
3963
|
@te = p+1
|
3964
3964
|
begin
|
@@ -3966,7 +3966,7 @@ p = p - 1; begin
|
|
3966
3966
|
end
|
3967
3967
|
end
|
3968
3968
|
when 46 then
|
3969
|
-
# line
|
3969
|
+
# line 770 "lib/parser/lexer-strings.rl"
|
3970
3970
|
begin
|
3971
3971
|
@te = p+1
|
3972
3972
|
begin
|
@@ -4017,7 +4017,7 @@ p = p - 1; begin
|
|
4017
4017
|
end
|
4018
4018
|
end
|
4019
4019
|
when 47 then
|
4020
|
-
# line
|
4020
|
+
# line 740 "lib/parser/lexer-strings.rl"
|
4021
4021
|
begin
|
4022
4022
|
@te = p+1
|
4023
4023
|
begin
|
@@ -4050,7 +4050,7 @@ p = p - 1; begin
|
|
4050
4050
|
end
|
4051
4051
|
end
|
4052
4052
|
when 48 then
|
4053
|
-
# line
|
4053
|
+
# line 805 "lib/parser/lexer-strings.rl"
|
4054
4054
|
begin
|
4055
4055
|
@te = p
|
4056
4056
|
p = p - 1; begin
|
@@ -4058,7 +4058,7 @@ p = p - 1; begin
|
|
4058
4058
|
end
|
4059
4059
|
end
|
4060
4060
|
when 49 then
|
4061
|
-
# line
|
4061
|
+
# line 740 "lib/parser/lexer-strings.rl"
|
4062
4062
|
begin
|
4063
4063
|
@te = p
|
4064
4064
|
p = p - 1; begin
|
@@ -4091,7 +4091,7 @@ p = p - 1; begin
|
|
4091
4091
|
end
|
4092
4092
|
end
|
4093
4093
|
when 50 then
|
4094
|
-
# line
|
4094
|
+
# line 770 "lib/parser/lexer-strings.rl"
|
4095
4095
|
begin
|
4096
4096
|
@te = p+1
|
4097
4097
|
begin
|
@@ -4142,7 +4142,7 @@ p = p - 1; begin
|
|
4142
4142
|
end
|
4143
4143
|
end
|
4144
4144
|
when 51 then
|
4145
|
-
# line
|
4145
|
+
# line 763 "lib/parser/lexer-strings.rl"
|
4146
4146
|
begin
|
4147
4147
|
@te = p+1
|
4148
4148
|
begin
|
@@ -4150,7 +4150,7 @@ p = p - 1; begin
|
|
4150
4150
|
end
|
4151
4151
|
end
|
4152
4152
|
when 52 then
|
4153
|
-
# line
|
4153
|
+
# line 770 "lib/parser/lexer-strings.rl"
|
4154
4154
|
begin
|
4155
4155
|
@te = p+1
|
4156
4156
|
begin
|
@@ -4201,7 +4201,7 @@ p = p - 1; begin
|
|
4201
4201
|
end
|
4202
4202
|
end
|
4203
4203
|
when 53 then
|
4204
|
-
# line
|
4204
|
+
# line 740 "lib/parser/lexer-strings.rl"
|
4205
4205
|
begin
|
4206
4206
|
@te = p+1
|
4207
4207
|
begin
|
@@ -4234,7 +4234,7 @@ p = p - 1; begin
|
|
4234
4234
|
end
|
4235
4235
|
end
|
4236
4236
|
when 54 then
|
4237
|
-
# line
|
4237
|
+
# line 740 "lib/parser/lexer-strings.rl"
|
4238
4238
|
begin
|
4239
4239
|
@te = p
|
4240
4240
|
p = p - 1; begin
|
@@ -4267,7 +4267,7 @@ p = p - 1; begin
|
|
4267
4267
|
end
|
4268
4268
|
end
|
4269
4269
|
when 55 then
|
4270
|
-
# line
|
4270
|
+
# line 851 "lib/parser/lexer-strings.rl"
|
4271
4271
|
begin
|
4272
4272
|
@te = p+1
|
4273
4273
|
begin
|
@@ -4284,7 +4284,7 @@ p = p - 1; begin
|
|
4284
4284
|
end
|
4285
4285
|
end
|
4286
4286
|
when 56 then
|
4287
|
-
# line
|
4287
|
+
# line 770 "lib/parser/lexer-strings.rl"
|
4288
4288
|
begin
|
4289
4289
|
@te = p+1
|
4290
4290
|
begin
|
@@ -4335,7 +4335,7 @@ p = p - 1; begin
|
|
4335
4335
|
end
|
4336
4336
|
end
|
4337
4337
|
when 57 then
|
4338
|
-
# line
|
4338
|
+
# line 740 "lib/parser/lexer-strings.rl"
|
4339
4339
|
begin
|
4340
4340
|
@te = p+1
|
4341
4341
|
begin
|
@@ -4368,7 +4368,7 @@ p = p - 1; begin
|
|
4368
4368
|
end
|
4369
4369
|
end
|
4370
4370
|
when 58 then
|
4371
|
-
# line
|
4371
|
+
# line 833 "lib/parser/lexer-strings.rl"
|
4372
4372
|
begin
|
4373
4373
|
@te = p
|
4374
4374
|
p = p - 1; begin
|
@@ -4376,7 +4376,7 @@ p = p - 1; begin
|
|
4376
4376
|
end
|
4377
4377
|
end
|
4378
4378
|
when 59 then
|
4379
|
-
# line
|
4379
|
+
# line 822 "lib/parser/lexer-strings.rl"
|
4380
4380
|
begin
|
4381
4381
|
@te = p
|
4382
4382
|
p = p - 1; begin
|
@@ -4386,7 +4386,7 @@ p = p - 1; begin
|
|
4386
4386
|
end
|
4387
4387
|
end
|
4388
4388
|
when 60 then
|
4389
|
-
# line
|
4389
|
+
# line 740 "lib/parser/lexer-strings.rl"
|
4390
4390
|
begin
|
4391
4391
|
@te = p
|
4392
4392
|
p = p - 1; begin
|
@@ -4419,7 +4419,7 @@ p = p - 1; begin
|
|
4419
4419
|
end
|
4420
4420
|
end
|
4421
4421
|
when 61 then
|
4422
|
-
# line
|
4422
|
+
# line 740 "lib/parser/lexer-strings.rl"
|
4423
4423
|
begin
|
4424
4424
|
begin p = (( @te))-1; end
|
4425
4425
|
begin
|
@@ -4452,7 +4452,7 @@ p = p - 1; begin
|
|
4452
4452
|
end
|
4453
4453
|
end
|
4454
4454
|
when 62 then
|
4455
|
-
# line
|
4455
|
+
# line 770 "lib/parser/lexer-strings.rl"
|
4456
4456
|
begin
|
4457
4457
|
@te = p+1
|
4458
4458
|
begin
|
@@ -4503,7 +4503,7 @@ p = p - 1; begin
|
|
4503
4503
|
end
|
4504
4504
|
end
|
4505
4505
|
when 63 then
|
4506
|
-
# line
|
4506
|
+
# line 740 "lib/parser/lexer-strings.rl"
|
4507
4507
|
begin
|
4508
4508
|
@te = p+1
|
4509
4509
|
begin
|
@@ -4536,7 +4536,7 @@ p = p - 1; begin
|
|
4536
4536
|
end
|
4537
4537
|
end
|
4538
4538
|
when 64 then
|
4539
|
-
# line
|
4539
|
+
# line 851 "lib/parser/lexer-strings.rl"
|
4540
4540
|
begin
|
4541
4541
|
@te = p+1
|
4542
4542
|
begin
|
@@ -4553,7 +4553,7 @@ p = p - 1; begin
|
|
4553
4553
|
end
|
4554
4554
|
end
|
4555
4555
|
when 65 then
|
4556
|
-
# line
|
4556
|
+
# line 770 "lib/parser/lexer-strings.rl"
|
4557
4557
|
begin
|
4558
4558
|
@te = p+1
|
4559
4559
|
begin
|
@@ -4604,7 +4604,7 @@ p = p - 1; begin
|
|
4604
4604
|
end
|
4605
4605
|
end
|
4606
4606
|
when 66 then
|
4607
|
-
# line
|
4607
|
+
# line 740 "lib/parser/lexer-strings.rl"
|
4608
4608
|
begin
|
4609
4609
|
@te = p+1
|
4610
4610
|
begin
|
@@ -4637,7 +4637,7 @@ p = p - 1; begin
|
|
4637
4637
|
end
|
4638
4638
|
end
|
4639
4639
|
when 67 then
|
4640
|
-
# line
|
4640
|
+
# line 833 "lib/parser/lexer-strings.rl"
|
4641
4641
|
begin
|
4642
4642
|
@te = p
|
4643
4643
|
p = p - 1; begin
|
@@ -4645,7 +4645,7 @@ p = p - 1; begin
|
|
4645
4645
|
end
|
4646
4646
|
end
|
4647
4647
|
when 68 then
|
4648
|
-
# line
|
4648
|
+
# line 822 "lib/parser/lexer-strings.rl"
|
4649
4649
|
begin
|
4650
4650
|
@te = p
|
4651
4651
|
p = p - 1; begin
|
@@ -4655,7 +4655,7 @@ p = p - 1; begin
|
|
4655
4655
|
end
|
4656
4656
|
end
|
4657
4657
|
when 69 then
|
4658
|
-
# line
|
4658
|
+
# line 805 "lib/parser/lexer-strings.rl"
|
4659
4659
|
begin
|
4660
4660
|
@te = p
|
4661
4661
|
p = p - 1; begin
|
@@ -4663,7 +4663,7 @@ p = p - 1; begin
|
|
4663
4663
|
end
|
4664
4664
|
end
|
4665
4665
|
when 70 then
|
4666
|
-
# line
|
4666
|
+
# line 740 "lib/parser/lexer-strings.rl"
|
4667
4667
|
begin
|
4668
4668
|
@te = p
|
4669
4669
|
p = p - 1; begin
|
@@ -4696,7 +4696,7 @@ p = p - 1; begin
|
|
4696
4696
|
end
|
4697
4697
|
end
|
4698
4698
|
when 71 then
|
4699
|
-
# line
|
4699
|
+
# line 740 "lib/parser/lexer-strings.rl"
|
4700
4700
|
begin
|
4701
4701
|
begin p = (( @te))-1; end
|
4702
4702
|
begin
|
@@ -4729,7 +4729,7 @@ p = p - 1; begin
|
|
4729
4729
|
end
|
4730
4730
|
end
|
4731
4731
|
when 72 then
|
4732
|
-
# line
|
4732
|
+
# line 770 "lib/parser/lexer-strings.rl"
|
4733
4733
|
begin
|
4734
4734
|
@te = p+1
|
4735
4735
|
begin
|
@@ -4780,7 +4780,7 @@ p = p - 1; begin
|
|
4780
4780
|
end
|
4781
4781
|
end
|
4782
4782
|
when 73 then
|
4783
|
-
# line
|
4783
|
+
# line 740 "lib/parser/lexer-strings.rl"
|
4784
4784
|
begin
|
4785
4785
|
@te = p+1
|
4786
4786
|
begin
|
@@ -4813,7 +4813,7 @@ p = p - 1; begin
|
|
4813
4813
|
end
|
4814
4814
|
end
|
4815
4815
|
when 74 then
|
4816
|
-
# line
|
4816
|
+
# line 805 "lib/parser/lexer-strings.rl"
|
4817
4817
|
begin
|
4818
4818
|
@te = p
|
4819
4819
|
p = p - 1; begin
|
@@ -4821,7 +4821,7 @@ p = p - 1; begin
|
|
4821
4821
|
end
|
4822
4822
|
end
|
4823
4823
|
when 75 then
|
4824
|
-
# line
|
4824
|
+
# line 937 "lib/parser/lexer-strings.rl"
|
4825
4825
|
begin
|
4826
4826
|
@te = p+1
|
4827
4827
|
begin
|
@@ -4838,7 +4838,7 @@ p = p - 1; begin
|
|
4838
4838
|
end
|
4839
4839
|
end
|
4840
4840
|
when 76 then
|
4841
|
-
# line
|
4841
|
+
# line 924 "lib/parser/lexer-strings.rl"
|
4842
4842
|
begin
|
4843
4843
|
@te = p
|
4844
4844
|
p = p - 1; begin
|
@@ -4860,7 +4860,7 @@ p = p - 1; begin
|
|
4860
4860
|
end
|
4861
4861
|
end
|
4862
4862
|
when 77 then
|
4863
|
-
# line
|
4863
|
+
# line 962 "lib/parser/lexer-strings.rl"
|
4864
4864
|
begin
|
4865
4865
|
@te = p+1
|
4866
4866
|
begin
|
@@ -4879,7 +4879,7 @@ p = p - 1; begin
|
|
4879
4879
|
end
|
4880
4880
|
end
|
4881
4881
|
when 78 then
|
4882
|
-
# line
|
4882
|
+
# line 955 "lib/parser/lexer-strings.rl"
|
4883
4883
|
begin
|
4884
4884
|
@te = p
|
4885
4885
|
p = p - 1; begin
|
@@ -4895,7 +4895,7 @@ p = p - 1; begin
|
|
4895
4895
|
end
|
4896
4896
|
end
|
4897
4897
|
when 79 then
|
4898
|
-
# line
|
4898
|
+
# line 973 "lib/parser/lexer-strings.rl"
|
4899
4899
|
begin
|
4900
4900
|
@te = p
|
4901
4901
|
p = p - 1; begin
|
@@ -4911,7 +4911,7 @@ p = p - 1; begin
|
|
4911
4911
|
end
|
4912
4912
|
end
|
4913
4913
|
when 80 then
|
4914
|
-
# line
|
4914
|
+
# line 955 "lib/parser/lexer-strings.rl"
|
4915
4915
|
begin
|
4916
4916
|
begin p = (( @te))-1; end
|
4917
4917
|
begin
|
@@ -4927,7 +4927,7 @@ p = p - 1; begin
|
|
4927
4927
|
end
|
4928
4928
|
end
|
4929
4929
|
when 81 then
|
4930
|
-
# line
|
4930
|
+
# line 981 "lib/parser/lexer-strings.rl"
|
4931
4931
|
begin
|
4932
4932
|
@te = p+1
|
4933
4933
|
begin raise 'bug' end
|
@@ -5338,6 +5338,15 @@ p = p - 1; begin
|
|
5338
5338
|
break
|
5339
5339
|
end
|
5340
5340
|
|
5341
|
+
# UTF-16 surrogate pairs. These are actually accepted before Ruby 2.4
|
5342
|
+
# but can't be represented in the AST. Make them a syntax error in
|
5343
|
+
# all versions instead, Ruby would raise an exception otherwise.
|
5344
|
+
if codepoint & 0xfffff800 == 0xd800
|
5345
|
+
diagnostic :error, :invalid_unicode_escape, nil,
|
5346
|
+
range(codepoint_s, codepoint_s + codepoint_str.length)
|
5347
|
+
break
|
5348
|
+
end
|
5349
|
+
|
5341
5350
|
@escape += codepoint.chr(Encoding::UTF_8)
|
5342
5351
|
codepoint_s += codepoint_str.length
|
5343
5352
|
end
|
@@ -5417,7 +5426,7 @@ p = p - 1; begin
|
|
5417
5426
|
}
|
5418
5427
|
|
5419
5428
|
|
5420
|
-
# line
|
5429
|
+
# line 984 "lib/parser/lexer-strings.rl"
|
5421
5430
|
|
5422
5431
|
# %
|
5423
5432
|
|
data/lib/parser/ruby27.rb
CHANGED
@@ -10871,11 +10871,12 @@ end
|
|
10871
10871
|
|
10872
10872
|
def _reduce_527(val, _values, result)
|
10873
10873
|
name = val[1][0]
|
10874
|
+
lvar = @builder.accessible(@builder.ident(val[1]))
|
10875
|
+
|
10874
10876
|
unless static_env.declared?(name)
|
10875
10877
|
diagnostic :error, :undefined_lvar, { :name => name }, val[1]
|
10876
10878
|
end
|
10877
10879
|
|
10878
|
-
lvar = @builder.accessible(@builder.ident(val[1]))
|
10879
10880
|
result = @builder.pin(val[0], lvar)
|
10880
10881
|
|
10881
10882
|
result
|
data/lib/parser/ruby30.rb
CHANGED
@@ -11162,11 +11162,12 @@ end
|
|
11162
11162
|
|
11163
11163
|
def _reduce_538(val, _values, result)
|
11164
11164
|
name = val[1][0]
|
11165
|
+
lvar = @builder.accessible(@builder.ident(val[1]))
|
11166
|
+
|
11165
11167
|
unless static_env.declared?(name)
|
11166
11168
|
diagnostic :error, :undefined_lvar, { :name => name }, val[1]
|
11167
11169
|
end
|
11168
11170
|
|
11169
|
-
lvar = @builder.accessible(@builder.ident(val[1]))
|
11170
11171
|
result = @builder.pin(val[0], lvar)
|
11171
11172
|
|
11172
11173
|
result
|
data/lib/parser/ruby31.rb
CHANGED
@@ -11589,11 +11589,12 @@ end
|
|
11589
11589
|
|
11590
11590
|
def _reduce_548(val, _values, result)
|
11591
11591
|
name = val[1][0]
|
11592
|
+
lvar = @builder.accessible(@builder.ident(val[1]))
|
11593
|
+
|
11592
11594
|
unless static_env.declared?(name)
|
11593
11595
|
diagnostic :error, :undefined_lvar, { :name => name }, val[1]
|
11594
11596
|
end
|
11595
11597
|
|
11596
|
-
lvar = @builder.accessible(@builder.ident(val[1]))
|
11597
11598
|
result = @builder.pin(val[0], lvar)
|
11598
11599
|
|
11599
11600
|
result
|