summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog5
-rw-r--r--lib/set.rb8
2 files changed, 9 insertions, 4 deletions
diff --git a/ChangeLog b/ChangeLog
index 2540307c53..3fabddb14a 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+Sat Nov 23 08:23:23 2013 Aman Gupta <ruby@tmm1.net>
+
+ * lib/set.rb (class SortedSet): Fix source_location for methods
+ defined via eval.
+
Sat Nov 23 03:44:03 2013 Eric Hodel <drbrain@segment7.net>
* lib/rubygems: Update to RubyGems master dcce4ff. Important changes
diff --git a/lib/set.rb b/lib/set.rb
index cc068f0a52..e30d590c5d 100644
--- a/lib/set.rb
+++ b/lib/set.rb
@@ -574,7 +574,7 @@ class SortedSet < Set
begin
require 'rbtree'
- module_eval %{
+ module_eval <<-END, __FILE__, __LINE__+1
def initialize(*args)
@hash = RBTree.new
super
@@ -585,9 +585,9 @@ class SortedSet < Set
super
end
alias << add
- }
+ END
rescue LoadError
- module_eval %{
+ module_eval <<-END, __FILE__, __LINE__+1
def initialize(*args)
@keys = nil
super
@@ -647,7 +647,7 @@ class SortedSet < Set
(@keys = @hash.keys).sort! unless @keys
@keys
end
- }
+ END
end
module_eval {
# a hack to shut up warning