1
0

178 lines
4.7 KiB
Plaintext
Raw Normal View History

2023-11-10 20:44:03 -05:00
================================================================================
2023-10-31 05:51:37 -04:00
Simple Indexes
2023-11-10 20:44:03 -05:00
================================================================================
dust_data:1:name
creature:total_clams
foobar:1:42
2023-11-10 20:44:03 -05:00
--------------------------------------------------------------------------------
(root
2023-11-10 20:44:03 -05:00
(statement
(expression
(index
(index_expression
2023-10-31 05:51:37 -04:00
(index
(index_expression
2023-11-10 20:44:03 -05:00
(identifier))
(index_expression
2023-10-31 05:51:37 -04:00
(value
2023-11-10 20:44:03 -05:00
(integer)))))
(index_expression
2023-11-10 20:44:03 -05:00
(identifier)))))
(statement
(expression
(index
(index_expression
2023-11-10 20:44:03 -05:00
(identifier))
(index_expression
2023-11-10 20:44:03 -05:00
(identifier)))))
(statement
(expression
(index
(index_expression
2023-11-10 20:44:03 -05:00
(index
(index_expression
2023-11-10 20:44:03 -05:00
(identifier))
(index_expression
2023-11-10 20:44:03 -05:00
(value
(integer)))))
(index_expression
2023-11-10 20:44:03 -05:00
(value
(integer)))))))
2023-10-31 05:51:37 -04:00
2023-11-10 20:44:03 -05:00
================================================================================
2023-10-31 05:51:37 -04:00
Nested Indexes
2023-11-10 20:44:03 -05:00
================================================================================
2023-10-31 05:51:37 -04:00
[['answers' 'foobar'], 42, 666]:0:1:0..2
2023-11-10 20:44:03 -05:00
--------------------------------------------------------------------------------
(root
2023-11-10 20:44:03 -05:00
(statement
(expression
(index
(index_expression
2023-10-31 05:51:37 -04:00
(index
(index_expression
2023-10-31 05:51:37 -04:00
(index
(index_expression
2023-11-10 20:44:03 -05:00
(value
(list
(expression
(value
(list
(expression
(value
(string)))
(expression
(value
(string))))))
(expression
(value
(integer)))
(expression
(value
(integer))))))
(index_expression
(value
2023-10-31 05:51:37 -04:00
(integer)))))
(index_expression
2023-10-31 05:51:37 -04:00
(value
2023-11-10 20:44:03 -05:00
(integer)))))
(index_expression
2023-11-10 20:44:03 -05:00
(value
(integer)))
(expression
(value
(integer)))))))
2023-11-14 18:56:44 -05:00
================================================================================
Function Call Index
================================================================================
x:(y()):0
2023-11-14 18:56:44 -05:00
--------------------------------------------------------------------------------
(root
(statement
(expression
(index
(index_expression
2023-11-14 18:56:44 -05:00
(index
(index_expression
2023-11-14 18:56:44 -05:00
(identifier))
(index_expression
2023-11-30 11:05:09 -05:00
(function_call
(function_expression
2023-12-02 02:34:23 -05:00
(identifier))))))
(index_expression
2023-11-14 18:56:44 -05:00
(value
(integer)))))))
================================================================================
Structure Definition Index
================================================================================
struct {
bar = 1
}:bar
--------------------------------------------------------------------------------
(root
(statement
(expression
(index
(index_expression
(value
(structure_definition
(structure_instantiator
(identifier)
(statement
(expression
(value
(integer))))))))
(index_expression
(identifier))))))
================================================================================
Structure Definition Index Function Call
================================================================================
struct {
bar = () <str> { 'bar' }
}:bar()
--------------------------------------------------------------------------------
(root
(statement
(expression
(function_call
(function_expression
(index
(index_expression
(value
(structure_definition
(structure_instantiator
(identifier)
(statement
(expression
(value
(function
(type_definition
(type))
(block
(statement
(expression
(value
(string)))))))))))))
(index_expression
(identifier))))))))