From 114f01bd9d1a9dc28d62a1a25b31a210bf871bbc Mon Sep 17 00:00:00 2001 From: nobu Date: Sun, 16 Aug 2009 14:58:27 +0000 Subject: [PATCH] * parse.y (yylex): should dispatch scan-event even when follows just after delayed-token. [ruby-dev:37855] [Bug #1071] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@24557 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- ChangeLog | 5 +++++ parse.y | 1 - test/ripper/test_scanner_events.rb | 5 +++++ 3 files changed, 10 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index c0dbb83b08..cbef75706b 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +Sun Aug 16 23:58:22 2009 Nobuyoshi Nakada + + * parse.y (yylex): should dispatch scan-event even when follows + just after delayed-token. [ruby-dev:37855] [Bug #1071] + Sun Aug 16 22:20:16 2009 Tadayoshi Funaba * lib/date/format.rb: reverted. diff --git a/parse.y b/parse.y index 33660a2d09..41706eaf34 100644 --- a/parse.y +++ b/parse.y @@ -7612,7 +7612,6 @@ yylex(void *p) #ifdef RIPPER if (!NIL_P(parser->delayed)) { ripper_dispatch_delayed_token(parser, t); - return t; } if (t != 0) ripper_dispatch_scan_event(parser, t); diff --git a/test/ripper/test_scanner_events.rb b/test/ripper/test_scanner_events.rb index 4389946104..6599165700 100644 --- a/test/ripper/test_scanner_events.rb +++ b/test/ripper/test_scanner_events.rb @@ -63,6 +63,11 @@ class TestRipper_ScannerEvents < Test::Unit::TestCase [[2, 0], :on_tstring_content, "heredoc\n"], [[3, 0], :on_heredoc_end, "EOS"]], Ripper.lex("<