|
|
|
Show HN: AGL a toy language that compiles to Go
(github.com)
|
|
83 points
by alain_gilbert
354 days ago
|
|
I spent the past 2 weeks making this toy programming language. I basically forked the Go scanner/parser, and changed the syntax to have functions return a single value. This enable proper Result/Option type to be used as well as propagating errors with an operator. I also wanted to have short "type inferred" anonymous functions to be able to use functions like Map/Reduce/Filter, without having to use 100 characters to specify the types. |
|
This seems to nicely smooth out a lot of the pain points I had back when I regularly wrote Go but also switched to other more expression-based languages occasionally. Being able to get all these conveniences while still being able to call into existing Go code seems amazing!
Also, I appreciate the pun, but did you have to use AI for the logo? Haha