KnowledgeHub
Questions
Tags
Users
Search
Alex Rivera
|
Logout
Edit Question
Title
Body
I am trying to learn how to use Parsec to write a Delphi parser, but I am getting stuck at defining the LanguageDef. In Delphi, there are two types of comment blocks, (* comments *) and { comments } . But the types of commentStart & commentEnd of LanguageDef are String, not [String], so I could only put in one or the other. So, I tried to make my own whiteSpace parser, but I'm not sure I could actually pass it into makeTokenParser . Any help would be appreciated. Thanks John and Chris have helped me to understand and get around the problem, but the solution involves replacing a huge number of parsers that makeTokenParser provides, so it's not exactly desirable. I will post again if I could find a better solution.
Tags (comma-separated)
Save Edits
Cancel