Suppose I defined the BNF syntax rules for Language X.
Then I can generate an AST from a piece of example code using the defined BNF.
Now I want to do some manipulations of the previous generated AST, then generate the code back from the AST, using also the previously defined BNF.
Is this possible? Is the AST and BNF contain enough informations to generate syntax-valid code? I don't need the generated code to be pretty, just valid.
**live creditcard numbers with money