From 3a66cfd1b443867cbecc80f1455e1b8f2f8c6d12 Mon Sep 17 00:00:00 2001 From: Igor Sheludko Date: Fri, 26 Apr 2024 16:28:49 +0200 Subject: [PATCH] Don't use soon-to-be-deprecated V8 Api (#182) Namely v8::FunctionCallbackInfo::Holder(), one should use This() method instead. See https://crrev.com/c/5444829 for details. --- src/README.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/README.md b/src/README.md index 01d6d5fd4bcd89..5f1f063fe1787d 100644 --- a/src/README.md +++ b/src/README.md @@ -826,9 +826,9 @@ class from C++. The JavaScript object can be accessed as a `v8::Local` by using `self->object()`, given a `BaseObject` named `self`. -Accessing a `BaseObject` from a `v8::Local` (frequently that is -`args.This()` in a [binding function][]) can be done using -the `Unwrap(obj)` function, where `T` is a subclass of `BaseObject`. +Accessing a `BaseObject` from a `v8::Local` (that is `args.This()` +in a [binding function][]) can be done using the `Unwrap(obj)` function, +where `T` is a subclass of `BaseObject`. A helper for this is the `ASSIGN_OR_RETURN_UNWRAP` macro that returns from the current function if unwrapping fails (typically that means that the `BaseObject` has been deleted earlier).