Saturday, April 29, 2006

Came back from the future today, it's still April now, not May. Thanks TimToday.

I woke up really late today. It was about noon and I went to the office for the $part_time_job in the afternoon. But I can still spend some time on IRC. At about five o'clock, I fed the rule I drafted for MiniPerl6 to Pugs::Compiler::Rule and found some compilation error. Audrey pointed out that the comma may have to be escaped. That worked and many other problems are resolved in the same way including the plus sign, minus sign, tilde (string concatenation operator) and semicolon.

The draft of the grammar is now here. It's full of "<ws>?" since I do not yet know how to turn the word parsing mode on in P::C::Rule. And the string matching part lacks escaping sequence matching because Pugs::Emit::Rule::Perl5 currently ignores character class rule and I met some problem handling backslashes. I will spend some time to fix it. Also, production rules are mostly omitted but, as the sample parsing script demos, the written one works.

You might find that there is currently no Pugs/Grammar/MiniPerl6.pm in the repository. Yes, it's not there since it can be generated by feeding the grammar to the script under Pugs-Compiler-Rule. The automatic generating script will be added soon, maybe right after some kind of completion of the mini-grammar.