Move ast code into its own namespace.