File and line numbers in error messages
Jeffrey Hutzelman
jhutz at cmu.edu
Wed Apr 29 17:58:22 EDT 2009
--On Wednesday, April 29, 2009 05:37:58 PM -0400 Greg Hudson
<ghudson at mit.edu> wrote:
> As Sam pointed out, the onus is on us to make our error messages clear,
> not rely on obscure features to support people who get unclear error
> messages.
Clear error messages help the user figure out what is wrong and how to fix
it. Unfortunately, they also encourage the user to explain what they think
is wrong in their own words instead of quoting something you can grep for.
In addition, even if the user _does_ quote the message, having clear error
messages also often means producing the same error message in multiple
places. That makes it a pain to figure out which code path produced the
message. Including the filename and line number can be fairly useful in
resolving this, and also helps people who are not deeply familiar with the
source tree to figure out where to start looking.
-- Jeff
More information about the krbdev
mailing list