aboutsummaryrefslogtreecommitdiffstats
path: root/lib/arel
diff options
context:
space:
mode:
authorNick Kallen <nkallen@nick-kallens-computer-2.local>2008-05-16 13:14:11 -0700
committerNick Kallen <nkallen@nick-kallens-computer-2.local>2008-05-16 13:14:11 -0700
commit6c173acf0a2ccc4907cf55709def5752f59d0167 (patch)
tree88fc9ba6f987877b61dbcb5c107bd678f9dfeb85 /lib/arel
parent0ff5607e1e6e150915543766ac42a292a69fcfd6 (diff)
downloadrails-6c173acf0a2ccc4907cf55709def5752f59d0167.tar.gz
rails-6c173acf0a2ccc4907cf55709def5752f59d0167.tar.bz2
rails-6c173acf0a2ccc4907cf55709def5752f59d0167.zip
cleanup
Diffstat (limited to 'lib/arel')
-rw-r--r--lib/arel/relations/projection.rb5
-rw-r--r--lib/arel/relations/recursion.rb1
-rw-r--r--lib/arel/relations/selection.rb8
3 files changed, 4 insertions, 10 deletions
diff --git a/lib/arel/relations/projection.rb b/lib/arel/relations/projection.rb
index 87b952d672..7c64726852 100644
--- a/lib/arel/relations/projection.rb
+++ b/lib/arel/relations/projection.rb
@@ -14,11 +14,6 @@ module Arel
attributes.any?(&:aggregation?)
end
- # XXX
- def relation_for(attribute)
- self[attribute] && self || relation.relation_for(attribute)
- end
-
def ==(other)
self.class == other.class and
relation == other.relation and
diff --git a/lib/arel/relations/recursion.rb b/lib/arel/relations/recursion.rb
index 1333d7ff57..fa4d9969c9 100644
--- a/lib/arel/relations/recursion.rb
+++ b/lib/arel/relations/recursion.rb
@@ -1,7 +1,6 @@
module Arel
module Recursion
module BaseCase
- # XXX
def table
self
end
diff --git a/lib/arel/relations/selection.rb b/lib/arel/relations/selection.rb
index 0e7615a83c..a37f51c9ec 100644
--- a/lib/arel/relations/selection.rb
+++ b/lib/arel/relations/selection.rb
@@ -8,14 +8,14 @@ module Arel
@predicate = predicate.bind(@relation)
end
+ def selects
+ (relation.selects + [predicate]).collect { |p| p.bind(self) }
+ end
+
def ==(other)
self.class == other.class and
relation == other.relation and
predicate == other.predicate
end
-
- def selects
- (relation.selects + [predicate]).collect { |p| p.bind(self) }
- end
end
end \ No newline at end of file