static void *
tbl_seek(int id)
{
- struct empfile *ep = &empfile[cur_type];
void *obj;
if (id >= ef_nelem(cur_type)) {
if (!ef_ensure_space(cur_type, id, 1)) {
- gripe("Can't put ID %d into table %s", id, ep->name);
+ gripe("can't grow table to hold this row");
return NULL;
}
}
return -1;
} else {
if (!can_fill_gaps(cur_type))
- return gripe("Expected %d more rows",
+ return gripe("expected %d more rows",
ep->fids - (cur_id + 1));
omit_ids(cur_id + 1, ep->fids);
}
} else {
if (expected_id(cur_id + 1, ep->fids) >= 0)
- return gripe("Table's first part has more rows");
+ return gripe("table's first part has more rows");
}
}
getfld(int fldno, int *idx)
{
if (fldno >= nflds) {
- gripe("Too many fields, expected only %d", nflds);
+ gripe("too many fields, expected only %d", nflds);
return NULL;
}
if (CANT_HAPPEN(fldno < 0))
return cur_id + 1;
if (id != cur_id + 1 && !can_fill_gaps(cur_type))
- return gripe("Expected %d in field %d",
+ return gripe("expected %d in field %d",
cur_id + 1, fldno + 1);
if (id <= cur_id)
- return gripe("Field %d must be > %d", fldno + 1, cur_id);
+ return gripe("field %d must be > %d", fldno + 1, cur_id);
max_id = ef_id_limit(cur_type);
if (id > max_id)
- return gripe("Field %d must be <= %d", fldno + 1, max_id);
+ return gripe("field %d must be <= %d", fldno + 1, max_id);
return id;
}
/* Note: reporting values out of range left to putnum() */
if (id <= cur_id) {
sctoff2xy(&x, &y, cur_id);
- return gripe("Coordinates in fields %d,%d must be > %d,%d",
+ return gripe("coordinates in fields %d,%d must be > %d,%d",
fldno_x + 1, fldno_y + 1, x, y);
}
return id;
realm = (long)fldval[fldno_realm].val_as.dbl;
cnum = (long)fldval[fldno_cnum].val_as.dbl;
if (cnum < 0 || cnum >= MAXNOC)
- return gripe("Field %d must be between 0 and %d",
+ return gripe("field %d must be between 0 and %d",
fldno_cnum, MAXNOC);
if (realm < 0 || realm >= MAXNOR)
- return gripe("Field %d must be between 0 and %d",
+ return gripe("field %d must be between 0 and %d",
fldno_realm, MAXNOR);
id = realm + cnum * MAXNOR;
if (id <= cur_id)
- return gripe("Fields %d,%d must be > (%d,%d)",
+ return gripe("fields %d,%d must be > (%d,%d)",
fldno_cnum + 1, fldno_realm + 1,
cur_id / MAXNOR, cur_id % MAXNOR);
return id;
if (partno) {
id = expected_id(cur_id + 1, empfile[cur_type].fids);
if (id < 0) {
- gripe("Table's first part doesn't have this row");
+ gripe("table's first part doesn't have this row");
return NULL;
}
} else if (ca0_is_id(cur_type)) {
} else
id = last_id + 1;
if (id > ef_id_limit(cur_type)) {
- gripe("Too many rows");
+ gripe("too many rows");
return NULL;
}
new = ((time_t *)memb_ptr)[idx] = (time_t)dbl;
break;
default:
- return gripe("Field %d doesn't take numbers", fldno + 1);
+ return gripe("field %d doesn't take numbers", fldno + 1);
}
if (fldval_must_match(fldno) && old != dbl)
- return gripe("Value for field %d must be %g", fldno + 1, old);
+ return gripe("value for field %d must be %g", fldno + 1, old);
if (new != dbl)
- return gripe("Field %d can't hold this value", fldno + 1);
+ return gripe("field %d can't hold this value", fldno + 1);
return 0;
}
if (CANT_HAPPEN(idx))
return -1;
if (!str)
- return gripe("Field %d doesn't take nil", fldno + 1);
+ return gripe("field %d doesn't take nil", fldno + 1);
/* Wart: if ca_len <= 1, the terminating null may be omitted */
sz = ca->ca_len;
len = sz > 1 ? sz - 1 : sz;
if (strlen(str) > len)
- return gripe("Field %d takes at most %d characters",
+ return gripe("field %d takes at most %d characters",
fldno + 1, (int)len);
old = memb_ptr;
if (must_match)
strncpy(memb_ptr, str, sz);
break;
default:
- return gripe("Field %d doesn't take strings", fldno + 1);
+ return gripe("field %d doesn't take strings", fldno + 1);
}
if (mismatch) {
if (old)
- return gripe("Value for field %d must be \"%.*s\"",
+ return gripe("value for field %d must be \"%.*s\"",
fldno + 1, (int)len, old);
else
- return gripe("Value for field %d must be nil", fldno + 1);
+ return gripe("value for field %d must be nil", fldno + 1);
}
return 0;
ch = skipfs(fp);
switch (ch) {
case EOF:
- return gripe("Unexpected EOF");
+ return gripe("unexpected EOF");
case '\n':
nflds = i - (ellipsis != 0);
if (chkflds() < 0)
return 0;
case '.':
if (getc(fp) != '.' || getc(fp) != '.')
- return gripe("Junk in header field %d", i + 1);
+ return gripe("junk in header field %d", i + 1);
if (i == 0)
- return gripe("Header fields expected");
+ return gripe("header fields expected");
ellipsis = 1;
ch = skipfs(fp);
if (ch != EOF && ch != '\n')
- return gripe("Junk after ...");
+ return gripe("junk after ...");
ungetc(ch, fp);
return 1;
default:
ungetc(ch, fp);
if (getid(fp, buf) < 0)
- return gripe("Junk in header field %d", i + 1);
+ return gripe("junk in header field %d", i + 1);
ch = getc(fp);
if (ch != '(') {
ungetc(ch, fp);
ungetc(ch, fp);
if (isdigit(ch) || ch == '-' || ch == '+') {
if (fscanf(fp, "%d", &idx) != 1)
- return gripe("Malformed number in index of header field %d",
+ return gripe("malformed number in index of header field %d",
i + 1);
if (idx < 0)
- return gripe("Index must not be negative in header field %d",
+ return gripe("index must not be negative in header field %d",
i + 1);
} else {
if (getid(fp, buf) < 0)
- return gripe("Malformed index in header field %d", i + 1);
- return gripe("Symbolic index in header field %d not yet implemented",
+ return gripe("malformed index in header field %d", i + 1);
+ return gripe("symbolic index in header field %d not yet implemented",
i + 1);
}
ch = getc(fp);
if (ch != ')')
- return gripe("Malformed index in header field %d", i + 1);
+ return gripe("malformed index in header field %d", i + 1);
return deffld(i, buf, idx);
}
}
ch = skipfs(fp);
switch (ch) {
case EOF:
- return gripe("Unexpected EOF");
+ return gripe("unexpected EOF");
case '\n':
CANT_HAPPEN(i > nflds);
for (j = i; j < nflds; j++) {
if (CA_IS_ARRAY(fldca[j]))
- gripe("Field %s(%d) missing",
+ gripe("field '%s(%d)' missing",
fldca[j]->ca_name, fldidx[j]);
else
- gripe("Field %s missing", fldca[j]->ca_name);
+ gripe("field '%s' missing", fldca[j]->ca_name);
}
if (i != nflds || putrow() < 0)
return -1;
case '5': case '6': case '7': case '8': case '9':
ungetc(ch, fp);
if (fscanf(fp, "%lg", &dbl) != 1)
- return gripe("Malformed number in field %d", i + 1);
+ return gripe("malformed number in field %d", i + 1);
return setnum(i, dbl);
case '"':
ch = getc(fp);
else {
ungetc(ch, fp);
if (fscanf(fp, "%1023[^\"\n]", buf) != 1 || getc(fp) != '"')
- return gripe("Malformed string in field %d", i + 1);
+ return gripe("malformed string in field %d", i + 1);
if (!xuesc(buf))
- return gripe("Invalid escape sequence in field %d",
+ return gripe("invalid escape sequence in field %d",
i + 1);
}
return setstr(i, buf);
for (;;) {
ch = skipfs(fp);
if (ch == EOF || ch == '\n')
- return gripe("Unmatched '(' in field %d", i + 1);
+ return gripe("unmatched '(' in field %d", i + 1);
if (ch == ')')
break;
ungetc(ch, fp);
if (getid(fp, buf) < 0)
- return gripe("Junk in field %d", i + 1);
+ return gripe("junk in field %d", i + 1);
if (add2symset(i, &set, buf) < 0)
return -1;
}
default:
ungetc(ch, fp);
if (getid(fp, buf) < 0)
- return gripe("Junk in field %d", i + 1);
+ return gripe("junk in field %d", i + 1);
if (!strcmp(buf, "nil"))
return setstr(i, NULL);
else
if (ch == '\n')
ungetc(ch, fp);
else if (ch != ' ' && ch != '\t')
- return gripe("Bad field separator after field %d", i + 1);
+ return gripe("bad field separator after field %d", i + 1);
}
}
res = stmtch(name, ca, offsetof(struct castr, ca_name),
sizeof(struct castr));
if (res < 0)
- return gripe("Header %s of field %d is %s", name, fldno + 1,
- res == M_NOTUNIQUE ? "ambiguous" : "unknown");
+ return gripe("%s header '%s' in field %d",
+ res == M_NOTUNIQUE ? "ambiguous" : "unknown",
+ name, fldno + 1);
if ((ca[res].ca_flags & NSC_EXTRA) || CANT_HAPPEN(ca[res].ca_get))
- return gripe("Extraneous header %s in field %d", name, fldno + 1);
+ return gripe("extraneous header '%s' in field %d", name, fldno + 1);
if (CA_IS_ARRAY(&ca[res])) {
if (idx < 0)
- return gripe("Header %s requires an index in field %d",
+ return gripe("header '%s' requires an index in field %d",
ca[res].ca_name, fldno + 1);
+ if (idx != caflds[res] && idx < ca[res].ca_len)
+ return gripe("expected header '%s(%d)' in field %d",
+ ca[res].ca_name, caflds[res], fldno + 1);
if (idx >= ca[res].ca_len)
- return gripe("Header %s(%d) index out of bounds in field %d",
+ return gripe("unexpected header '%s(%d)' in field %d",
ca[res].ca_name, idx, fldno + 1);
- if (idx < caflds[res])
- return gripe("Duplicate header %s(%d) in field %d",
- ca[res].ca_name, idx, fldno + 1);
- if (idx > caflds[res])
- return gripe("Expected header %s(%d) in field %d",
- ca[res].ca_name, caflds[res], fldno + 1);
} else {
if (idx >= 0)
- return gripe("Header %s doesn't take an index in field %d",
+ return gripe("header '%s' doesn't take an index in field %d",
ca[res].ca_name, fldno + 1);
idx = 0;
if (caflds[res])
- return gripe("Duplicate header %s in field %d",
+ return gripe("duplicate header '%s' in field %d",
ca[res].ca_name, fldno + 1);
}
fldca[fldno] = &ca[res];
continue;
len = CA_ARRAY_LEN(&ca[i]);
if (!len && !cafldsmax)
- res = gripe("Header field %s missing", ca[i].ca_name);
+ res = gripe("header '%s' missing", ca[i].ca_name);
else if (len && cafldsmax == len - 1)
- res = gripe("Header field %s(%d) missing",
+ res = gripe("header '%s(%d)' missing",
ca[i].ca_name, len - 1);
else if (len && cafldsmax < len - 1)
- res = gripe("Header fields %s(%d) ... %s(%d) missing",
+ res = gripe("header '%s(%d)' ... '%s(%d)' missing",
ca[i].ca_name, cafldsmax, ca[i].ca_name, len - 1);
}
{
int i = ef_elt_byname(ca->ca_table, id);
if (i < 0)
- return gripe("%s %s symbol `%s' in field %d",
- i == M_NOTUNIQUE ? "Ambiguous" : "Unknown",
+ return gripe("%s %s symbol '%s' in field %d",
+ i == M_NOTUNIQUE ? "ambiguous" : "unknown",
ca->ca_name, id, n + 1);
return i;
}
return -1;
if (ca->ca_table == EF_BAD || (ca->ca_flags & NSC_BITS))
- return gripe("Field %d doesn't take symbols", fldno + 1);
+ return gripe("field %d doesn't take symbols", fldno + 1);
i = xunsymbol(sym, ca, fldno);
if (i < 0)
if (ca->ca_table == EF_BAD || ef_cadef(ca->ca_table) != symbol_ca
|| !(ca->ca_flags & NSC_BITS))
- return gripe("Field %d doesn't take symbol sets", fldno + 1);
+ return gripe("field %d doesn't take symbol sets", fldno + 1);
*set = 0;
return 0;
}
? fscanf(fp, "config%*[ \t]%63[^ \t#\n]%n", name, &res) != 1
: fscanf(fp, "XDUMP%*[ \t]%63[^ \t#\n]%*[ \t]%*[^ \t#\n]%n",
name, &res) != 1) || res < 0)
- return gripe("Expected xdump header");
+ return gripe("expected xdump header");
type = ef_byname(name);
if (type < 0)
- return gripe("Unknown table `%s'", name);
+ return gripe("unknown table '%s'", name);
if (expected_table != EF_BAD && expected_table != type)
- return gripe("Expected table `%s', not `%s'",
+ return gripe("expected table '%s', not '%s'",
ef_nameof(expected_table), name);
if (!empfile[type].file
|| !ef_cadef(type) || !(ef_flags(type) & EFF_MEM)) {
CANT_HAPPEN(expected_table != EF_BAD);
- return gripe("Table `%s' is not permitted here", name);
+ return gripe("table '%s' is not permitted here", name);
}
if (skipfs(fp) != '\n')
- return gripe("Junk after xdump header");
+ return gripe("junk after xdump header");
lineno++;
return type;
res = -1;
if (human) {
if (fscanf(fp, "config%n", &res) != 0 || res < 0)
- return gripe("Malformed table footer");
+ return gripe("malformed table footer");
} else {
if (fscanf(fp, "%d", &n) != 1)
- return gripe("Malformed table footer");
+ return gripe("malformed table footer");
if (recs != n)
- return gripe("Read %d rows, which doesn't match footer "
- "%d rows", recs, n);
+ return gripe("expected footer /%d", recs);
}
if (skipfs(fp) != '\n')
- return gripe("Junk after table footer");
+ return gripe("junk after table footer");
if (tbl_part_done() < 0)
return -1;
lineno++;
-tests/empdump/xundump-errors/colhdr-amb:2: Header m of field 3 is ambiguous
-tests/empdump/xundump-errors/colhdr-dup:2: Duplicate header name in field 2
-tests/empdump/xundump-errors/colhdr-dup2:6: Duplicate header name in field 3
-tests/empdump/xundump-errors/colhdr-dup3:2: Duplicate header pkg(0) in field 8
-tests/empdump/xundump-errors/colhdr-ellipsis:2: Header fields expected
-tests/empdump/xundump-errors/colhdr-ellipsis2:2: Junk after ...
-tests/empdump/xundump-errors/colhdr-eof:2: Unexpected EOF
-tests/empdump/xundump-errors/colhdr-idxbig:2: Header pkg(99) index out of bounds in field 7
-tests/empdump/xundump-errors/colhdr-idxneg:2: Index must not be negative in header field 7
-tests/empdump/xundump-errors/colhdr-idxreq:2: Header pkg requires an index in field 7
-tests/empdump/xundump-errors/colhdr-junk:2: Junk in header field 1
-tests/empdump/xundump-errors/colhdr-junk2:2: Junk in header field 1
-tests/empdump/xundump-errors/colhdr-junk3:2: Junk in header field 1
-tests/empdump/xundump-errors/colhdr-malidx:2: Malformed number in index of header field 1
-tests/empdump/xundump-errors/colhdr-malidx2:2: Malformed index in header field 1
-tests/empdump/xundump-errors/colhdr-malidx3:2: Malformed index in header field 1
-tests/empdump/xundump-errors/colhdr-miss:2: Header field uid missing
-tests/empdump/xundump-errors/colhdr-miss:2: Header field ctype(2) missing
-tests/empdump/xundump-errors/colhdr-miss:2: Header fields camt(0) ... camt(2) missing
-tests/empdump/xundump-errors/colhdr-miss:2: Header field nllag missing
-tests/empdump/xundump-errors/colhdr-miss2:21: Header fields ctype(0) ... ctype(2) missing
-tests/empdump/xundump-errors/colhdr-miss2:21: Header fields camt(0) ... camt(2) missing
-tests/empdump/xundump-errors/colhdr-miss2:21: Header field type missing
-tests/empdump/xundump-errors/colhdr-miss2:21: Header field level missing
-tests/empdump/xundump-errors/colhdr-miss2:21: Header field cost missing
-tests/empdump/xundump-errors/colhdr-miss2:21: Header field nrndx missing
-tests/empdump/xundump-errors/colhdr-miss2:21: Header field nrdep missing
-tests/empdump/xundump-errors/colhdr-miss2:21: Header field nlndx missing
-tests/empdump/xundump-errors/colhdr-miss2:21: Header field nlmin missing
-tests/empdump/xundump-errors/colhdr-miss2:21: Header field nllag missing
-tests/empdump/xundump-errors/colhdr-noidx:2: Header name doesn't take an index in field 1
-tests/empdump/xundump-errors/colhdr-sep:2: Bad field separator after field 1
-tests/empdump/xundump-errors/colhdr-symidx:2: Symbolic index in header field 1 not yet implemented
-tests/empdump/xundump-errors/colhdr-unexp2:2: Expected header pkg(0) in field 7
-tests/empdump/xundump-errors/colhdr-unk:2: Header xxx of field 1 is unknown
-tests/empdump/xundump-errors/fld-ambsym:2: Ambiguous flags symbol `s' in field 29
-tests/empdump/xundump-errors/fld-badnum:3: Field 2 can't hold this value
-tests/empdump/xundump-errors/fld-constnum:3: Value for field 1 must be 0
-tests/empdump/xundump-errors/fld-conststr:3: Value for field 1 must be "road network"
-tests/empdump/xundump-errors/fld-conststr2:8: Value for field 2 must be nil
-tests/empdump/xundump-errors/fld-eof:2: Unexpected EOF
-tests/empdump/xundump-errors/fld-invesc:2: Invalid escape sequence in field 1
-tests/empdump/xundump-errors/fld-invid:3: Field 1 can't hold this value
-tests/empdump/xundump-errors/fld-invid1:3: Expected 0 in field 1
-tests/empdump/xundump-errors/fld-invid2:3: Field 1 must be > -1
-tests/empdump/xundump-errors/fld-invid3:4: Field 1 must be > 2
-tests/empdump/xundump-errors/fld-invid4:3: Field 1 must be <= 98
-tests/empdump/xundump-errors/fld-invid5:4: Coordinates in fields 1,2 must be > 2,0
-tests/empdump/xundump-errors/fld-invid6:3: Field 0 must be between 0 and 99
-tests/empdump/xundump-errors/fld-invid7:3: Field 1 must be between 0 and 50
-tests/empdump/xundump-errors/fld-invid8:4: Fields 1,2 must be > (0,1)
-tests/empdump/xundump-errors/fld-junk:2: Junk in field 1
-tests/empdump/xundump-errors/fld-junk2:2: Junk in field 19
-tests/empdump/xundump-errors/fld-malnum:2: Malformed number in field 1
-tests/empdump/xundump-errors/fld-malstr:2: Malformed string in field 1
-tests/empdump/xundump-errors/fld-many:2: Too many fields, expected only 6
-tests/empdump/xundump-errors/fld-miss:2: Field name missing
-tests/empdump/xundump-errors/fld-miss:2: Field mnem missing
-tests/empdump/xundump-errors/fld-miss:2: Field value missing
-tests/empdump/xundump-errors/fld-miss:2: Field sell missing
-tests/empdump/xundump-errors/fld-miss:2: Field lbs missing
-tests/empdump/xundump-errors/fld-miss:2: Field pkg(0) missing
-tests/empdump/xundump-errors/fld-miss:2: Field pkg(1) missing
-tests/empdump/xundump-errors/fld-miss:2: Field pkg(2) missing
-tests/empdump/xundump-errors/fld-miss:2: Field pkg(3) missing
-tests/empdump/xundump-errors/fld-miss:2: Field pkg(4) missing
-tests/empdump/xundump-errors/fld-miss:2: Field melt_denom missing
-tests/empdump/xundump-errors/fld-miss2:3: Field ctype(0) missing
-tests/empdump/xundump-errors/fld-nonil:3: Field 19 doesn't take nil
-tests/empdump/xundump-errors/fld-nonum:3: Field 2 doesn't take numbers
-tests/empdump/xundump-errors/fld-nostr:3: Field 1 doesn't take strings
-tests/empdump/xundump-errors/fld-nosym:2: Field 1 doesn't take symbols
-tests/empdump/xundump-errors/fld-nosymset:2: Field 1 doesn't take symbol sets
-tests/empdump/xundump-errors/fld-sep:2: Bad field separator after field 1
-tests/empdump/xundump-errors/fld-strbig:3: Field 19 takes at most 9 characters
-tests/empdump/xundump-errors/fld-unexpid:6: Table's first part doesn't have this row
-tests/empdump/xundump-errors/fld-unexpid1:7: Value for field 1 must be 2
-tests/empdump/xundump-errors/fld-unksym:2: Unknown level symbol `xxx' in field 11
-tests/empdump/xundump-errors/fld-unparen:2: Unmatched '(' in field 19
-tests/empdump/xundump-errors/ftr-fewrows:2: Expected 34 more rows
-tests/empdump/xundump-errors/ftr-fewrows2:4: Expected 13 more rows
-tests/empdump/xundump-errors/ftr-fewrows3:4: Expected 1 more rows
-tests/empdump/xundump-errors/ftr-fewrows4:7: Table's first part has more rows
-tests/empdump/xundump-errors/ftr-junk:2: Junk after table footer
-tests/empdump/xundump-errors/ftr-mal:2: Malformed table footer
-tests/empdump/xundump-errors/ftr-mal2:6: Malformed table footer
-tests/empdump/xundump-errors/ftr-manyrows:5: Too many rows
-tests/empdump/xundump-errors/ftr-manyrows2:17: Too many rows
-tests/empdump/xundump-errors/ftr-mismatch:2: Read 0 rows, which doesn't match footer 2 rows
-tests/empdump/xundump-errors/hdr-extra:2: Extraneous header timestamp in field 1
-tests/empdump/xundump-errors/hdr-extra2:2: Extraneous header uid in field 1
-tests/empdump/xundump-errors/hdr-junk:1: Junk after xdump header
-tests/empdump/xundump-errors/hdr-none:1: Expected xdump header
-tests/empdump/xundump-errors/hdr-noperm:1: Table `map' is not permitted here
-tests/empdump/xundump-errors/hdr-noperm2:1: Table `table' is not permitted here
-tests/empdump/xundump-errors/hdr-unexp:4: Expected table `ship', not `plane'
-tests/empdump/xundump-errors/hdr-unktab:1: Unknown table `xxx'
+tests/empdump/xundump-errors/colhdr-amb:2: ambiguous header 'm' in field 3
+tests/empdump/xundump-errors/colhdr-dup:2: duplicate header 'name' in field 2
+tests/empdump/xundump-errors/colhdr-dup2:6: duplicate header 'name' in field 3
+tests/empdump/xundump-errors/colhdr-dup3:2: expected header 'pkg(1)' in field 8
+tests/empdump/xundump-errors/colhdr-ellipsis:2: header fields expected
+tests/empdump/xundump-errors/colhdr-ellipsis2:2: junk after ...
+tests/empdump/xundump-errors/colhdr-eof:2: unexpected EOF
+tests/empdump/xundump-errors/colhdr-idxbig:2: unexpected header 'pkg(99)' in field 12
+tests/empdump/xundump-errors/colhdr-idxneg:2: index must not be negative in header field 7
+tests/empdump/xundump-errors/colhdr-idxreq:2: header 'pkg' requires an index in field 7
+tests/empdump/xundump-errors/colhdr-junk:2: junk in header field 1
+tests/empdump/xundump-errors/colhdr-junk2:2: junk in header field 1
+tests/empdump/xundump-errors/colhdr-junk3:2: junk in header field 1
+tests/empdump/xundump-errors/colhdr-malidx:2: malformed number in index of header field 1
+tests/empdump/xundump-errors/colhdr-malidx2:2: malformed index in header field 1
+tests/empdump/xundump-errors/colhdr-malidx3:2: malformed index in header field 1
+tests/empdump/xundump-errors/colhdr-miss:2: header 'uid' missing
+tests/empdump/xundump-errors/colhdr-miss:2: header 'ctype(2)' missing
+tests/empdump/xundump-errors/colhdr-miss:2: header 'camt(0)' ... 'camt(2)' missing
+tests/empdump/xundump-errors/colhdr-miss:2: header 'nllag' missing
+tests/empdump/xundump-errors/colhdr-miss2:21: header 'ctype(0)' ... 'ctype(2)' missing
+tests/empdump/xundump-errors/colhdr-miss2:21: header 'camt(0)' ... 'camt(2)' missing
+tests/empdump/xundump-errors/colhdr-miss2:21: header 'type' missing
+tests/empdump/xundump-errors/colhdr-miss2:21: header 'level' missing
+tests/empdump/xundump-errors/colhdr-miss2:21: header 'cost' missing
+tests/empdump/xundump-errors/colhdr-miss2:21: header 'nrndx' missing
+tests/empdump/xundump-errors/colhdr-miss2:21: header 'nrdep' missing
+tests/empdump/xundump-errors/colhdr-miss2:21: header 'nlndx' missing
+tests/empdump/xundump-errors/colhdr-miss2:21: header 'nlmin' missing
+tests/empdump/xundump-errors/colhdr-miss2:21: header 'nllag' missing
+tests/empdump/xundump-errors/colhdr-noidx:2: header 'name' doesn't take an index in field 1
+tests/empdump/xundump-errors/colhdr-sep:2: bad field separator after field 1
+tests/empdump/xundump-errors/colhdr-symidx:2: symbolic index in header field 1 not yet implemented
+tests/empdump/xundump-errors/colhdr-unexp2:2: expected header 'pkg(0)' in field 7
+tests/empdump/xundump-errors/colhdr-unk:2: unknown header 'xxx' in field 1
+tests/empdump/xundump-errors/fld-ambsym:2: ambiguous flags symbol 's' in field 29
+tests/empdump/xundump-errors/fld-badnum:3: field 2 can't hold this value
+tests/empdump/xundump-errors/fld-constnum:3: value for field 1 must be 0
+tests/empdump/xundump-errors/fld-conststr:3: value for field 1 must be "road network"
+tests/empdump/xundump-errors/fld-conststr2:8: value for field 2 must be nil
+tests/empdump/xundump-errors/fld-eof:2: field 'name' missing
+tests/empdump/xundump-errors/fld-eof:2: field 'civil' missing
+tests/empdump/xundump-errors/fld-eof:2: field 'milit' missing
+tests/empdump/xundump-errors/fld-eof:2: field 'shell' missing
+tests/empdump/xundump-errors/fld-eof:2: field 'gun' missing
+tests/empdump/xundump-errors/fld-eof:2: field 'petrol' missing
+tests/empdump/xundump-errors/fld-eof:2: field 'iron' missing
+tests/empdump/xundump-errors/fld-eof:2: field 'dust' missing
+tests/empdump/xundump-errors/fld-eof:2: field 'bar' missing
+tests/empdump/xundump-errors/fld-eof:2: field 'food' missing
+tests/empdump/xundump-errors/fld-eof:2: field 'oil' missing
+tests/empdump/xundump-errors/fld-eof:2: field 'lcm' missing
+tests/empdump/xundump-errors/fld-eof:2: field 'hcm' missing
+tests/empdump/xundump-errors/fld-eof:2: field 'uw' missing
+tests/empdump/xundump-errors/fld-eof:2: field 'rad' missing
+tests/empdump/xundump-errors/fld-eof:2: field 'l_build' missing
+tests/empdump/xundump-errors/fld-eof:2: field 'h_build' missing
+tests/empdump/xundump-errors/fld-eof:2: field 'armor' missing
+tests/empdump/xundump-errors/fld-eof:2: field 'speed' missing
+tests/empdump/xundump-errors/fld-eof:2: field 'visib' missing
+tests/empdump/xundump-errors/fld-eof:2: field 'vrnge' missing
+tests/empdump/xundump-errors/fld-eof:2: field 'frnge' missing
+tests/empdump/xundump-errors/fld-eof:2: field 'glim' missing
+tests/empdump/xundump-errors/fld-eof:2: field 'nxlight' missing
+tests/empdump/xundump-errors/fld-eof:2: field 'nchoppers' missing
+tests/empdump/xundump-errors/fld-eof:2: field 'tech' missing
+tests/empdump/xundump-errors/fld-eof:2: field 'cost' missing
+tests/empdump/xundump-errors/fld-eof:2: field 'flags' missing
+tests/empdump/xundump-errors/fld-eof:2: field 'nplanes' missing
+tests/empdump/xundump-errors/fld-eof:2: field 'nland' missing
+tests/empdump/xundump-errors/fld-invesc:2: invalid escape sequence in field 1
+tests/empdump/xundump-errors/fld-invid:3: field 1 can't hold this value
+tests/empdump/xundump-errors/fld-invid1:3: expected 0 in field 1
+tests/empdump/xundump-errors/fld-invid2:3: field 1 must be > -1
+tests/empdump/xundump-errors/fld-invid3:4: field 1 must be > 2
+tests/empdump/xundump-errors/fld-invid4:3: field 1 must be <= 98
+tests/empdump/xundump-errors/fld-invid5:4: coordinates in fields 1,2 must be > 2,0
+tests/empdump/xundump-errors/fld-invid6:3: field 0 must be between 0 and 99
+tests/empdump/xundump-errors/fld-invid7:3: field 1 must be between 0 and 50
+tests/empdump/xundump-errors/fld-invid8:4: fields 1,2 must be > (0,1)
+tests/empdump/xundump-errors/fld-junk:2: junk in field 1
+tests/empdump/xundump-errors/fld-junk2:2: junk in field 19
+tests/empdump/xundump-errors/fld-malnum:2: malformed number in field 1
+tests/empdump/xundump-errors/fld-malstr:2: malformed string in field 1
+tests/empdump/xundump-errors/fld-many:2: too many fields, expected only 6
+tests/empdump/xundump-errors/fld-miss:2: field 'name' missing
+tests/empdump/xundump-errors/fld-miss:2: field 'mnem' missing
+tests/empdump/xundump-errors/fld-miss:2: field 'value' missing
+tests/empdump/xundump-errors/fld-miss:2: field 'sell' missing
+tests/empdump/xundump-errors/fld-miss:2: field 'lbs' missing
+tests/empdump/xundump-errors/fld-miss:2: field 'pkg(0)' missing
+tests/empdump/xundump-errors/fld-miss:2: field 'pkg(1)' missing
+tests/empdump/xundump-errors/fld-miss:2: field 'pkg(2)' missing
+tests/empdump/xundump-errors/fld-miss:2: field 'pkg(3)' missing
+tests/empdump/xundump-errors/fld-miss:2: field 'pkg(4)' missing
+tests/empdump/xundump-errors/fld-miss:2: field 'melt_denom' missing
+tests/empdump/xundump-errors/fld-miss2:3: field 'ctype(0)' missing
+tests/empdump/xundump-errors/fld-nonil:3: field 19 doesn't take nil
+tests/empdump/xundump-errors/fld-nonum:3: field 2 doesn't take numbers
+tests/empdump/xundump-errors/fld-nostr:3: field 1 doesn't take strings
+tests/empdump/xundump-errors/fld-nosym:2: field 1 doesn't take symbols
+tests/empdump/xundump-errors/fld-nosymset:2: field 1 doesn't take symbol sets
+tests/empdump/xundump-errors/fld-sep:2: bad field separator after field 1
+tests/empdump/xundump-errors/fld-strbig:3: field 19 takes at most 9 characters
+tests/empdump/xundump-errors/fld-unexpid:6: table's first part doesn't have this row
+tests/empdump/xundump-errors/fld-unexpid1:7: value for field 1 must be 2
+tests/empdump/xundump-errors/fld-unksym:2: unknown level symbol 'xxx' in field 11
+tests/empdump/xundump-errors/fld-unparen:2: unmatched '(' in field 19
+tests/empdump/xundump-errors/ftr-fewrows:2: expected 34 more rows
+tests/empdump/xundump-errors/ftr-fewrows2:4: expected 13 more rows
+tests/empdump/xundump-errors/ftr-fewrows3:4: expected 1 more rows
+tests/empdump/xundump-errors/ftr-fewrows4:7: table's first part has more rows
+tests/empdump/xundump-errors/ftr-junk:2: junk after table footer
+tests/empdump/xundump-errors/ftr-mal:2: malformed table footer
+tests/empdump/xundump-errors/ftr-mal2:6: malformed table footer
+tests/empdump/xundump-errors/ftr-manyrows:5: too many rows
+tests/empdump/xundump-errors/ftr-manyrows2:17: too many rows
+tests/empdump/xundump-errors/ftr-mismatch:2: expected footer /0
+tests/empdump/xundump-errors/hdr-extra:2: extraneous header 'timestamp' in field 1
+tests/empdump/xundump-errors/hdr-extra2:2: extraneous header 'uid' in field 1
+tests/empdump/xundump-errors/hdr-junk:1: junk after xdump header
+tests/empdump/xundump-errors/hdr-none:1: expected xdump header
+tests/empdump/xundump-errors/hdr-noperm:1: table 'map' is not permitted here
+tests/empdump/xundump-errors/hdr-noperm2:1: table 'table' is not permitted here
+tests/empdump/xundump-errors/hdr-unexp:4: expected table 'ship', not 'plane'
+tests/empdump/xundump-errors/hdr-unktab:1: unknown table 'xxx'
File plane uid 0 field flags: bit 8 is not in symbol table plane-flags
File plane uid 1 field mission: value 99 is not in symbol table missions
File plane uid 2 field owner: value 255 indexes table nat out of bounds 0..99
config sect-chr
uid name m
-# Header m of field 3 is ambiguous
+# ambiguous header 'm' in field 3
/config
config ship-chr
name name
-# Duplicate header name in field 2
+# duplicate header 'name' in field 2
config ship-chr
type name name
-# Duplicate header name in field 3
+# duplicate header 'name' in field 3
/config
config item
uid name mnem value sell lbs pkg(0) pkg(0)
-# Duplicate header pkg(0) in field 8
+# expected header 'pkg(1)' in field 8
/config
config product
...
-# Header fields expected
+# header fields expected
config item
uid ... name
-# Junk after ...
+# junk after ...
-config ship-chr # Unexpected EOF
+config ship-chr # unexpected EOF
config item
-uid name mnem value sell lbs pkg(99)
-# Header pkg(99) index out of bounds in field 7
+uid name mnem value sell lbs pkg(0) pkg(1) pkg(2) pkg(3) pkg(4) pkg(99)
+# unexpected header 'pkg(99)' in field 12
config item
uid name mnem value sell lbs pkg(-1)
-# Index must not be negative in header field 7
+# index must not be negative in header field 7
config item
uid name mnem value sell lbs pkg
-# Header pkg requires an index in field 7
+# header 'pkg' requires an index in field 7
config item
0
-# Junk in header field 1
+# junk in header field 1
config item
/config
-# Junk in header field 1
+# junk in header field 1
config item
.a
-# Junk in header field 1
+# junk in header field 1
config item
x(-
-# Malformed number in index of header field 1
+# malformed number in index of header field 1
config item
x(!
-# Malformed index in header field 1
+# malformed index in header field 1
config item
x(0 y
-# Malformed index in header field 1
+# malformed index in header field 1
config product
name sname ctype(0) ctype(1) type level cost nrndx nrdep nlndx nlmin
-# Header field uid missing
-# Header field ctype(2) missing
-# Header fields camt(0) ... camt(2) missing
-# Header field nllag missing
+# header 'uid' missing
+# header 'ctype(2)' missing
+# header 'camt(0)' ... 'camt(2)' missing
+# header 'nllag' missing
/config
config product
name
-# Header fields ctype(0) ... ctype(2) missing
-# Header fields camt(0) ... camt(2) missing
-# Header field type missing
-# Header field level missing
-# Header field cost missing
-# Header field nrndx missing
-# Header field nrdep missing
-# Header field nlndx missing
-# Header field nlmin missing
-# Header field nllag missing
+# header 'ctype(0)' ... 'ctype(2)' missing
+# header 'camt(0)' ... 'camt(2)' missing
+# header 'type' missing
+# header 'level' missing
+# header 'cost' missing
+# header 'nrndx' missing
+# header 'nrdep' missing
+# header 'nlndx' missing
+# header 'nlmin' missing
+# header 'nllag' missing
config ship-chr
name(0)
-# Header name doesn't take an index in field 1
+# header 'name' doesn't take an index in field 1
config item
u=
-# Bad field separator after field 1
+# bad field separator after field 1
config item
f(x)
-# Symbolic index in header field 1 not yet implemented
+# symbolic index in header field 1 not yet implemented
config item
uid name mnem value sell lbs pkg(1)
-# Expected header pkg(0) in field 7
+# expected header 'pkg(0)' in field 7
/config
config ship-chr
xxx
-# Header xxx of field 1 is unknown
+# unknown header 'xxx' in field 1
/config
XDUMP ship-chr 1
0 "ft\040\040\040fishing\040trawler" 300 10 0 0 0 0 0 0 900 0 0 0 15 0 25 15 10 25 15 2 0 0 0 0 35 300 (sw s) 0 0
-# Ambiguous flags symbol `s' in field 29
+# ambiguous flags symbol 's' in field 29
config land
uid owner ...
0 1.1
-# Field 2 can't hold this value
+# field 2 can't hold this value
config sect
xloc yloc ...
64 0
-# Value for field 1 must be 0
+# value for field 1 must be 0
config infrastructure
name lcms hcms dcost mcost enable
"lala" 1 1 1 1 1
-# Value for field 1 must be "road network"
+# value for field 1 must be "road network"
config ship-chr
type name ...
0 "non-nil"
-# Value for field 2 must be nil
+# value for field 2 must be nil
XDUMP ship-chr 0
-0 # Unexpected EOF
\ No newline at end of file
+0 # unexpected EOF
XDUMP infrastructure 0
"lala\0"
-# Invalid escape sequence in field 1
+# invalid escape sequence in field 1
config ship
uid ...
0.1
-# Field 1 can't hold this value
+# field 1 can't hold this value
config item
uid ...
1
-# Expected 0 in field 1
+# expected 0 in field 1
config ship
uid ...
-1
-# Field 1 must be > -1
+# field 1 must be > -1
uid ...
2
0
-# Field 1 must be > 2
+# field 1 must be > 2
config nat
cnum ...
100
-# Field 1 must be <= 98
+# field 1 must be <= 98
xloc yloc ...
2 0
0 0
-# Coordinates in fields 1,2 must be > 2,0
+# coordinates in fields 1,2 must be > 2,0
config realm
cnum realm ...
100 0
-# Field 0 must be between 0 and 99
+# field 0 must be between 0 and 99
config realm
cnum realm ...
0 100
-# Field 1 must be between 0 and 50
+# field 1 must be between 0 and 50
cnum realm ...
0 1
0 0
-# Fields 1,2 must be > (0,1)
+# fields 1,2 must be > (0,1)
XDUMP infrastructure 0
!
-# Junk in field 1
+# junk in field 1
XDUMP plane 0
0 1 0 0 0 0 0 0 0 0 0 0 0 "" 0 -1 -1 0 (!
-# Junk in field 19
+# junk in field 19
XDUMP infrastructure 0
+
-# Malformed number in field 1
+# malformed number in field 1
XDUMP infrastructure 0
"lala
-# Malformed string in field 1
+# malformed string in field 1
XDUMP realm 0
0 0 2 3 4 5 6 7 8 9 a b c d e f 0 1 2 3 4 5 6 7 8 9 a b c d e f 0 1 2 3 4 5 6 7 8 9 a b c d e f 0 1 2 3 4 5 6 7 8 9 a b c d e f 0 1 2 3 4 5 6 7 8 9 a b c d e f 0 1 2 3 4 5 6 7 8 9 a b c d e f 0 1 2 3 4 5 6 7 8 9 a b c d e f 0 1 2 3 4 5 6 7 8 9 a b c d e f 0 1 2 3 4 5 6 7 8 9 a b c d e f 0 1 2 3 4 5 6 7 8 9 a b c d e f 0 1 2 3 4 5 6 7 8 9 a b c d e f 0 1 2 3 4 5 6 7 8 9 a b c d e f 0 1 2 3 4 5 6 7 8 9 a b c d e f 0 1 2 3 4 5 6 7 8 9 a b c d e f 0 1 2 3 4 5 6 7 8 9 a b c d e f 0 1 2 3 4 5 6 7 8 9 a b c d e f
-# Too many fields, expected only 6
+# too many fields, expected only 6
XDUMP item 0
0
-# Field name missing
-# Field mnem missing
-# Field value missing
-# Field sell missing
-# Field lbs missing
-# Field pkg(0) missing
-# Field pkg(1) missing
-# Field pkg(2) missing
-# Field pkg(3) missing
-# Field pkg(4) missing
-# Field melt_denom missing
+# field 'name' missing
+# field 'mnem' missing
+# field 'value' missing
+# field 'sell' missing
+# field 'lbs' missing
+# field 'pkg(0)' missing
+# field 'pkg(1)' missing
+# field 'pkg(2)' missing
+# field 'pkg(3)' missing
+# field 'pkg(4)' missing
+# field 'melt_denom' missing
config product
uid name sname ct(0) ...
0 "iron\040ore" "iron"
-# Field ctype(0) missing
+# field 'ctype(0)' missing
config land
uid owner xloc yloc type effic mobil off tech opx opy mission radius army ship harden retreat rflags rpath ...
0 1 0 0 0 100 0 0 100 0 0 0 0 "" -1 0 42 0 nil
-# Field 19 doesn't take nil
+# field 19 doesn't take nil
config item
uid name ...
0 0
-# Field 2 doesn't take numbers
+# field 2 doesn't take numbers
config item
uid ...
""
-# Field 1 doesn't take strings
+# field 1 doesn't take strings
XDUMP infrastructure 0
xxx
-# Field 1 doesn't take symbols
+# field 1 doesn't take symbols
XDUMP infrastructure 0
()
-# Field 1 doesn't take symbol sets
+# field 1 doesn't take symbol sets
XDUMP ship-chr 0
0!
-# Bad field separator after field 1
+# bad field separator after field 1
config land
uid owner xloc yloc type effic mobil off tech opx opy mission radius army ship harden retreat rflags rpath ...
0 1 0 0 0 100 0 0 100 0 0 0 0 "" -1 0 42 0 "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
-# Field 19 takes at most 9 characters
+# field 19 takes at most 9 characters
config ship
uid ...
2
-# Table's first part doesn't have this row
+# table's first part doesn't have this row
/config
config ship
uid ...
1
-# Value for field 1 must be 2
+# value for field 1 must be 2
/config
XDUMP product 1
0 "iron ore" "iron" 0 0 0 0 0 0 0 xxx
-# Unknown level symbol `xxx' in field 11
+# unknown level symbol 'xxx' in field 11
XDUMP plane 0
0 1 0 0 0 0 0 0 0 0 0 0 0 "" 0 -1 -1 0 (launched sync
-# Unmatched '(' in field 19
+# unmatched '(' in field 19
XDUMP sect-chr 0
/0
-# Expected 34 more rows
+# expected 34 more rows
uid ...
0
/config
-# Expected 13 more rows
+# expected 13 more rows
"road\040network" 2 2 2 1 1
"rail\040network" 1 1 1 1 1
/2
-# Expected 1 more rows
+# expected 1 more rows
config ship
uid ...
/config
-# Table's first part has more rows
+# table's first part has more rows
XDUMP ship-chr 1130359236
/0x
-# Junk after table footer
+# junk after table footer
XDUMP ship-chr 1130359236
/x
-# Malformed table footer
+# malformed table footer
"rail network" 1 1 1 1 1
"defense factor" 1 1 1 1 0
/con
-# Malformed table footer
+# malformed table footer
"rail\040network" 1 1 1 1 1
"defense\040factor" 1 1 1 1 0
"lala" 1 1 1 1 1
-# Too many rows
+# too many rows
/4
12
13
14
-# Too many rows
+# too many rows
XDUMP ship-chr 1130359236
/2
-# Read 0 rows, which doesn't match footer 2 rows
+# expected footer /0
config news
timestamp
-# Extraneous header timestamp in field 1
+# extraneous header 'timestamp' in field 1
config sect
uid ...
-# Extraneous header uid in field 1
+# extraneous header 'uid' in field 1
XDUMP ship 1130359236 junk
-# Junk after xdump header
+# junk after xdump header
/0
junk
-# Expected xdump header
+# expected xdump header
config map
-# Table `map' is not permitted here
+# table 'map' is not permitted here
config table
-# Table `table' is not permitted here
+# table 'table' is not permitted here
uid ...
/config
config plane
-# Expected table `ship', not `plane'
+# expected table 'ship', not 'plane'
XDUMP xxx 1
-# Unknown table `xxx'
+# unknown table 'xxx'