aboutsummaryrefslogtreecommitdiffstats
path: root/activesupport/lib/active_support/core_ext/symbol.rb
diff options
context:
space:
mode:
Diffstat (limited to 'activesupport/lib/active_support/core_ext/symbol.rb')
-rw-r--r--activesupport/lib/active_support/core_ext/symbol.rb5
1 files changed, 5 insertions, 0 deletions
diff --git a/activesupport/lib/active_support/core_ext/symbol.rb b/activesupport/lib/active_support/core_ext/symbol.rb
new file mode 100644
index 0000000000..cd928aae80
--- /dev/null
+++ b/activesupport/lib/active_support/core_ext/symbol.rb
@@ -0,0 +1,5 @@
+class Symbol #:nodoc:
+ def to_proc
+ Proc.new { |obj, *args| obj.send(self, *args) }
+ end
+end