Commit Graph

17 Commits

Author SHA1 Message Date
a213c7f70a grammar: Minor cleanup, fix compat with Grammatical parser 2024-04-11 19:59:00 -05:00
a31d285d99 grammar.ebnf: Clean up grammar
- TODO: Member access is totally broken lmao
2024-04-06 01:02:31 -05:00
325498ac8b ast: Add metadata attributes on Items
TODO: decide what other places attributes belong
2024-02-27 23:31:49 -06:00
978f5e40c1 conlang: Introduce type-alias/typedef syntax
`type T;` | `type T = U;`
2024-02-27 20:49:02 -06:00
87c8d43d11 grammar.ebnf: Fix ModuleKind grammar 2024-02-26 16:19:21 -06:00
66deb41301 grammar.ebnf: Sync changes with AST 2024-02-26 16:02:36 -06:00
c4a32895df conlang 0.3.0: Total grammar overhaul
- Rewrote the grammar
- Rewrote the AST
- Rewrote the Parser
- Removed pretty printer (now handled by ast::ast_impl::Pretty, a Writer wrapper)
- Added items, and new keywords to go with them
  - Syntax is ~maybe temporary, based on Rust syntax
2024-01-21 05:32:18 -06:00
79fda16788 cl 0.0.2: MAJOR ERGONOMIC BOOST
Broke frontend into its own library, "cl-frontend"
- Frontend is pretty :D
- Included sample fibonacci implementation

Deprecated conlang::ast::Visitor in favor of bespoke traits
- Rust traits are super cool.
- The Interpreter is currently undergoing a major rewrite

Added preliminary type-path support to the parser
- Currently incomplete: type paths must end in Never..?

Pretty printer is now even prettier
- conlang::ast now exports all relevant AST nodes, since there are no namespace collisions any more
2024-01-04 02:18:09 -06:00
ee5dabb4f3 Conlang: Implement functions 1.0 (Resolves #12)
- [x] Call syntax
- [x] Function declaration syntax
TODO:
- [ ] Any form of type checking
- [ ] Static variable resolution
- [ ] Closures, etc.
2023-10-29 23:47:00 -05:00
8fe89e6297 conlang: Variable binding and cleanup
ast: Separate concerns, and remove Walk
interpreter: implement variable binding
2023-10-29 01:13:48 -05:00
0445598ae8 grammar: Remove Ignore expression to avoid parsing ambiguity :'( 2023-10-26 14:36:55 -05:00
b1f90ca4e9 conlang: Add statements
TODO: Parse `let` statements
2023-10-26 14:33:56 -05:00
ccfddcc09a Conlang: Add range operators
TODO: Limit range operators to at most 2 operands
2023-10-22 18:30:00 -05:00
1e5f7149d9 Token: Add range operators, rename for consistency 2023-10-20 17:09:14 -05:00
a26a01fc17 constr: Misuse iterators to parse tokens 2023-10-20 15:33:02 -05:00
7f7393d2c6 conlang: Grammatical cleanup; merge control flow expressions 2023-10-19 14:40:03 -05:00
cdb8c28e64 grammar.ebnf: Initial prototype grammar 2023-10-16 22:33:38 -05:00