Project

General

Profile

Actions

Bug #8041

closed

Marshal incompatibility with prepend

Added by marcandre (Marc-Andre Lafortune) almost 12 years ago. Updated almost 12 years ago.

Status:
Closed
Assignee:
-
Target version:
ruby -v:
r39629
Backport:
[ruby-core:53202]

Description

=begin
Marshal doesn't work for objects with prepended modules:

o = Object.new
o.singleton_class.send :include, Enumerable
Marshal.load(Marshal.dump(o)) # => ok

o = Object.new
o.singleton_class.send :prepend, Enumerable
Marshal.load(Marshal.dump(o)) # => ArgumentError: Object does not refer to module

=end

Actions

Also available in: Atom PDF

Like0
Like0Like0