summaryrefslogtreecommitdiff
path: root/lib/rbot/irc.rb
diff options
context:
space:
mode:
authorfranz <Franz.Netykafka@runbox.com>2009-06-15 22:07:45 +0200
committerGiuseppe Bilotta <giuseppe.bilotta@gmail.com>2009-08-26 23:31:38 +0200
commitb596f88703fb6d87b1fd16ba33d60efa9261d138 (patch)
treecb3d93253f1caf0bfd6c49f816467c77565d3187 /lib/rbot/irc.rb
parent7cad4b67e17cc734d26fb1366bd90684cc13c470 (diff)
ruby 1.9: disable the Singleton monkeypatch for 1.9
this monkeypatch doesn't work on 1.9 - Singleton has no _load method
Diffstat (limited to 'lib/rbot/irc.rb')
-rw-r--r--lib/rbot/irc.rb2
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/rbot/irc.rb b/lib/rbot/irc.rb
index 9a9998e7..7970a773 100644
--- a/lib/rbot/irc.rb
+++ b/lib/rbot/irc.rb
@@ -24,6 +24,7 @@ require 'singleton'
# The following monkeypatch is to fix a bug in Singleton where marshaling would
# fail when trying to restore a marshaled Singleton due to _load being declared
# private.
+if RUBY_VERSION < '1.9'
module ::Singleton
public :_dump
end
@@ -33,6 +34,7 @@ class << Singleton
public :_load
end
end
+end
class Object