class Byebug::UndisplayCommand

def execute

def execute
  if @match[1]
    pos, err = get_int(@match[1], "Undisplay", 1, Byebug.displays.size)
    return errmsg(err) unless err.nil?
    last_display = Byebug.displays[pos - 1]
    return errmsg(pr("display.errors.undefined", expr: pos)) unless last_display
    last_display[0] = nil
  else
    return unless confirm(pr("display.confirmations.clear_all"))
    Byebug.displays.each { |d| d[0] = false }
  end
end