class RuboCop::Cop::Performance::RedundantStringChars

def build_bad_method(method, args)

def build_bad_method(method, args)
  case method
  when :[]
    "chars[#{build_call_args(args)}]"
  else
    if args.any?
      "chars.#{method}(#{build_call_args(args)})"
    else
      "chars.#{method}"
    end
  end
end