d->ld where appropriate and other various format changes.