diff options
author | Jo-Philipp Wich <jo@mein.io> | 2021-12-05 00:16:53 +0100 |
---|---|---|
committer | Jo-Philipp Wich <jo@mein.io> | 2021-12-05 00:26:54 +0100 |
commit | 3489b7571ee5e0e69f9f5724cd5b3701591353d1 (patch) | |
tree | 65add922f24250f859f3b753dc4f6d0e9d10c5f4 | |
parent | 07802f37ddb13489cfde314716ad6181dd9b1671 (diff) |
vm: support object property access on resource value types
Allow querying object properties on resource values. A resource value may
have a prototype object set whose properties should be enumerable.
Support that use case in the VM.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
-rw-r--r-- | vm.c | 1 |
1 files changed, 1 insertions, 0 deletions
@@ -1025,6 +1025,7 @@ uc_vm_insn_load_val(uc_vm_t *vm, uc_vm_insn_t insn) uc_value_t *v = uc_vm_stack_pop(vm); switch (ucv_type(v)) { + case UC_RESSOURCE: case UC_OBJECT: case UC_ARRAY: uc_vm_stack_push(vm, ucv_key_get(vm, v, k)); |