[#60404] is RB_GC_GUARD needed in rb_io_syswrite? — Eric Wong <normalperson@...>
I haven't gotten it to crash as-is, but it seems like we need to
4 messages
2014/02/01
[#60682] volatile usages — Eric Wong <normalperson@...>
Hi all, I went ahead and removed some use of volatile which were once
5 messages
2014/02/13
[#60794] [RFC] rearrange+pack vtm and time_object structs — Eric Wong <normalperson@...>
Extracted from addendum on top of Feature #9362 (cache-aligned objects).
4 messages
2014/02/16
[#61139] [ruby-trunk - Feature #9577] [Open] [PATCH] benchmark/driver.rb: align columns in text output — normalperson@...
Issue #9577 has been reported by Eric Wong.
3 messages
2014/02/28
[ruby-core:60667] [Backport200 - Backport #9248] Struct methods, segmentation fault
From:
eregontp@...
Date:
2014-02-12 14:48:52 UTC
List:
ruby-core #60667
Issue #9248 has been updated by Benoit Daloze.
This still seems problematic:
c = Struct.new(:a?)
o = c.new(42)
o.send("a?=", 3) rescue p $! # => #<NoMethodError: undefined method `a?=' for #<struct :a?=42>>
p o.a?
p o.methods # removing the "p" here would produce a NoMethodError below, somehow this "fixes" everything
o.send("a?=", 3)
p o.a?
IMHO, adding methods not callable by default because they do not respect the symbol syntax is bad. I would much prefer just to forbid attributes with a final question mark in Struct (or make them behave as the attribute without the "?" and just an extra "#{attr}?" predicate).
----------------------------------------
Backport #9248: Struct methods, segmentation fault
https://bugs.ruby-lang.org/issues/9248#change-45096
* Author: H H
* Status: Closed
* Priority: Normal
* Assignee: Tomoyuki Chikanaga
* Category:
* Target version:
* ruby -v: 2.0.0p353
----------------------------------------
=begin
The following snippet causes segmentation fault:
(({p Struct.new(:method_with_questionmark?).new.methods}))
This happens when accessor method name contains question mark.
=end
--
http://bugs.ruby-lang.org/