Actions
Bug #790
closedUnexpected Behaviour: Fibers as superclass don
Description
=begin
This is possibly just undocumented and intended behaviour:
=end
Updated by Skade (Florian Gilcher) about 16 years ago
=begin
Sorry, hit the wrong button:
Fibers as superclass don't call initialize of derived class. This is probably intended, but not documented.
Description by Wolfgang NĂ¡dasi-Donner:
The following code...
class Hugo < Fiber
def initialize(&b)
puts "in 'Hugo'" # !!! never executed !!!
super(&b)
end
end
h = Hugo.new{42}
p h
...results in...
ruby19 myfiber_test.rb
#Hugo:0xb24ee0
Exit code: 0
...which I didn't expect.
=end
Updated by matz (Yukihiro Matsumoto) about 16 years ago
- Status changed from Open to Closed
- % Done changed from 0 to 100
=begin
Applied in changeset r20388.
=end
Actions
Like0
Like0Like0