rename errors/warnings
This commit is contained in:
parent
09652f597c
commit
9e7b89bf10
|
@ -256,11 +256,11 @@ class AddHint : private T
|
||||||
typedef AddName<
|
typedef AddName<
|
||||||
AddDescription<
|
AddDescription<
|
||||||
AddHint<
|
AddHint<
|
||||||
EIError>>> StandardError;
|
EIError>>> ProgramError;
|
||||||
typedef AddName<
|
typedef AddName<
|
||||||
AddDescription<
|
AddDescription<
|
||||||
AddHint<
|
AddHint<
|
||||||
EIWarning>>> StandardWarning;
|
EIWarning>>> ProgramWarning;
|
||||||
|
|
||||||
typedef AddName<
|
typedef AddName<
|
||||||
AddDescription<
|
AddDescription<
|
||||||
|
@ -269,7 +269,7 @@ typedef AddName<
|
||||||
AddColumnRange<
|
AddColumnRange<
|
||||||
AddLOC<
|
AddLOC<
|
||||||
AddHint<
|
AddHint<
|
||||||
EIError>>>>>>> MkNixError;
|
EIError>>>>>>> NixLangError;
|
||||||
typedef AddName<
|
typedef AddName<
|
||||||
AddDescription<
|
AddDescription<
|
||||||
AddNixFile<
|
AddNixFile<
|
||||||
|
@ -277,7 +277,7 @@ typedef AddName<
|
||||||
AddColumnRange<
|
AddColumnRange<
|
||||||
AddLOC<
|
AddLOC<
|
||||||
AddHint<
|
AddHint<
|
||||||
EIWarning>>>>>>> MkNixWarning;
|
EIWarning>>>>>>> NixLangWarning;
|
||||||
|
|
||||||
|
|
||||||
// --------------------------------------------------------
|
// --------------------------------------------------------
|
||||||
|
|
|
@ -14,44 +14,20 @@ int main()
|
||||||
|
|
||||||
ErrorInfo::programName = optional("error-test");
|
ErrorInfo::programName = optional("error-test");
|
||||||
|
|
||||||
/*
|
printErrorInfo(ProgramError()
|
||||||
ColumnRange columnRange;
|
|
||||||
columnRange.start = 24;
|
|
||||||
columnRange.len = 14;
|
|
||||||
|
|
||||||
ErrLine errline;
|
|
||||||
errline.lineNumber = 7;
|
|
||||||
errline.columnRange = optional(columnRange);
|
|
||||||
errline.errLineOfCode = "line of code where the error occurred";
|
|
||||||
|
|
||||||
NixCode nixcode;
|
|
||||||
nixcode.nixFile = optional("myfile.nix");
|
|
||||||
nixcode.errLine = errline;
|
|
||||||
|
|
||||||
ErrorInfo generic;
|
|
||||||
generic.level = elError;
|
|
||||||
generic.name = "error name";
|
|
||||||
generic.description = "general error description";
|
|
||||||
generic.program = "nixtool.exe";
|
|
||||||
generic.nixCode = nixcode;
|
|
||||||
|
|
||||||
printErrorInfo(generic);
|
|
||||||
*/
|
|
||||||
|
|
||||||
printErrorInfo(StandardError()
|
|
||||||
.name("name")
|
.name("name")
|
||||||
.description("error description")
|
.description("error description")
|
||||||
.nohint()
|
.nohint()
|
||||||
);
|
);
|
||||||
|
|
||||||
printErrorInfo(StandardWarning()
|
printErrorInfo(ProgramWarning()
|
||||||
.name("warning name")
|
.name("warning name")
|
||||||
.description("warning description")
|
.description("warning description")
|
||||||
.nohint()
|
.nohint()
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|
||||||
printErrorInfo(MkNixWarning()
|
printErrorInfo(NixLangWarning()
|
||||||
.name("warning name")
|
.name("warning name")
|
||||||
.description("warning description")
|
.description("warning description")
|
||||||
.nixFile("myfile.nix")
|
.nixFile("myfile.nix")
|
||||||
|
@ -63,7 +39,7 @@ int main()
|
||||||
.hint(hintfmt("this hint has %1% templated %2%!!") % "yellow" % "values")
|
.hint(hintfmt("this hint has %1% templated %2%!!") % "yellow" % "values")
|
||||||
);
|
);
|
||||||
|
|
||||||
printErrorInfo(MkNixError()
|
printErrorInfo(NixLangError()
|
||||||
.name("error name")
|
.name("error name")
|
||||||
.description("error description")
|
.description("error description")
|
||||||
.nixFile("myfile.nix")
|
.nixFile("myfile.nix")
|
||||||
|
|
Loading…
Reference in a new issue