mirror of
https://github.com/NixOS/nix
synced 2025-06-25 14:51:16 +02:00
Initial frames support
This commit is contained in:
parent
3f9f6ae127
commit
b945b844a9
5 changed files with 63 additions and 13 deletions
|
@ -110,6 +110,7 @@ void printAtPos(const ErrPos & pos, std::ostream & out);
|
|||
struct Trace {
|
||||
std::optional<ErrPos> pos;
|
||||
hintformat hint;
|
||||
bool frame;
|
||||
};
|
||||
|
||||
struct ErrorInfo {
|
||||
|
@ -188,7 +189,7 @@ public:
|
|||
addTrace(e, hintfmt(std::string(fs), args...));
|
||||
}
|
||||
|
||||
void addTrace(std::optional<ErrPos> e, hintformat hint);
|
||||
void addTrace(std::optional<ErrPos> e, hintformat hint, bool frame = false);
|
||||
|
||||
bool hasTrace() const { return !err.traces.empty(); }
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue