Commit 46224e75 authored by Camillo Bruni's avatar Camillo Bruni Committed by V8 LUCI CQ

[api] Advance API deprecation for V8 version v10.2

Previously marked V8_DEPRECATED_SOON that are now V8_DEPRECATED:

File                                    Version  Date        Commit
include/v8-initialization.h:208            v9.9  2021-12-15  277fdd1d
include/v8-initialization.h:226            v9.9  2021-12-15  277fdd1d
include/v8-initialization.h:236            v9.9  2021-12-15  277fdd1d
include/v8-initialization.h:250            v9.9  2021-12-15  277fdd1d
include/v8-locker.h:130                   v10.0  2022-01-20  116ca00f
include/v8-message.h:90                    v9.8  2021-11-09  2b3df06b


Previously marked V8_DEPRECATED that are now removed:

File                                    Version  Date        Commit
include/v8-fast-api-calls.h:886            v9.8  2021-11-11  b295d0b0
include/v8-fast-api-calls.h:893            v9.8  2021-11-11  b295d0b0
include/v8-fast-api-calls.h:902            v9.8  2021-11-11  b295d0b0
include/v8-initialization.h:186           v10.0  2022-01-26  36707481
include/v8-isolate.h:639                  v10.0  2022-01-26  36707481
include/v8-locker.h:132                    v9.8  2021-11-11  b295d0b0
include/v8-object.h:597                    v9.9  2022-01-18  0a61fa51
include/v8-object.h:609                    v9.8  2021-11-11  b295d0b0
include/v8-script.h:50                    v10.0  2022-01-26  36707481
include/v8-script.h:653                   v10.0  2022-01-18  9cf4f131


Output generated by ./tools/release/list_deprecated.py

