[ruby/yarp] Better Node#pretty_print
Respect the current indentation https://github.com/ruby/yarp/commit/068333ef49
This commit is contained in:
parent
a71001d341
commit
4da53fd3a7
@ -307,7 +307,10 @@ module YARP
|
||||
end
|
||||
|
||||
def pretty_print(q)
|
||||
q.text(inspect.chomp)
|
||||
q.seplist(inspect.chomp.each_line, -> { q.breakable }) do |line|
|
||||
q.text(line.chomp)
|
||||
end
|
||||
q.current_group.break
|
||||
end
|
||||
end
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user