ssm-lang / Scoria

This is an embedding of the Sparse Synchronous Model, in Haskell!
BSD 3-Clause "New" or "Revised" License
4 stars 0 forks source link

Megaparsec parser instead of using the `Read` instance #69

Closed Rewbert closed 3 years ago

Rewbert commented 3 years ago

As described in #58, the Read instance as a parser was very slow when compared with a handcrafted megaparsec parser. Here I am pushing a new, tested megaparsec parser.

It appears to be some 70-80% faster than the Read-parser. I have not benchmarked it other than running time stack test --profile, but when I do that I consistently get about 25% shorter execution times for the 2-regression-low test-suite.