module Byebug::Helpers::ToggleHelper

def enable_disable_breakpoints(is_enable, args)

def enable_disable_breakpoints(is_enable, args)
  raise pr("toggle.errors.no_breakpoints") if Breakpoint.none?
  select_breakpoints(is_enable, args).each do |b|
    enabled = (is_enable == "enable")
    raise pr("toggle.errors.expression", expr: b.expr) if enabled && !syntax_valid?(b.expr)
    puts pr("toggle.messages.toggled", bpnum: b.id,
                                       endis: enabled ? "en" : "dis")
    b.enabled = enabled
  end
end