Issue #17547 has been reported by osyo (manga osyo).

----------------------------------------
Bug #17547: Fix `Ripper.lex("a <<b")`
https://bugs.ruby-lang.org/issues/17547

* Author: osyo (manga osyo)
* Status: Open
* Priority: Normal
* ruby -v: ruby 3.0.0p0 (2020-12-25 revision 95aff21468) [x86_64-linux]
* Backport: 2.5: UNKNOWN, 2.6: UNKNOWN, 2.7: UNKNOWN, 3.0: UNKNOWN
----------------------------------------
`Ripper.lex("a <<b")` was not parsed correctly.

```ruby
require "ripper"

p Ripper.lex("a <<b")
# Expected behavior => [[[1, 0], :on_ident, "a", CMDARG], [[1, 1], :on_sp, " ", CMDARG], [[1, 2], :on_heredoc_beg, "<<b", CMDARG]]
# Actual behavior   => [[[1, 2], :on_heredoc_beg, "<<b", CMDARG]]
```

PR: https://github.com/ruby/ruby/pull/4083




-- 
https://bugs.ruby-lang.org/

Unsubscribe: <mailto:ruby-core-request / ruby-lang.org?subject=unsubscribe>
<http://lists.ruby-lang.org/cgi-bin/mailman/options/ruby-core>