Module: Poetics::Syntax
- Included in:
- Parser
- Defined in:
- lib/poetics/syntax/ast.rb,
lib/poetics/syntax/node.rb,
lib/poetics/syntax/literal.rb
Defined Under Namespace
Classes: Boolean, False, Node, Null, Number, String, True, Undefined, Value
Instance Method Summary
collapse
Instance Method Details
#false_value ⇒ Object
15
16
17
|
# File 'lib/poetics/syntax/ast.rb', line 15
def false_value
False.new line, column
end
|
#hexadecimal(value) ⇒ Object
7
8
9
|
# File 'lib/poetics/syntax/ast.rb', line 7
def hexadecimal(value)
Number.new line, column, value.to_i(16)
end
|
#null_value ⇒ Object
19
20
21
|
# File 'lib/poetics/syntax/ast.rb', line 19
def null_value
Null.new line, column
end
|
#number(value) ⇒ Object
3
4
5
|
# File 'lib/poetics/syntax/ast.rb', line 3
def number(value)
Number.new line, column, value
end
|
#string_value(value) ⇒ Object
27
28
29
|
# File 'lib/poetics/syntax/ast.rb', line 27
def string_value(value)
String.new line, column, value
end
|
#true_value ⇒ Object
11
12
13
|
# File 'lib/poetics/syntax/ast.rb', line 11
def true_value
True.new line, column
end
|
#undefined_value ⇒ Object
23
24
25
|
# File 'lib/poetics/syntax/ast.rb', line 23
def undefined_value
Undefined.new line, column
end
|