Closed vrotaru closed 1 year ago
What is the goal of this PR ?
propcc.ml is a generated file; we do not want to edit it by hand.
Stream
and Genlex
are going to disappear to the standard library, but a replacement package is already available on opam.
Well the goal of this is not to replace propcc.ml but propcc.ml4. Obviously. Very few people know and use Camlp4.
But you are the maintainer, so whatever. I was doing something somewhat related and this was a just bit of a challenge.
Where PMS stands for Poor-Man Streams, not what you may have thought.
What i did is that I've added lexers for
varcc|propcc
tools, but I'm accessing them not directly, but through a wrapper structThis gives us the familiar stream operations,
next
, andpeek
and that is enough to port the stream parsing code almost verbatim.Also something which I learned during that exercise is that writing good error messages is hard and tedious.