class Rufo::Formatter
def visit_call_without_receiver(node)
def visit_call_without_receiver(node) # foo(arg1, ..., argN) # # [:method_add_arg, # [:fcall, [:@ident, "foo", [1, 0]]], # [:arg_paren, [:args_add_block, [[:@int, "1", [1, 6]]], false]]] _, name, args = node @name_dot_column = nil visit name # Some times a call comes without parens (should probably come as command, but well...) return if args.empty? # Remember dot column so it's not affected by args dot_column = @dot_column original_dot_column = @original_dot_column want_indent = @name_dot_column && @name_dot_column > @indent maybe_indent(want_indent, @name_dot_column) do visit_call_at_paren(node, args) end # Restore dot column so it's not affected by args @dot_column = dot_column @original_dot_column = original_dot_column end