language-python
language-python copied to clipboard
Documentation request: Python AST
Is it possible to document the target AST? Would help while contributing.
Not sure on the format most folks would find useful -- personally, I'd be a fan of a JSON blob where:
x = 1
is represented by
{
"type": "expression",
"operator": "assignment",
"variable": "x",
"value": "1"
}
Would this be useful for anyone?
I think documentation in the form of some examples would be very helpful, yes.
Can it be done with normal Haddock style comments in the source code? https://github.com/bjpop/language-python/blob/master/src/Language/Python/Common/AST.hs
I'm not sure about the JSON style. Perhaps you can elaborate on why that would be a good way to do it?
I would be very happy to accept pull requests for documentation.