Bug: v8:11165, chromium:1166077
Change-Id: Ie0d435f7a10f362ed714bdc30ad899ee9c485cb4
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3571804
Commit-Queue: Toon Verwaest <verwaest@chromium.org>
Auto-Submit: Camillo Bruni <cbruni@chromium.org>
Reviewed-by: 's avatarToon Verwaest <verwaest@chromium.org>
Reviewed-by: 's avatarMichael Lippautz <mlippautz@chromium.org>
Cr-Commit-Position: refs/heads/main@{#80337}
parent e3e8ea5d
......@@ -881,31 +881,6 @@ static constexpr CTypeInfo kTypeInfoFloat64 =
* to the requested destination type, is considered unsupported. The operation
* returns true on success. `type_info` will be used for conversions.
*/
template <const CTypeInfo* type_info, typename T>
V8_DEPRECATED(
"Use TryToCopyAndConvertArrayToCppBuffer<CTypeInfo::Identifier, T>()")
bool V8_EXPORT V8_WARN_UNUSED_RESULT
TryCopyAndConvertArrayToCppBuffer(Local<Array> src, T* dst,
uint32_t max_length);
template <>
V8_DEPRECATED(
"Use TryToCopyAndConvertArrayToCppBuffer<CTypeInfo::Identifier, T>()")
inline bool V8_WARN_UNUSED_RESULT
TryCopyAndConvertArrayToCppBuffer<&kTypeInfoInt32, int32_t>(
Local<Array> src, int32_t* dst, uint32_t max_length) {
return false;
}
template <>
V8_DEPRECATED(
"Use TryToCopyAndConvertArrayToCppBuffer<CTypeInfo::Identifier, T>()")
inline bool V8_WARN_UNUSED_RESULT
TryCopyAndConvertArrayToCppBuffer<&kTypeInfoFloat64, double>(
Local<Array> src, double* dst, uint32_t max_length) {
return false;
}
template <CTypeInfo::Identifier type_info_id, typename T>
bool V8_EXPORT V8_WARN_UNUSED_RESULT TryToCopyAndConvertArrayToCppBuffer(
Local<Array> src, T* dst, uint32_t max_length);
......
......@@ -184,8 +184,6 @@ class V8_EXPORT V8 {
* V8 was disposed.
*/
static void DisposePlatform();
V8_DEPRECATED("Use DisposePlatform()")
static void ShutdownPlatform() { DisposePlatform(); }
#ifdef V8_SANDBOX
//
......@@ -206,7 +204,7 @@ class V8_EXPORT V8 {
* as part of V8::Initialize, at which point this function should be removed.
*/
static bool InitializeSandbox();
V8_DEPRECATE_SOON("Use InitializeSandbox()")
V8_DEPRECATED("Use InitializeSandbox()")
static bool InitializeVirtualMemoryCage() { return InitializeSandbox(); }
/**
......@@ -224,7 +222,7 @@ class V8_EXPORT V8 {
* This function must only be called after initializing the sandbox.
*/
static VirtualAddressSpace* GetSandboxAddressSpace();
V8_DEPRECATE_SOON("Use GetSandboxAddressSpace()")
V8_DEPRECATED("Use GetSandboxAddressSpace()")
static PageAllocator* GetVirtualMemoryCagePageAllocator();
/**
......@@ -234,7 +232,7 @@ class V8_EXPORT V8 {
* this returns zero.
*/
static size_t GetSandboxSizeInBytes();
V8_DEPRECATE_SOON("Use GetSandboxSizeInBytes()")
V8_DEPRECATED("Use GetSandboxSizeInBytes()")
static size_t GetVirtualMemoryCageSizeInBytes() {
return GetSandboxSizeInBytes();
}
......@@ -248,7 +246,7 @@ class V8_EXPORT V8 {
* insecure sandbox is being used, in which case it will return false.
*/
static bool IsSandboxConfiguredSecurely();
V8_DEPRECATE_SOON("Use IsSandboxConfiguredSecurely()")
V8_DEPRECATED("Use IsSandboxConfiguredSecurely()")
static bool IsUsingSecureVirtualMemoryCage() {
return IsSandboxConfiguredSecurely();
}
......
......@@ -638,9 +638,6 @@ class V8_EXPORT Isolate {
* This specifies the callback called by the upcoming dynamic
* import() language feature to load modules.
*/
V8_DEPRECATED("Use HostImportModuleDynamicallyCallback")
void SetHostImportModuleDynamicallyCallback(
HostImportModuleDynamicallyWithImportAssertionsCallback callback);
void SetHostImportModuleDynamicallyCallback(
HostImportModuleDynamicallyCallback callback);
......
......@@ -127,10 +127,8 @@ class V8_EXPORT Locker {
* The current implementation is quite confusing and leads to unexpected
* results if anybody uses v8::Locker in the current process.
*/
V8_DEPRECATE_SOON("This method will be removed.")
V8_DEPRECATED("This method will be removed.")
static bool WasEverUsed();
V8_DEPRECATED("Use WasEverUsed instead")
static bool IsActive();
// Disallow copying and assigning.
Locker(const Locker&) = delete;
......
......@@ -87,7 +87,7 @@ class V8_EXPORT ScriptOrigin {
V8_INLINE int ColumnOffset() const;
V8_INLINE int ScriptId() const;
V8_INLINE Local<Value> SourceMapUrl() const;
V8_DEPRECATE_SOON("Use GetHostDefinedOptions")
V8_DEPRECATED("Use GetHostDefinedOptions")
Local<PrimitiveArray> HostDefinedOptions() const;
V8_INLINE Local<Data> GetHostDefinedOptions() const;
V8_INLINE ScriptOriginOptions Options() const { return options_; }
......
......@@ -594,8 +594,6 @@ class V8_EXPORT Object : public Value {
/**
* Returns the context in which the object was created.
*/
V8_DEPRECATED("Use MaybeLocal<Context> GetCreationContext()")
Local<Context> CreationContext();
MaybeLocal<Context> GetCreationContext();
/**
......@@ -604,10 +602,6 @@ class V8_EXPORT Object : public Value {
Local<Context> GetCreationContextChecked();
/** Same as above, but works for Persistents */
V8_DEPRECATED(
"Use MaybeLocal<Context> GetCreationContext(const "
"PersistentBase<Object>& object)")
static Local<Context> CreationContext(const PersistentBase<Object>& object);
V8_INLINE static MaybeLocal<Context> GetCreationContext(
const PersistentBase<Object>& object) {
return object.val_->GetCreationContext();
......
......@@ -5087,28 +5087,6 @@ Local<v8::Object> v8::Object::Clone() {
return Utils::ToLocal(result);
}
namespace {
Local<v8::Context> CreationContextImpl(i::Handle<i::JSReceiver> self) {
i::Handle<i::Context> context;
if (self->GetCreationContext().ToHandle(&context)) {
return Utils::ToLocal(context);
}
return Local<v8::Context>();
}
} // namespace
Local<v8::Context> v8::Object::CreationContext() {
auto self = Utils::OpenHandle(this);
return CreationContextImpl(self);
}
Local<v8::Context> v8::Object::CreationContext(
const PersistentBase<Object>& object) {
auto self = Utils::OpenHandle(object.val_);
return CreationContextImpl(self);
}
MaybeLocal<v8::Context> v8::Object::GetCreationContext() {
auto self = Utils::OpenHandle(this);
i::Handle<i::Context> context;
......@@ -8765,12 +8743,6 @@ void Isolate::SetAbortOnUncaughtExceptionCallback(
i_isolate->SetAbortOnUncaughtExceptionCallback(callback);
}
void Isolate::SetHostImportModuleDynamicallyCallback(
HostImportModuleDynamicallyWithImportAssertionsCallback callback) {
i::Isolate* i_isolate = reinterpret_cast<i::Isolate*>(this);
i_isolate->SetHostImportModuleDynamicallyCallback(callback);
}
void Isolate::SetHostImportModuleDynamicallyCallback(
HostImportModuleDynamicallyCallback callback) {
i::Isolate* i_isolate = reinterpret_cast<i::Isolate*>(this);
......
......@@ -56,9 +56,6 @@ bool Locker::IsLocked(v8::Isolate* isolate) {
return i_isolate->thread_manager()->IsLockedByCurrentThread();
}
// static
bool Locker::IsActive() { return WasEverUsed(); }
// static
bool Locker::WasEverUsed() {
return base::Relaxed_Load(&g_locker_was_ever_used_) != 0;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment