rbs
rbs copied to clipboard
bin/sort sorts private as though it were a method
private and protected shouldn't be sorted by bin/sort.
Input:
module Foo
def baz: (*untyped) -> untyped
private
def foo: (*untyped) -> untyped
def bar: (*untyped) -> untyped
end
Output:
module Foo
private
def bar: (*untyped) -> untyped
def baz: (*untyped) -> untyped
def foo: (*untyped) -> untyped
end
What I'd expect the output to look like, with the private methods sorted within themselves:
module Foo
def baz: (*untyped) -> untyped
private
def bar: (*untyped) -> untyped
def foo: (*untyped) -> untyped
end