# File Ouroboros.rb, line 240 def delete( obj ) return nil unless obj.respond_to?(:_ouroboros_index) && obj._ouroboros_index && @all[obj._ouroboros_index].eql?( obj ) if obj.eql?( @current ) @current = obj.next @current_index = obj.next._ouroboros_index end @all.delete_at( obj._ouroboros_index ) obj.next = obj.prev = obj._ouroboros_index = nil sync_from_array obj end