ast-pattern-matching
ast-pattern-matching copied to clipboard
A library to do pattern matching on the AST in the Nim programming language.
basically this doesn't work: ```nim result = @[] fragmentPart.matchAstRecursive: of `sym` @ nnkSym: result.add sym ```
ref https://github.com/nim-lang/Nim/commit/86f7f4ffa5b8d84cbff12afbcd9b88d3ceb429c8. The devel tests of nimlsp fail because of this.
I've implemented a library similar to this one [here](https://github.com/godalming123/t3-chat-clone/blob/main/src/helpers.nim). Except my library is about 1/3 the code, has better error handling, and I have checked that it works on the...