
[Please do not mail me a copy of your followup] boost-users@lists.boost.org spake the secret code <4CF652D3.7090008@motovilov.net> thusly:
My advice is to take things one step at a time. Don't try to write a grammar that covers all the complexity of your input. Start with the simplest piece of the input and write a parser for that. Gradually add more rules to your grammar as you cover more complexity in the input.
Well, in my case the input is relatively simple (JSON), it's the interpretation of the target types that complicates things... but your point about the incremental approach is certainly taken :-)
Additionally, if you practice test-driven development, then as you incrementally refine your grammar you'll know that the complexity you're adding doesn't break the simple cases you already have working. -- "The Direct3D Graphics Pipeline" -- DirectX 9 draft available for download http://legalizeadulthood.wordpress.com/the-direct3d-graphics-pipeline/ Legalize Adulthood! http://legalizeadulthood.wordpress.com