(parse): When an entry does not balance, print the entry so the user

can see what Ledger saw.
This commit is contained in:
John Wiegley 2005-02-13 23:27:02 +00:00
parent 32df4dd563
commit 10c78678bc

View file

@ -572,8 +572,9 @@ unsigned int textual_parser_t::parse(std::istream& in,
entry->end_pos = in.tellg();
count++;
} else {
print_entry(std::cerr, *entry);
delete entry;
throw parse_error(path, first_line, "Entry does not balance");
throw parse_error(path, first_line, "Entry above does not balance");
}
} else {
throw parse_error(path, first_line, "Failed to parse entry");