1
0
mirror of https://github.com/janet-lang/janet synced 2024-12-27 00:40:26 +00:00

Fix struct proto missing when making a struct with a nil value.

This commit is contained in:
Calvin Rose 2021-11-23 23:16:06 -06:00
parent a99500aebf
commit e08394c870

View File

@ -150,6 +150,7 @@ const JanetKV *janet_struct_end(JanetKV *st) {
janet_struct_put(newst, kv->key, kv->value); janet_struct_put(newst, kv->key, kv->value);
} }
} }
janet_struct_proto(newst) = janet_struct_proto(st);
st = newst; st = newst;
} }
janet_struct_hash(st) = janet_kv_calchash(st, janet_struct_capacity(st)); janet_struct_hash(st) = janet_kv_calchash(st, janet_struct_capacity(st));