Skip to content

Commit e5a842d

Browse files
committed
COMMON: update const error message
1 parent 960ec12 commit e5a842d

File tree

3 files changed

+3
-4
lines changed

3 files changed

+3
-4
lines changed

samples/distro-examples/tests/output/trycatch.out

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@ Stack:
1414
IF: 193
1515
IF: 192
1616
SUB: 216
17-
1817

1918

2019
* RTE-ERROR AT ../../../samples/distro-examples/tests/trycatch.bas:200 *

src/common/sberr.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -179,11 +179,11 @@ void err_argerr(void) {
179179
}
180180

181181
void err_varisarray(void) {
182-
rt_raise(EVAL_VAR_IS_ARRAY);
182+
err_throw(EVAL_VAR_IS_ARRAY);
183183
}
184184

185185
void err_varisnotarray(void) {
186-
rt_raise(EVAL_VAR_IS_NOT_ARRAY);
186+
err_throw(EVAL_VAR_IS_NOT_ARRAY);
187187
}
188188

189189
void err_vararridx(int i, int m) {

src/languages/messages.en.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -172,7 +172,7 @@
172172
#define EVAL_TYPE "Expr/RT: Type mismatch"
173173
#define EVAL_PARAM "Expr/RT: Invalid parameter"
174174
#define ERR_UNSUPPORTED "Unsupported"
175-
#define ERR_CONST "LET: Cannot change a constant"
175+
#define ERR_CONST "LET: Cannot change a constant (CONST always has global scope)"
176176
#define ERR_NOT_A_VAR "Not a variable"
177177
#define ERR_NOT_ARR_OR_FUNC "NOT an array OR function"
178178
#define ERR_RANGE "Out of range"

0 commit comments

Comments
 (0)