class Byebug::UndisplayCommand

def execute

def execute
  if @match[1]
    pos, err = get_int(@match[1], 'Undisplay', 1, @state.display.size)
    return errmsg(err) unless err.nil?
    unless @state.display[pos - 1]
      return errmsg("Display expression #{pos} is not defined.")
    end
    @state.display[pos - 1][0] = nil
  else
    return unless confirm('Clear all expressions? (y/n) ')
    @state.display.each { |d| d[0] = false }
  end
end