-
Notifications
You must be signed in to change notification settings - Fork 52
Open
Description
- Ruby version: 3.1
- Rubyfmt git sha: (if unsure, redownload the latest version and run against that) Stripe's
Input file
def foo(e)
e.to_s.each_line(chomp: true) {
|l| X }
endIn my repro, X was a long namespaced-method call so I was looking to learn whether rubyfmt would recommend to keep as a single line or else.
Rubyfmt's output
def foo(e)
e.to_s.each_line(chomp: true) { |
l
| X }
endThis breaks because
Unexpected formatting, breaking variable declaration across multiple lines seems wrong
- Not to break the declaration of
|l| - Probably, leave as is, make a single line, or ?
def foo(e)
e.to_s.each_line(chomp: true) { |l| X }
end
Metadata
Metadata
Assignees
Labels
No labels