diff options
author | Bad Diode <bd@badd10de.dev> | 2021-10-13 16:44:17 +0200 |
---|---|---|
committer | Bad Diode <bd@badd10de.dev> | 2021-10-13 16:44:17 +0200 |
commit | ed1f406102738812fafa5e49ee131fe06c177687 (patch) | |
tree | 0bb648c18b6f96e0f020a9f8e664df330199b51b /src/bootstrap/errors.c | |
parent | b8bad3bf5af3261f25780a8cd8b90a659fe29bab (diff) | |
download | bdl-ed1f406102738812fafa5e49ee131fe06c177687.tar.gz bdl-ed1f406102738812fafa5e49ee131fe06c177687.zip |
Add a lot of primitive types
Diffstat (limited to 'src/bootstrap/errors.c')
-rw-r--r-- | src/bootstrap/errors.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/bootstrap/errors.c b/src/bootstrap/errors.c index c9d9c97..13a2f3c 100644 --- a/src/bootstrap/errors.c +++ b/src/bootstrap/errors.c | |||
@@ -17,6 +17,7 @@ typedef enum ErrorValue { | |||
17 | ERR_OBJ_NOT_CALLABLE, | 17 | ERR_OBJ_NOT_CALLABLE, |
18 | ERR_NOT_ENOUGH_ARGS, | 18 | ERR_NOT_ENOUGH_ARGS, |
19 | ERR_WRONG_ARG_TYPE, | 19 | ERR_WRONG_ARG_TYPE, |
20 | ERR_DIVISION_BY_ZERO, | ||
20 | } ErrorValue; | 21 | } ErrorValue; |
21 | 22 | ||
22 | typedef struct Error { | 23 | typedef struct Error { |
@@ -39,6 +40,7 @@ static const char* error_msgs[] = { | |||
39 | [ERR_OBJ_NOT_CALLABLE] = "error: object is not callable", | 40 | [ERR_OBJ_NOT_CALLABLE] = "error: object is not callable", |
40 | [ERR_NOT_ENOUGH_ARGS] = "error: not enough arguments", | 41 | [ERR_NOT_ENOUGH_ARGS] = "error: not enough arguments", |
41 | [ERR_WRONG_ARG_TYPE] = "error: wrong argument type", | 42 | [ERR_WRONG_ARG_TYPE] = "error: wrong argument type", |
43 | [ERR_DIVISION_BY_ZERO] = "error: division by zero", | ||
42 | }; | 44 | }; |
43 | 45 | ||
44 | #define ERR_MAX_NUMBER 16 | 46 | #define ERR_MAX_NUMBER 16 |