1
0
Fork 0
mirror of https://github.com/NixOS/nix synced 2025-06-30 11:43:15 +02:00

builtins.warn: Use new EvalBaseError + "evaluation warning"

This commit is contained in:
Robert Hensing 2024-05-22 12:51:46 +02:00
parent 831d96d8d7
commit 70b1036224
6 changed files with 53 additions and 7 deletions

View file

@ -70,6 +70,13 @@ EvalErrorBuilder<T>::addTrace(PosIdx pos, std::string_view formatString, const A
return *this;
}
template<class T>
EvalErrorBuilder<T> & EvalErrorBuilder<T>::setIsFromExpr()
{
error.err.isFromExpr = true;
return *this;
}
template<class T>
void EvalErrorBuilder<T>::debugThrow()
{
@ -85,6 +92,7 @@ void EvalErrorBuilder<T>::debugThrow()
throw error;
}
template class EvalErrorBuilder<EvalBaseError>;
template class EvalErrorBuilder<EvalError>;
template class EvalErrorBuilder<AssertionError>;
template class EvalErrorBuilder<ThrownError>;