[fine] Automatic rebase support for CST

This commit is contained in:
John Doty 2024-01-04 19:37:58 -08:00
parent 1f6d7ec131
commit 26871aa9ae
6 changed files with 122 additions and 8 deletions

View file

@ -1,10 +1,6 @@
// concrete:
// | File
// | ExpressionStatement
// | LiteralExpression
// | Number:'"42"'
// | Semicolon:'";"'
// | ExpressionStatement
// | BinaryExpression
// | BinaryExpression
// | LiteralExpression
@ -23,5 +19,4 @@
// | Number:'"4"'
// | Semicolon:'";"'
//
42;
1 * 2 + -3 * 4;

View file

@ -0,0 +1,22 @@
// concrete:
// | File
// | ExpressionStatement
// | BinaryExpression
// | BinaryExpression
// | LiteralExpression
// | True:'"true"'
// | And:'"and"'
// | LiteralExpression
// | False:'"false"'
// | Or:'"or"'
// | BinaryExpression
// | LiteralExpression
// | False:'"false"'
// | And:'"and"'
// | UnaryExpression
// | Bang:'"!"'
// | LiteralExpression
// | True:'"true"'
// | Semicolon:'";"'
//
true and false or false and !true;

View file

@ -0,0 +1,8 @@
// concrete:
// | File
// | ExpressionStatement
// | LiteralExpression
// | Number:'"42"'
// | Semicolon:'";"'
//
42;

View file

@ -0,0 +1,12 @@
// concrete:
// | File
// | ExpressionStatement
// | BinaryExpression
// | LiteralExpression
// | String:'"\"Hello \""'
// | Plus:'"+"'
// | LiteralExpression
// | String:'"'world!'"'
// | Semicolon:'";"'
//
"Hello " + 'world!';