Hi Dave, I want to employ the technique described in http://eli.thegreenplace.net/2010/01/28/generating-random-sentences-from-a-context-free-grammar/ to auto-generate test cases for my PLY-based parser. So I need to walk over the productions created from my grammar definition.
For that purpose, I need access to the Grammar object created from my grammar, however there seems to me there's no way accessing it given PLY's code at it is now. The yacc function creates the grammar object just to run LR on it, and doesn't save it. And I can't access it through the parser. Am I missing something, or must I hack into PLY to make this possible. I guess I could create an alternative yacc function that saves the grammar somewhere, but is there a simpler way? Thanks in advance Eli -- You received this message because you are subscribed to the Google Groups "ply-hack" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/ply-hack?hl=en.
