You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
There are lots of Parsers in directory camlp4/Camlp4Parsers.
It would be nice to factor out one line
"let module M = Register.OCamlSyntaxExtension Id Make in ();"
to make it more reusable.
The Grammar is already parameterized over Camlp4Ast;
but the last line makes linking with Camlp4OCamlRevisedParser.cmo will mutate Syntax. It would be nice to move the last line to another file.
Then users can get the parsers for free without polluting its syntax.
The text was updated successfully, but these errors were encountered:
Other factoring which makes camlp4 more usable is to parameterize Register module which depends on PreCast.
Since Camlp4 3.10+ was developed based on the idea that Lexer's parameterized, but the fact that Register.ml depends on PreCast.ml which hardcode the default Lexer.ml makes users to supply their own Lexer too much work.
I guess refactoring these modules will not take too much time, but people may need to take care of the building scripts.
Original bug ID: 5635
Reporter: @bobzhang
Assigned to: @bobzhang
Status: closed (set by @diml on 2016-12-07T17:25:08Z)
Resolution: suspended
Priority: normal
Severity: feature
Category: -for Camlp4 use https://github.com/ocaml/camlp4/issues
Monitored by: @hcarty
Bug description
There are lots of Parsers in directory camlp4/Camlp4Parsers.
It would be nice to factor out one line
"let module M = Register.OCamlSyntaxExtension Id Make in ();"
to make it more reusable.
The Grammar is already parameterized over Camlp4Ast;
but the last line makes linking with Camlp4OCamlRevisedParser.cmo will mutate Syntax. It would be nice to move the last line to another file.
Then users can get the parsers for free without polluting its syntax.
The text was updated successfully, but these errors were encountered: