1
0
Fork 0
mirror of https://github.com/NixOS/nix synced 2025-07-06 21:41:48 +02:00

switch to one level of builder function, not subobject functions

This commit is contained in:
Ben Burdette 2020-03-24 14:24:57 -06:00
parent 657c08c852
commit fc310eda3a
2 changed files with 112 additions and 132 deletions

View file

@ -34,41 +34,34 @@ using namespace nix;
print_error(generic);
*/
StandardError standardError;
print_error(standardError
print_error(StandardError()
.name("name")
.description("description"));
StandardWarning standardWarning;
print_error(standardWarning
print_error(StandardWarning()
.name("warning name")
.description("warning description"));
print_error(MkNixError()
.name("name")
.description("description")
.nixcode(
MkNixCode()
.nixFile("myfile.nix")
.errLine(MkErrLine().lineNumber(40)
.columnRange(13,7)
.linesOfCode(nullopt
,"this is the problem line of code"
,nullopt))));
print_error(MkNixWarning()
.name("name")
.description("description")
.nixcode(
MkNixCode()
.nixFile("myfile.nix")
.errLine(MkErrLine().lineNumber(40)
.columnRange(13,7)
.linesOfCode(nullopt
,"this is the problem line of code"
,nullopt))));
.name("warning name")
.description("warning description")
.nixFile("myfile.nix")
.lineNumber(40)
.columnRange(13,7)
.linesOfCode(nullopt
,"this is the problem line of code"
,nullopt));
print_error(MkNixError()
.name("error name")
.description("warning description")
.nixFile("myfile.nix")
.lineNumber(40)
.columnRange(13,7)
.linesOfCode(nullopt
,"this is the problem line of code"
,nullopt));
return 0;
}