One minor related thing I noticed --- the comment for v8::Value::ToBigInt seem off:
/** * Perform the equivalent of `BigInt(value)` in JS. */ V8_WARN_UNUSED_RESULT MaybeLocal<BigInt> ToBigInt I think it actually implements the ToBigInt operation (which is what I would expect from the name), not what the BigInt function does --- in particular it rejects numbers, as ToBigInt is written to do, rather than accept some of them as BigInt does. e.g. : -> BigInt(12) <- 12n vs. -> a = new BigInt64Array(); <- BigInt64Array [buffer: ArrayBuffer(0), byteLength: 0, byteOffset: 0, length: 0, Symbol(Symbol.toStringTag): 'BigInt64Array'] -> a.fill(12) <- VM206:1 Uncaught TypeError: Cannot convert 12 to a BigInt at BigInt64Array.fill (<anonymous>) at <anonymous>:1:3 Thanks, Maks On Mon, Jul 31, 2023 at 9:22 AM Maksim Orlovich <morlov...@google.com> wrote: > Thanks! > > On Mon, Jul 31, 2023 at 6:08 AM Leszek Swirski <lesz...@chromium.org> > wrote: > >> ... and landed in >> https://chromium-review.googlesource.com/c/v8/v8/+/4727691 >> >> On Fri, Jul 28, 2023 at 4:03 PM Leszek Swirski <lesz...@chromium.org> >> wrote: >> >>> Hi Maks, >>> >>> We have these on our internal API, but I think they aren't exposed on >>> the public one. I can add them. >>> >>> - Leszek >>> >>> On Thu, Jul 27, 2023 at 5:28 PM Maks Orlovich <morlov...@chromium.org> >>> wrote: >>> >>>> Hi... Is there any way of calling the ToNumeric (or ToPrimitive) spec >>>> operations via the v8 public API (without re-implementing them by hand)? >>>> They seem necessary to implement >>>> https://webidl.spec.whatwg.org/#converted-to-a-numeric-type-or-bigint >>>> >>>> Thanks, >>>> Maks >>>> >>>> -- >>>> -- >>>> v8-dev mailing list >>>> v8-dev@googlegroups.com >>>> http://groups.google.com/group/v8-dev >>>> --- >>>> You received this message because you are subscribed to the Google >>>> Groups "v8-dev" group. >>>> To unsubscribe from this group and stop receiving emails from it, send >>>> an email to v8-dev+unsubscr...@googlegroups.com. >>>> To view this discussion on the web visit >>>> https://groups.google.com/d/msgid/v8-dev/6b974f30-9ae9-4e0f-93a3-ddce2ccadd26n%40googlegroups.com >>>> <https://groups.google.com/d/msgid/v8-dev/6b974f30-9ae9-4e0f-93a3-ddce2ccadd26n%40googlegroups.com?utm_medium=email&utm_source=footer> >>>> . >>>> >>> -- >> -- >> v8-dev mailing list >> v8-dev@googlegroups.com >> http://groups.google.com/group/v8-dev >> --- >> You received this message because you are subscribed to a topic in the >> Google Groups "v8-dev" group. >> To unsubscribe from this topic, visit >> https://groups.google.com/d/topic/v8-dev/h6O3DSIA_jI/unsubscribe. >> To unsubscribe from this group and all its topics, send an email to >> v8-dev+unsubscr...@googlegroups.com. >> To view this discussion on the web visit >> https://groups.google.com/d/msgid/v8-dev/CAGRskv_wLvASyhfZsWFCPmy-SwA8bZtY4JpVDbnHrbSBbFNLqA%40mail.gmail.com >> <https://groups.google.com/d/msgid/v8-dev/CAGRskv_wLvASyhfZsWFCPmy-SwA8bZtY4JpVDbnHrbSBbFNLqA%40mail.gmail.com?utm_medium=email&utm_source=footer> >> . >> > -- -- v8-dev mailing list v8-dev@googlegroups.com http://groups.google.com/group/v8-dev --- You received this message because you are subscribed to the Google Groups "v8-dev" group. To unsubscribe from this group and stop receiving emails from it, send an email to v8-dev+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/v8-dev/CAHRWggTkwA%3DQTSdamOyVXOcV%3DopZ-DUwGiNRoSJLz-Ja2ER-sw%40mail.gmail.com.