Class: Spoom::Sorbet::Sigs::RBSToRBITranslator

Inherits:
Object
  • Object
show all
Extended by:
T::Sig
Defined in:
lib/spoom/sorbet/sigs.rb

Class Method Summary collapse

Class Method Details

.translate(comment, node) ⇒ Object

: (RBI::RBSComment comment, (RBI::Method | RBI::Attr) node) -> String



183
184
185
186
187
188
189
190
# File 'lib/spoom/sorbet/sigs.rb', line 183

def translate(comment, node)
  case node
  when RBI::Method
    translate_method_sig(comment, node)
  when RBI::Attr
    translate_attr_sig(comment, node)
  end
end