Class: TurboTest::StaticAnalysis::ActiveRecord::LineStackSexpBuilder
- Inherits:
-
Ripper::SexpBuilder
- Object
- Ripper::SexpBuilder
- TurboTest::StaticAnalysis::ActiveRecord::LineStackSexpBuilder
- Defined in:
- lib/turbo_test_static_analysis/active_record_schema/sexp_builder/line_stack_sexp_builder.rb
Direct Known Subclasses
Constant Summary collapse
- EVENTS_TO_REJECT =
[:magic_comment].freeze
- ARITIES =
["()", "(a)", "(a,b)", "(a,b,c)", "(a,b,c,d)", "(a,b,c,d,e)", "(a,b,c,d,e,f)", "(a,b,c,d,e,f,g)", "(a,b,c,d,e,f,g,h)"].freeze
Instance Attribute Summary collapse
-
#stack ⇒ Object
readonly
Returns the value of attribute stack.
Instance Method Summary collapse
-
#initialize(path, filename = "-", lineno = 1) ⇒ LineStackSexpBuilder
constructor
A new instance of LineStackSexpBuilder.
- #stack_line ⇒ Object
Constructor Details
#initialize(path, filename = "-", lineno = 1) ⇒ LineStackSexpBuilder
Returns a new instance of LineStackSexpBuilder.
29 30 31 32 |
# File 'lib/turbo_test_static_analysis/active_record_schema/sexp_builder/line_stack_sexp_builder.rb', line 29 def initialize(path, filename = "-", lineno = 1) super @stack = LineColumnStack.new end |
Instance Attribute Details
#stack ⇒ Object (readonly)
Returns the value of attribute stack.
27 28 29 |
# File 'lib/turbo_test_static_analysis/active_record_schema/sexp_builder/line_stack_sexp_builder.rb', line 27 def stack @stack end |
Instance Method Details
#stack_line ⇒ Object
34 35 36 |
# File 'lib/turbo_test_static_analysis/active_record_schema/sexp_builder/line_stack_sexp_builder.rb', line 34 def stack_line @stack.push lineno, column end |