Class: Depager::LALR::AdvancedParser
- Extended by:
- Forwardable
- Defined in:
- lib/depager/parser.rb
Direct Known Subclasses
Constant Summary
Constants inherited from Parser
Instance Attribute Summary collapse
-
#basis ⇒ Object
readonly
Returns the value of attribute basis.
-
#decorator_index ⇒ Object
readonly
Returns the value of attribute decorator_index.
Instance Method Summary collapse
- #accept ⇒ Object
- #error ⇒ Object
-
#initialize(inside) ⇒ AdvancedParser
constructor
A new instance of AdvancedParser.
- #reduce ⇒ Object
- #shift ⇒ Object
Methods inherited from Parser
#action_table, #defred_after_shift_table, #defred_table, #goto_table, #int_to_nonterm, #int_to_term, #lex, #nonterm_to_int, #parse, #reduce_table, #term_to_int
Constructor Details
#initialize(inside) ⇒ AdvancedParser
Returns a new instance of AdvancedParser.
202 203 204 205 206 207 |
# File 'lib/depager/parser.rb', line 202 def initialize(inside) @inside = inside @basis = inside.basis @decorator_index = @basis.next_decorator_index super() end |
Instance Attribute Details
#basis ⇒ Object (readonly)
Returns the value of attribute basis.
200 201 202 |
# File 'lib/depager/parser.rb', line 200 def basis @basis end |
#decorator_index ⇒ Object (readonly)
Returns the value of attribute decorator_index.
200 201 202 |
# File 'lib/depager/parser.rb', line 200 def decorator_index @decorator_index end |
Instance Method Details
#accept ⇒ Object
209 210 211 212 213 |
# File 'lib/depager/parser.rb', line 209 def accept before_accept @inside.accept after_accept end |
#error ⇒ Object
215 216 217 218 219 |
# File 'lib/depager/parser.rb', line 215 def error before_error @inside.error after_error end |
#reduce ⇒ Object
227 228 229 230 231 |
# File 'lib/depager/parser.rb', line 227 def reduce before_reduce @inside.reduce after_reduce end |
#shift ⇒ Object
221 222 223 224 225 |
# File 'lib/depager/parser.rb', line 221 def shift before_shift @inside.shift after_shift end |