[ruby-core:104916] [Ruby master Bug#18075] Crasher using ripper + yydebug
From:
ryand-ruby@...
Date:
2021-08-14 04:20:07 UTC
List:
ruby-core #104916
Issue #18075 has been reported by zenspider (Ryan Davis).
----------------------------------------
Bug #18075: Crasher using ripper + yydebug
https://bugs.ruby-lang.org/issues/18075
* Author: zenspider (Ryan Davis)
* Status: Open
* Priority: Normal
* Backport: 2.6: UNKNOWN, 2.7: UNKNOWN, 3.0: UNKNOWN
----------------------------------------
`method `inspect' called on unexpected T_NODE object` via the following with `-d` (see output at end):
```
#!/usr/bin/env ruby -wvs
$d ||= false
require "ripper/sexp"
src = "'woot'"
rip = Ripper::SexpBuilderPP.new src
rip.yydebug = $d
p rip.parse # boom
__END__
############################################################
% % multiruby ./ripper_bug.rb
...
Passed: 2.3.8, 2.4.9, 2.5.8, 2.6.6, 2.7.3, 3.0.1 master
Failed:
############################################################
% multiruby ./ripper_bug.rb -d
...
Entering state 299
./ripper_bug.rb:11:in `parse': method `inspect' called on unexpected T_NODE object (0x000000012f8db898 flags=0x1e1b) (NotImplementedError)
from ./ripper_bug.rb:11:in `<main>'
RESULT = pid 24703 exit 1
TOTAL RESULT = 3 failures out of 6
Passed: 2.3.8, 2.4.9, 2.5.8
Failed: 2.6.6, 2.7.3, 3.0.1, master
```
Exists on 2.6 and up
--
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>