Olivier Goffart
e3459f39d4
Parse two ways bindings
2020-09-23 14:06:08 +02:00
Olivier Goffart
e0ed5252a8
Parse type declaration
...
```
export Foo := {
property <int> xxx;
}
```
2020-09-16 18:26:13 +02:00
Olivier Goffart
c809638003
Parse signal handler with arguments (parsing only)
2020-09-07 18:14:17 +02:00
Olivier Goffart
9f026c820d
Parse declaration of signal with arguments
2020-09-07 17:41:24 +02:00
Olivier Goffart
9d405060e2
Parse object and array type
2020-09-03 07:43:20 +02:00
Patrick José Pereira
b63852967e
sixtyfps_compiler: parser: Move code to use new nth and kind functions
...
Signed-off-by: Patrick José Pereira <patrickelectric@gmail.com>
2020-08-31 15:02:41 +02:00
Simon Hausmann
c1aa4b28c6
Add support for children insertion points for components
...
Sometimes re-usable components need to act as containers that allow the
user to place other items inside. The component needs to be able to
control the placement of these user-provided elements. That is what the
new
$children
expression inside elements does.
2020-08-28 15:05:21 +02:00
Olivier Goffart
58cdaeb8dd
Update license header to mention that commertial option are available
2020-08-26 13:23:42 +02:00
Simon Hausmann
2823f32692
Apply license headers to all non-binary/non-json sources
2020-08-17 17:55:20 +02:00
Olivier Goffart
0199b70cea
if
statements
2020-08-04 17:36:20 +02:00
Simon Hausmann
84406cc70b
Add support for renaming imports
...
This is very useful to avoid name clashes.
2020-07-23 10:12:45 +02:00
Simon Hausmann
0b5f4054ea
Improve import uri parsing
...
Avoid unnecessary SyntaxKind variants. The import uri is simply the first string literal in the ImportSpecifier.
Also covert the case of an empty import list and use expect() instead of
test() to produce a meaningful error message.
2020-07-22 14:06:42 +02:00
Simon Hausmann
3e619170cd
Extend the parser with support for import statements
2020-07-22 11:31:58 +02:00
Simon Hausmann
3e21aafab9
Add support for direct export for convenience
2020-07-22 08:45:49 +02:00
Simon Hausmann
921a41b07c
Add support for explicit exports from files
...
Using an ES module inspired syntax, this allows free naming and control
over exported names.
2020-07-22 08:40:30 +02:00
Olivier Goffart
9d735d98cd
Build the transitions tree and more flexible animations
2020-07-20 18:46:04 +02:00
Olivier Goffart
0dff3f5f78
Parse state and transition
2020-07-20 12:59:12 +02:00
Olivier Goffart
19a8559d3f
WIP: Conditional elements
...
The parsing part is implemented, but not the backend as it requires
non-const "models"
2020-06-29 15:03:09 +02:00
Simon Hausmann
388c98bba5
Parse animate someProperty { ... } declarations
2020-06-24 17:43:48 +02:00
Olivier Goffart
6238d0d14f
Prepare for the ability to access the model
...
Add an expression type for the access of the model variable from a repeater
2020-06-19 13:46:55 +02:00
Olivier Goffart
be8f127317
Object and array parsing
2020-06-18 15:22:30 +02:00
Olivier Goffart
d4594cff97
Introduce a new DeclaredIdentifier
syntax kind to disambiguiate identifiers when there are several
2020-06-11 16:55:38 +02:00
Olivier Goffart
788137e3d5
Parser: allow to specify an index token in bracket in the for loop
2020-06-11 16:55:22 +02:00
Olivier Goffart
708e62800d
Test that the tree is well formed for what we expect
2020-06-11 15:01:09 +02:00
Olivier Goffart
92697ec6b0
Add some code to parse statements in blocks (separated with semicolon)
2020-05-28 07:22:08 +02:00
Olivier Goffart
9e4c355fa1
Lookup of quallified id
2020-05-25 17:24:31 +02:00
Simon Hausmann
1efa80882e
Parse initializers for property declarations
2020-05-25 16:42:09 +02:00
Olivier Goffart
11e5ce5887
Rename the CondeStatement syntax node to BindingExpression
...
This is the right-hand-side of a binding, and it is a pure expression.
Statements will be reserved for signals
2020-05-25 14:58:26 +02:00
Simon Hausmann
32b99547f1
Parse property declarations
...
For now this uses the syntax
property<qualified type name> name;
2020-05-25 12:38:29 +02:00
Simon Hausmann
5accea4cdd
Add support for qualified type names to the parser
2020-05-25 11:53:44 +02:00
Olivier Goffart
dd756ef112
Adapt the parser to parse := instead of =
2020-05-25 10:46:00 +02:00
Olivier Goffart
270c626c6c
Make the Parser a trait
...
Because the rowan::GreenNode is read-only but i want to use the parser
to generate something that can be mutated
2020-05-22 15:31:27 +02:00
Olivier Goffart
efe0ccfb3f
Add support for signal in the parser
...
(currently not doing anything else than parsing)
2020-05-20 12:53:08 +02:00
Olivier Goffart
300cd9653a
Move the expression parse funciton in their own module
2020-05-20 12:30:30 +02:00
Olivier Goffart
260f17a3e0
Support for inline components within a .60 file
2020-05-19 17:43:56 +02:00
Olivier Goffart
ab28828351
Support for img!("foo.png") to make string absolute
...
This is a temporary solution until we get better ressource handling
2020-05-19 16:30:48 +02:00
Olivier Goffart
a4569ddca3
BangExpression allow for finding relative paths
2020-05-19 15:36:56 +02:00
Olivier Goffart
6cf327166e
Parser: add support for parentheses in expressions
2020-05-11 11:19:57 +02:00
Olivier Goffart
1673f12652
Implement for loop in the parser
...
Not yet implemented in the object tree
2020-05-11 10:46:42 +02:00
Olivier Goffart
bdaf14ae23
Parse numbers
2020-05-07 09:06:58 +02:00
Olivier Goffart
b128a848e2
Parse quoted string
2020-05-06 18:24:30 +02:00
Olivier Goffart
3a541ec1eb
Handle children elements
2020-05-06 16:43:04 +02:00
Olivier Goffart
f0b5a9fee9
Use the parser_test only in test mode
...
So it does not have to be published on crate.io
2020-05-05 16:37:49 +02:00
Olivier Goffart
3a6d39bfe9
Generate an object tree
2020-05-05 11:18:13 +02:00
Olivier Goffart
684d516fee
Small cleanups to get rid of the .0
2020-05-04 19:36:32 +02:00
Olivier Goffart
e1b7949864
proc_macro to have parser tests
2020-05-04 17:11:02 +02:00
Olivier Goffart
112613712f
Move the actual parsing in its own file
2020-05-04 14:44:34 +02:00