ezno-parser 0.1.7

Parser and AST definitions for Ezno
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
use ezno_parser::{ASTNode, Expression, TypeAnnotation};

fn main() {
	let reference = TypeAnnotation::from_string(
		"Pair<Nested<Object<2>>, Array<number>>".into(),
		Default::default(),
	);

	println!("{reference:#?}");

	let expression = Expression::from_string(
		"(x << 3, x >> 2, y<Array<string>>(2), x < 7, x< 7)".into(),
		Default::default(),
	);

	println!("{expression:#?}");
}