add error for dividing by zero in static function evaluation

This commit is contained in:
Andrew Kelley
2016-04-12 16:18:41 -07:00
parent be4df96e4b
commit 69109bc270
6 changed files with 65 additions and 58 deletions

View File

@@ -12,6 +12,8 @@ const char *err_str(int err) {
case ErrorFileNotFound: return "file not found";
case ErrorFileSystem: return "file system error";
case ErrorFileTooBig: return "file too big";
case ErrorDivByZero: return "division by zero";
case ErrorOverflow: return "overflow";
}
return "(invalid error)";
}