Fix bugs found testing on druntime and phobos