|
OK, two more questions on terminals if you have time.
First, I am using IdentifierTerminal for value when really value is more like a string literal but without any start and end delimiters. e.g. valid values might be 1.0, C#4 etc. Is there an appropriate built-in terminal type I can use?
Second, and this is where I fear things may get a bit complicated. This language actually allows spaces in values so for example:
name=John Smith age=50 birthplace=New York height=6'2"
would ideally parse to:
opcode: "name"
value: "John Smith"
opcode: "age"
value: "50"
opcode: "birthplace"
value="New York"
etc
To achieve this do I have to define my "value" as a non-terminal allowing component pieces, or is there a terminal that can cope with spaces in non-delimited string literals and work out where to stop?
thanks again for your time & this excellent library
Mark
|