summaryrefslogtreecommitdiffstats
path: root/src/libexpr/eval.cc
diff options
context:
space:
mode:
authorEelco Dolstra <edolstra@gmail.com>2020-06-15 13:50:33 +0200
committerEelco Dolstra <edolstra@gmail.com>2020-06-15 13:50:33 +0200
commitfd64e4fb96f814440dc337ce664cdbd22e0eabb2 (patch)
tree3a52bc42728f242e59c34213e068d58b9a27bdb0 /src/libexpr/eval.cc
parent7a77762961aee116e7179ea57f07e143d74aba1f (diff)
Disambiguate BaseError(Args) constructor
This means that 'throw Error({ ... ErrorInfo ... })' now works.
Diffstat (limited to 'src/libexpr/eval.cc')
-rw-r--r--src/libexpr/eval.cc9
1 files changed, 4 insertions, 5 deletions
diff --git a/src/libexpr/eval.cc b/src/libexpr/eval.cc
index 7bf25ea17..75e6a23a1 100644
--- a/src/libexpr/eval.cc
+++ b/src/libexpr/eval.cc
@@ -506,11 +506,10 @@ LocalNoInlineNoReturn(void throwEvalError(const char * s, const string & s2))
LocalNoInlineNoReturn(void throwEvalError(const Pos & pos, const char * s, const string & s2))
{
- throw EvalError(
- ErrorInfo {
- .hint = hintfmt(s, s2),
- .nixCode = NixCode { .errPos = pos }
- });
+ throw EvalError({
+ .hint = hintfmt(s, s2),
+ .nixCode = NixCode { .errPos = pos }
+ });
}
LocalNoInlineNoReturn(void throwEvalError(const char * s, const string & s2, const string & s3))