builder.append(d.getIssue());
builder.append(" msg='");
builder.append(d.getMessage());
builder.append('\'');
if(d instanceof FileDiagnostic) {
FileDiagnostic fd = (FileDiagnostic) d;
builder.append(" file=");
builder.append(fd.getFile());
builder.append(" line=");
builder.append(fd.getLineNumber());
if(fd instanceof DetailedFileDiagnostic) {
DetailedFileDiagnostic dfd = (DetailedFileDiagnostic) fd;
builder.append(" offset=");
builder.append(dfd.getOffset());
builder.append(" length=");