Index:spec/symbolic_operators_spec.rb===================================================================--- spec/symbolic_operators_spec.rb (revision 738)
+++ spec/symbolic_operators_spec.rb (working copy)
@@-24,4 +24,10@@ it 'age should not be nil' do
Person.all(:age.not => nil).size.should == 5
end
++ it "should be equivalent" do
+ :age.not.should == :age.not
++ {:age.not => 12}.has_key?(:age.not).should == true
+ end
end
\ No newline at end of file
Index:lib/data_mapper/support/symbol.rb===================================================================--- lib/data_mapper/support/symbol.rb (revision 738)
+++ lib/data_mapper/support/symbol.rb (working copy)
@@-15,6 +15,10@@ def to_sym
@value
end
++ def ==(other)
+ (@value == other.value) && (@type == other.type) && (@options == other.options)
+ end
end
def gt