CHanged errors somewhat.
This commit is contained in:
parent
3e55cb6302
commit
5c52b6a75a
|
@ -22,14 +22,14 @@ intobject TrueObject = {
|
||||||
static object *
|
static object *
|
||||||
err_ovf()
|
err_ovf()
|
||||||
{
|
{
|
||||||
err_setstr(RuntimeError, "integer overflow");
|
err_setstr(OverflowError, "integer overflow");
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
static object *
|
static object *
|
||||||
err_zdiv()
|
err_zdiv()
|
||||||
{
|
{
|
||||||
err_setstr(RuntimeError, "division by zero");
|
err_setstr(ZeroDivisionError, "integer division by zero");
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -55,7 +55,7 @@ getintvalue(op)
|
||||||
register object *op;
|
register object *op;
|
||||||
{
|
{
|
||||||
if (!is_intobject(op)) {
|
if (!is_intobject(op)) {
|
||||||
err_badarg();
|
err_badcall();
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
|
Loading…
Reference in New Issue