Class: RBI::Rewriters::Deannotate
- Extended by:
- T::Sig
- Defined in:
- lib/rbi/rewriters/deannotate.rb
Instance Method Summary collapse
-
#initialize(annotation) ⇒ Deannotate
constructor
A new instance of Deannotate.
- #visit(node) ⇒ Object
Methods inherited from Visitor
Constructor Details
#initialize(annotation) ⇒ Deannotate
Returns a new instance of Deannotate.
10 11 12 13 |
# File 'lib/rbi/rewriters/deannotate.rb', line 10 def initialize(annotation) super() @annotation = annotation end |
Instance Method Details
#visit(node) ⇒ Object
16 17 18 19 20 21 22 |
# File 'lib/rbi/rewriters/deannotate.rb', line 16 def visit(node) case node when Scope, Const, Attr, Method, TStructField, TypeMember deannotate_node(node) end visit_all(node.nodes) if node.is_a?(Tree) end |