aboutsummaryrefslogtreecommitdiffstats
path: root/lib/rake/dsl_definition.rb
diff options
context:
space:
mode:
authordrbrain <drbrain@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2011-08-12 16:56:48 +0000
committerdrbrain <drbrain@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2011-08-12 16:56:48 +0000
commit5caef67a6f19e5c03cc4684532d738e02a694015 (patch)
tree3028b8f201860495a38e149cb89a324869acd159 /lib/rake/dsl_definition.rb
parentda6eec340eb13d0c50431a0661528a7fe300ffda (diff)
downloadruby-5caef67a6f19e5c03cc4684532d738e02a694015.tar.gz
* lib/rake: Update to Rake 0.9.2.2. Prevent pollution of toplevel
namespace by Commands. Remove unused variable and debugging statement in tests. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@32948 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'lib/rake/dsl_definition.rb')
-rw-r--r--lib/rake/dsl_definition.rb8
1 files changed, 5 insertions, 3 deletions
diff --git a/lib/rake/dsl_definition.rb b/lib/rake/dsl_definition.rb
index 3294f9e6c0..6d9a6b88f3 100644
--- a/lib/rake/dsl_definition.rb
+++ b/lib/rake/dsl_definition.rb
@@ -144,10 +144,12 @@ module Rake
Rake.application.add_import(fn)
end
end
+
end
+ DeprecatedCommands = Object.new.extend(DSL)
+
module DeprecatedObjectDSL # :nodoc:
- Commands = Object.new.extend DSL
DSL.private_instance_methods(false).each do |name|
line = __LINE__+1
class_eval %{
@@ -160,8 +162,8 @@ module Rake
end
$stderr.puts "WARNING: DSL method \#{self.class}##{name} called at \#{caller.first}"
end
- Rake::DeprecatedObjectDSL::Commands.send(:#{name}, *args, &block)
- end
+ Rake::DeprecatedCommands.send(:#{name}, *args, &block)
+ end
private :#{name}
}, __FILE__, line
end