Explorar el Código

array index out of bounds returns none now

master
Martin Dørum hace 3 años
padre
commit
a60ae14896
Se han modificado 1 ficheros con 1 adiciones y 1 borrados
  1. 1
    1
      lib/vm/vm.c

+ 1
- 1
lib/vm/vm.c Ver fichero

@@ -156,7 +156,7 @@ const char *l2_value_type_name(enum l2_value_type typ) {

l2_word l2_value_arr_get(struct l2_vm *vm, struct l2_vm_value *val, l2_word k) {
if (k >= val->extra.arr_length) {
return l2_vm_error(vm, "Array index out of bounds");
return vm->knone;
}

if (val->flags & L2_VAL_SBO) {

Cargando…
Cancelar
Guardar