1
0
Fork 0
mirror of https://github.com/NixOS/nix synced 2025-06-25 19:01:16 +02:00

* Don't show trace information by default (`--show-trace' to enable).

NixOS evaluation errors in particular look intimidating and
  generally aren't very useful.  Ideally the builtins.throw messages
  should be self-contained.
This commit is contained in:
Eelco Dolstra 2009-06-30 13:28:29 +00:00
parent a2fc3a53ba
commit f2c3fc5191
6 changed files with 21 additions and 3 deletions

View file

@ -24,12 +24,14 @@ using boost::format;
class BaseError : public std::exception
{
protected:
string prefix_; // used for location traces etc.
string err;
public:
BaseError(const format & f);
~BaseError() throw () { };
const char * what() const throw () { return err.c_str(); }
const string & msg() const throw () { return err; }
const string & prefix() const throw () { return prefix_; }
BaseError & addPrefix(const format & f);
};