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

errorinfo constructor test

This commit is contained in:
Ben Burdette 2020-04-29 18:57:05 -06:00
parent 2d0f766a77
commit 39ff80d031
4 changed files with 16 additions and 5 deletions

View file

@ -23,6 +23,16 @@ int main()
logger->logEI(e.info());
}
// ErrorInfo constructor
try {
auto e = Error("generic error");
throw DemoError(e.info());
} catch (Error &e) {
logger->logEI(e.info());
}
// For completeness sake, info through vomit levels.
// But this is maybe a heavy format for those.
logger->logEI(