Make c++ ast definitions to take Query arguments.