summaryrefslogtreecommitdiff
path: root/ext/fiddle/lib/fiddle/function.rb
diff options
context:
space:
mode:
Diffstat (limited to 'ext/fiddle/lib/fiddle/function.rb')
-rw-r--r--ext/fiddle/lib/fiddle/function.rb3
1 files changed, 2 insertions, 1 deletions
diff --git a/ext/fiddle/lib/fiddle/function.rb b/ext/fiddle/lib/fiddle/function.rb
index f9910a0524..dc2e3e6bf5 100644
--- a/ext/fiddle/lib/fiddle/function.rb
+++ b/ext/fiddle/lib/fiddle/function.rb
@@ -22,7 +22,8 @@ module Fiddle
# Turn this function in to a proc
def to_proc
- lambda { |*args| self.call(*args) }
+ this = self
+ lambda { |*args| this.call(*args) }
end
end
end