Nifty ABNF tool, and error in ABNF syntax

I came across a nitfy tool: abnfgen <http://www.quut.com/abnfgen>.

It reads an abnf syntax and then generates random strings that adhere  
to that syntax. Very handy to test a parser. Your syntax needed a bit  
of minor massaging before abnfgen liked it, such as including the  
definitions for pchar and such that you've included by reference, and  
getting rid of the boring productions (like the non-media-fragment  
alternative in segment).

One of the first things it did was point out a problem with the  
syntax, I think:
	utf8string    = "'" *pchar "'"
But: single quote is also part of pchar, so this would allow a  
production of 'a'b', which I think is not what was intended.
--
Jack Jansen, <Jack.Jansen@cwi.nl>, http://www.cwi.nl/~jack
If I can't dance I don't want to be part of your revolution -- Emma  
Goldman

Received on Thursday, 26 March 2009 13:46:54 UTC