Class: Dhaka::LexerSupport::UnaryNode
- Inherits:
-
ASTNode
- Object
- ASTNode
- Dhaka::LexerSupport::UnaryNode
show all
- Defined in:
- lib/lexer/regex_grammar.rb
Instance Attribute Summary collapse
Instance Method Summary
collapse
Methods inherited from ASTNode
#accepting, #checkpoint
Constructor Details
#initialize(child) ⇒ UnaryNode
Returns a new instance of UnaryNode.
262
263
264
|
# File 'lib/lexer/regex_grammar.rb', line 262
def initialize child
@child = child
end
|
Instance Attribute Details
#child ⇒ Object
Returns the value of attribute child.
261
262
263
|
# File 'lib/lexer/regex_grammar.rb', line 261
def child
@child
end
|
Instance Method Details
#calculate_follow_sets ⇒ Object
284
285
286
|
# File 'lib/lexer/regex_grammar.rb', line 284
def calculate_follow_sets
child.calculate_follow_sets
end
|
#first ⇒ Object
276
277
278
|
# File 'lib/lexer/regex_grammar.rb', line 276
def first
child.first
end
|
#last ⇒ Object
280
281
282
|
# File 'lib/lexer/regex_grammar.rb', line 280
def last
child.last
end
|
#nullable ⇒ Object
272
273
274
|
# File 'lib/lexer/regex_grammar.rb', line 272
def nullable
child.nullable
end
|
#to_dot(graph) ⇒ Object
266
267
268
269
270
|
# File 'lib/lexer/regex_grammar.rb', line 266
def to_dot(graph)
graph.node(self, :label => label)
graph.edge(self, child)
child.to_dot(graph)
end
|