[m-rev.] for review: allow reporting of statistics to a stream for Java
zoltan.somogyi at runbox.com
Tue Mar 23 11:38:22 AEDT 2021
On Tue, 23 Mar 2021 10:59:38 +1100 (AEDT), Julien Fischer <jfischer at opturion.com> wrote:
> - we need to decide how I/O errors that occur when reporting statistics
> are handled (see XXXs below).
Agreed, though I have no idea how Java programmers
generally handle such errors.
> - the C implementation does not update the line number counter
> associated with the (Mercury) stream.
I am not sure streams *had* line number counters when that code
was written :-( Will you fix this, or should I?
BTW, the C# and Java implementations do not seem to update
the line counter either.
> - it would be nice to have a version of the statistics reporting code
> that prints a user specified prefix at the beginning of each line.
The names of the predicates that did this would need to be different
from the current ones, because otherwise we would have e.g.
two different report_standard_stats/3 predicates: one in which
the first arg is a stream, and one in which it is this prefix string.
We could add "_with_prefix" to the relevant predicate names as a suffix.
Any other proposals for names?
The diff is fine. Thank you.
More information about the reviews