Class: Module
- Inherits:
-
Object
- Object
- Module
- Defined in:
- lib/rake.rb
Instance Method Summary collapse
-
#const_missing(const_name) ⇒ Object
Check for deprecated uses of top level (i.e. in Object) uses of Rake class names.
-
#rake_original_const_missing ⇒ Object
Rename the original handler to make it available.
Instance Method Details
#const_missing(const_name) ⇒ Object
Check for deprecated uses of top level (i.e. in Object) uses of Rake class names. If someone tries to reference the constant name, display a warning and return the proper object. Using the –classic-namespace command line option will define these constants in Object and avoid this handler.
1933 1934 1935 1936 1937 1938 1939 1940 1941 1942 1943 1944 1945 1946 1947 1948 1949 1950 |
# File 'lib/rake.rb', line 1933 def const_missing(const_name) case const_name when :Task Rake.application.const_warning(const_name) Rake::Task when :FileTask Rake.application.const_warning(const_name) Rake::FileTask when :FileCreationTask Rake.application.const_warning(const_name) Rake::FileCreationTask when :RakeApp Rake.application.const_warning(const_name) Rake::Application else rake_original_const_missing(const_name) end end |
#rake_original_const_missing ⇒ Object
Rename the original handler to make it available.
1926 |
# File 'lib/rake.rb', line 1926 alias :rake_original_const_missing :const_missing |