Module: ImproveYourCode::AST::SexpExtensions::CasgnNode
- Includes:
- ConstantDefiningNodeBase
- Defined in:
- lib/improve_your_code/ast/sexp_extensions/module.rb
Instance Method Summary collapse
Methods included from ConstantDefiningNodeBase
Instance Method Details
#defines_module? ⇒ Boolean
35 36 37 38 |
# File 'lib/improve_your_code/ast/sexp_extensions/module.rb', line 35 def defines_module? call = constant_definition call&.module_creation_call? end |
#name ⇒ Object
40 41 42 |
# File 'lib/improve_your_code/ast/sexp_extensions/module.rb', line 40 def name children[1].to_s end |
#value ⇒ Object
44 45 46 |
# File 'lib/improve_your_code/ast/sexp_extensions/module.rb', line 44 def value children[2] end |