diff options
author | Aaron Patterson <aaron.patterson@gmail.com> | 2010-07-25 18:17:54 -0700 |
---|---|---|
committer | Aaron Patterson <aaron.patterson@gmail.com> | 2010-07-25 18:17:54 -0700 |
commit | edb786204fb45ba2a877ec7a3b26e84119b13377 (patch) | |
tree | 55c3b9d477ac55d4b027afd88c1983ae93313f47 /lib | |
parent | b0bef671e883eb4fba01d0295069e4b52d3328b1 (diff) | |
download | rails-edb786204fb45ba2a877ec7a3b26e84119b13377.tar.gz rails-edb786204fb45ba2a877ec7a3b26e84119b13377.tar.bz2 rails-edb786204fb45ba2a877ec7a3b26e84119b13377.zip |
removing unused file
Diffstat (limited to 'lib')
-rw-r--r-- | lib/arel/algebra/core_extensions.rb | 1 | ||||
-rw-r--r-- | lib/arel/algebra/core_extensions/class.rb | 32 |
2 files changed, 0 insertions, 33 deletions
diff --git a/lib/arel/algebra/core_extensions.rb b/lib/arel/algebra/core_extensions.rb index bce86d04ba..4416ff6b77 100644 --- a/lib/arel/algebra/core_extensions.rb +++ b/lib/arel/algebra/core_extensions.rb @@ -1,4 +1,3 @@ require 'arel/algebra/core_extensions/object' -require 'arel/algebra/core_extensions/class' require 'arel/algebra/core_extensions/symbol' require 'arel/algebra/core_extensions/hash' diff --git a/lib/arel/algebra/core_extensions/class.rb b/lib/arel/algebra/core_extensions/class.rb deleted file mode 100644 index d0894931da..0000000000 --- a/lib/arel/algebra/core_extensions/class.rb +++ /dev/null @@ -1,32 +0,0 @@ -module Arel - module ClassExtensions - def attributes(*attrs) - @attributes = attrs - attr_reader(*attrs) - end - - def deriving(*methods) - methods.each { |m| derive m } - end - - def derive(method_name) - methods = { - :initialize => " - def #{method_name}(#{@attributes.join(',')}) - #{@attributes.collect { |a| "@#{a} = #{a}" }.join("\n")} - end - ", - :== => " - def ==(other) - #{name} === other && - #{@attributes.collect { |a| "@#{a} == other.#{a}" }.join(" &&\n")} - end - " - } - class_eval methods[method_name], __FILE__, __LINE__ - end - - Class.send(:include, self) - end -end - |