aboutsummaryrefslogtreecommitdiffstats
path: root/activesupport/lib/active_support/core_ext
diff options
context:
space:
mode:
authorDavid Heinemeier Hansson <david@loudthinking.com>2007-04-28 15:57:29 +0000
committerDavid Heinemeier Hansson <david@loudthinking.com>2007-04-28 15:57:29 +0000
commit70ac560e42644938392381ecd52efd7fb0260323 (patch)
treedbc0bc73d480bf3af99aef2f4be16afa183f4850 /activesupport/lib/active_support/core_ext
parent1d5c34c2c27370356e8cd1ef478111802b6a5af4 (diff)
downloadrails-70ac560e42644938392381ecd52efd7fb0260323.tar.gz
rails-70ac560e42644938392381ecd52efd7fb0260323.tar.bz2
rails-70ac560e42644938392381ecd52efd7fb0260323.zip
Removed breakpointer and Binding.of_caller in favor of relying on ruby-debug by Kent Sibilev since the breakpointer has been broken since Ruby 1.8.4 and will not be coming back [DHH]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6611 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
Diffstat (limited to 'activesupport/lib/active_support/core_ext')
-rw-r--r--activesupport/lib/active_support/core_ext/kernel.rb1
-rw-r--r--activesupport/lib/active_support/core_ext/kernel/debugger.rb13
2 files changed, 14 insertions, 0 deletions
diff --git a/activesupport/lib/active_support/core_ext/kernel.rb b/activesupport/lib/active_support/core_ext/kernel.rb
index 1aa4f72b45..6475be7efa 100644
--- a/activesupport/lib/active_support/core_ext/kernel.rb
+++ b/activesupport/lib/active_support/core_ext/kernel.rb
@@ -2,3 +2,4 @@ require File.dirname(__FILE__) + '/kernel/daemonizing'
require File.dirname(__FILE__) + '/kernel/reporting'
require File.dirname(__FILE__) + '/kernel/agnostics'
require File.dirname(__FILE__) + '/kernel/requires'
+require File.dirname(__FILE__) + '/kernel/debugger'
diff --git a/activesupport/lib/active_support/core_ext/kernel/debugger.rb b/activesupport/lib/active_support/core_ext/kernel/debugger.rb
new file mode 100644
index 0000000000..c74d6cf884
--- /dev/null
+++ b/activesupport/lib/active_support/core_ext/kernel/debugger.rb
@@ -0,0 +1,13 @@
+module Kernel
+ unless respond_to?(:debugger)
+ # Starts a debugging session if ruby-debug has been loaded (call script/server --debugger to do load it).
+ def debugger
+ RAILS_DEFAULT_LOGGER.info "\n***** Debugger requested, but was not available: Start server with --debugger to enable *****\n"
+ end
+ end
+
+ def breakpoint
+ RAILS_DEFAULT_LOGGER.info "\n***** The 'breakpoint' command has been renamed 'debugger' -- please change *****\n"
+ debugger
+ end
+end \ No newline at end of file