[quickjs-devel] Re: how to iterator over a JSValue object?

  • From: "Sam Chang" <dmarc-noreply@xxxxxxxxxxxxx> (Redacted sender "sam.chang" for DMARC)
  • To: quickjs-devel@xxxxxxxxxxxxx
  • Date: Mon, 22 Jul 2019 11:09:44 +0800

Hi Ondrej,
It looks great, thanks!

Regards,
Sam

On Jul 19, 2019, at 7:59 PM, Ondřej Jirman <megi@xxxxxx> wrote:

Hi Sam,

On Fri, Jul 19, 2019 at 07:09:35PM +0800, Sam Chang wrote:
Hi,

I want to iterator an object in C, but i can’t find the suitable api, is any 
body knows? Thanks.

There's no public API for now, but you can get it hacked together by making
JS_GetIterator and JS_IteratorNext public in quickjs.c, and using those.

You can see how it can be used by going through some use cases in quickjs.c.

API may change in the future of course.

regards,
      Ondrej


Regards,
Sam



Other related posts: