Neat 0.2.1: Advent of Lexing
FeepingCreature
released this
19 Dec 17:46
·
385 commits
to master
since this release
When building Neat, the new lexer gives a 60ms speedup: 1.07s to 1.01s. Not the most spectacular, but hopefully more gains later.
I've also been doing the Advent of Code '22 puzzles to shake out bugs. Language is holding up so far; no show-stoppers.
- Change operator precedence to raise shift operators
- It is now
& ^ <<>> | */ +- <> && || if
- It is now
- Add character literals:
'a'
- The
-release
switch disables array bounds checking. - The
-run
switch executes the built binary.- Command line arguments after
--
are passed to the program.
- Command line arguments after
- Add
std.algorithm.splitter
- Add formatting for chars, named tuples, vectors, enums
- Add
hashmap.remove
,hashmap.clear
.()
now parses as a tuple, removing the need for.(())
with() { }
now supports types, such as enumsvalue.case(...)
now supports non-sumtypevalue
Ret foo() => value
is equivalent toRet foo() return value;
- Support
bool || bottom
. a ~= b;
now detects ifa
is non-mutable.- Fix long literals. Numbers that are too big for
int
are now automatically typed aslong
. - The input text is now lexed before parsing, providing a marginal speedup.