Skip to content
5 changes: 5 additions & 0 deletions lib/rbi/index.rb
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,11 @@ def visit(node)
end
end

#: -> String
def to_s
"#<RBI::Index #{@index.filter { |_, v| v.any? }.keys.sort}>"
end

private

#: ((Indexable & Node) node) -> void
Expand Down
2 changes: 1 addition & 1 deletion lib/rbi/model.rb
Original file line number Diff line number Diff line change
Expand Up @@ -297,7 +297,7 @@ class Attr < NodeWithComments
attr_accessor :visibility

#: Array[Sig]
attr_reader :sigs
attr_accessor :sigs

#: (Symbol name, Array[Symbol] names, ?visibility: Visibility, ?sigs: Array[Sig], ?loc: Loc?, ?comments: Array[Comment]) -> void
def initialize(name, names, visibility: Public.new, sigs: [], loc: nil, comments: [])
Expand Down
Loading
Loading