make use of new Error class APIs

This commit is contained in:
Axel Kohlmeyer
2025-01-22 22:15:08 -05:00
parent 3012e02de1
commit cc36947449
5 changed files with 33 additions and 25 deletions

View File

@ -178,7 +178,8 @@ std::string utils::strfind(const std::string &text, const std::string &pattern)
void utils::missing_cmd_args(const std::string &file, int line, const std::string &cmd,
Error *error)
{
if (error) error->all(file, line, "Illegal {} command: missing argument(s)", cmd);
if (error)
error->all(file, line, Error::NOPOINTER, "Illegal {} command: missing argument(s)", cmd);
}
std::string utils::point_to_error(Input *input, int failed)