Function quickjs_runtime::quickjs_utils::iterators::iterate[][src]

pub unsafe fn iterate<C: Fn(JSValueRef) -> Result<R, EsError>, R>(
    ctx: *mut JSContext,
    iterator_ref: &JSValueRef,
    consumer_producer: C
) -> Result<Vec<R>, EsError>

iterate over an object conforming to the iterator protocol

Safety

please ensure that the QuickjsContext corresponding to the passed JSContext is still valid