Clean up HandlePropagationAnalysis.

It at least doesn't crash now.
Add AST construction helpers.