Another possibility is to copy the xml.d, remove the module std.xml; declartion from it, change import std.xml; to import xml; then compile with dmd and ldc. This will account for differences in compiler flags used to compile phobos in dmd and ldc projects.