Code Duplication    Length = 6-6 lines in 2 locations

lib/mapper/type/attribute.rb 2 locations

@@ 158-163 (lines=6) @@
155
          def to_def
156
            types = @types ? @types.map(&:to_def).join(', ') : 'none'
157
            message = "#{owner.type}.#{name}"
158
            message += ':virtual' if virtual
159
            "#{message}<#{types}>"
160
          end
161
162
          def to_s
163
            message = "Attribute #{owner.type}.#{name}"
164
            message = "#{message} (virtual)" if virtual
165
            types = @types ? @types.map(&:to_def).join(', ') : 'none'
166
            "#{message} <#{types}>"
@@ 151-156 (lines=6) @@
148
            @owner == other.owner && @name == other.name
149
          end
150
151
          def ==(other)
152
            eql?(other)
153
          end
154
155
          def to_def
156
            types = @types ? @types.map(&:to_def).join(', ') : 'none'
157
            message = "#{owner.type}.#{name}"
158
            message += ':virtual' if virtual
159
            "#{message}<#{types}>"