clean up generated D code