require ‘yaml’
[YAML, Marshal].each do |serializer|
[/ab/x, /a
b/x].each do |regex|
begin
serializer.load(serializer.dump regex)
rescue
p $!
end
end
end
This, in tandem with a few other things, cost me about four hours today (and
made me reconsider my decision to become a nonsmoker -.-).
Is this a bug? If so, where should I report it?
It is probably a bug. It probably won’t ever get fixed as nobody
really maintains syck anymore (tho if you come up with a patch, that’d
certainly help). Try psych if it is possible:
require ‘yaml’
=> true
[YAML, Marshal].each do |serializer|
?> [/ab/x, /a
b/x].each do |regex|
?> begin
?> serializer.load(serializer.dump regex)
rescue
p $!
end
end
end
=> [YAML, Marshal]