Loading...
Searching...
No Matches
v8-script.h
Go to the documentation of this file.
1// Copyright 2021 the V8 project authors. All rights reserved.
2// Use of this source code is governed by a BSD-style license that can be
3// found in the LICENSE file.
4
5#ifndef INCLUDE_V8_SCRIPT_H_
6#define INCLUDE_V8_SCRIPT_H_
7
8#include <stddef.h>
9#include <stdint.h>
10
11#include <memory>
12#include <tuple>
13#include <vector>
14
15#include "v8-callbacks.h" // NOLINT(build/include_directory)
16#include "v8-data.h" // NOLINT(build/include_directory)
17#include "v8-local-handle.h" // NOLINT(build/include_directory)
18#include "v8-maybe.h" // NOLINT(build/include_directory)
19#include "v8-memory-span.h" // NOLINT(build/include_directory)
20#include "v8-message.h" // NOLINT(build/include_directory)
21#include "v8config.h" // NOLINT(build/include_directory)
22
23namespace v8 {
24
25class Function;
26class Message;
27class Object;
28class PrimitiveArray;
29class Script;
30
31namespace internal {
32class BackgroundDeserializeTask;
33struct ScriptStreamingData;
34} // namespace internal
35
43 public:
49
55};
56
61 public:
66
67 int GetId() const;
69
78
83 int GetLineNumber(int code_pos = 0);
84
89 int GetColumnNumber(int code_pos = 0);
90
91 static const int kNoScriptId = 0;
92};
93
98 public:
107};
108
113 public:
114 int GetLineNumber() { return line_number_; }
115 int GetColumnNumber() { return column_number_; }
116
117 Location(int line_number, int column_number)
118 : line_number_(line_number), column_number_(column_number) {}
119
120 private:
121 int line_number_;
122 int column_number_;
123};
124
126 public:
131
136
141 int GetSourceOffset() const;
142
157
158 V8_DEPRECATED("Use GetImportAttributes instead")
159 Local<FixedArray> GetImportAssertions() const {
160 return GetImportAttributes();
161 }
162
163 V8_INLINE static ModuleRequest* Cast(Data* data);
164
165 private:
166 static void CheckCast(Data* obj);
167};
168
172class V8_EXPORT Module : public Data {
173 public:
181 enum Status {
187 kErrored
188 };
189
194
199
204
210
214 int GetIdentityHash() const;
215
217 Local<Context> context, Local<String> specifier,
218 Local<FixedArray> import_attributes, Local<Module> referrer);
220 Local<Context> context, Local<String> specifier,
221 Local<FixedArray> import_attributes, Local<Module> referrer);
222
224 Local<Context> context, size_t module_request_index,
225 Local<Module> referrer);
227 Local<Context> context, size_t module_request_index,
228 Local<Module> referrer);
229
238 Local<Context> context, ResolveModuleCallback module_callback,
239 ResolveSourceCallback source_callback = nullptr);
240
248 Local<Context> context, ResolveModuleByIndexCallback module_callback,
249 ResolveSourceByIndexCallback source_callback = nullptr);
250
262
269
277
283 int ScriptId() const;
284
291 bool IsGraphAsync() const;
292
298 bool HasTopLevelAwait() const;
299
303 bool IsSourceTextModule() const;
304
308 bool IsSyntheticModule() const;
309
310 /*
311 * Callback defined in the embedder. This is responsible for setting
312 * the module's exported values with calls to SetSyntheticModuleExport().
313 * The callback must return a resolved Promise to indicate success (where no
314 * exception was thrown) and return an empy MaybeLocal to indicate falure
315 * (where an exception was thrown).
316 */
319
328 Isolate* isolate, Local<String> module_name,
329 const MemorySpan<const Local<String>>& export_names,
330 SyntheticModuleEvaluationSteps evaluation_steps);
331
340 Isolate* isolate, Local<String> export_name, Local<Value> export_value);
341
349 std::pair<LocalVector<Module>, LocalVector<Message>>
351
352 V8_INLINE static Module* Cast(Data* data);
353
354 private:
355 static void CheckCast(Data* obj);
356};
357
359 public:
363 std::vector<int> GetCompileHints(Isolate* isolate) const;
364};
365
370class V8_EXPORT Script : public Data {
371 public:
376 Local<Context> context, Local<String> source,
377 ScriptOrigin* origin = nullptr);
378
386 Local<Data> host_defined_options);
387
392
398
403 V8_DEPRECATE_SOON("Use GetCompileHintsCollector instead")
404 std::vector<int> GetProducedCompileHints() const;
405
411 Local<CompileHintsCollector> GetCompileHintsCollector() const;
412};
413
415
420 public:
422
431 enum BufferPolicy { BufferNotOwned, BufferOwned };
432
434 : data(nullptr),
435 length(0),
436 rejected(false),
437 buffer_policy(BufferNotOwned) {}
438
439 // If buffer_policy is BufferNotOwned, the caller keeps the ownership of
440 // data and guarantees that it stays alive until the CachedData object is
441 // destroyed. If the policy is BufferOwned, the given data will be deleted
442 // (with delete[]) when the CachedData object is destroyed.
443 CachedData(const uint8_t* data, int length,
444 BufferPolicy buffer_policy = BufferNotOwned);
446
448 // Don't change order/existing values of this enum since it keys into the
449 // `code_cache_reject_reason` histogram. Append-only!
451 kMagicNumberMismatch = 1,
452 kVersionMismatch = 2,
453 kSourceMismatch = 3,
454 kFlagsMismatch = 5,
455 kChecksumMismatch = 6,
456 kInvalidHeader = 7,
457 kLengthMismatch = 8,
458 kReadOnlySnapshotChecksumMismatch = 9,
459
460 // This should always point at the last real enum value.
461 kLast = kReadOnlySnapshotChecksumMismatch
462 };
463
464 // Check if the CachedData can be loaded in the given isolate.
466
467 // TODO(marja): Async compilation; add constructors which take a callback
468 // which will be called when V8 no longer needs the data.
469 const uint8_t* data;
473
474 // Prevent copying.
475 CachedData(const CachedData&) = delete;
476 CachedData& operator=(const CachedData&) = delete;
477 };
478
480 // V8 did not attempt to find this script in its in-memory cache.
481 kNotAttempted,
482
483 // V8 found a previously compiled copy of this script in its in-memory
484 // cache. Any data generated by a streaming compilation or background
485 // deserialization was abandoned.
486 kHit,
487
488 // V8 didn't have any previously compiled data for this script.
489 kMiss,
490
491 // V8 had some previously compiled data for an identical script, but the
492 // data was incomplete.
493 kPartial,
494 };
495
496 // Details about what happened during a compilation.
498 InMemoryCacheResult in_memory_cache_result =
499 InMemoryCacheResult::kNotAttempted;
500
501 static constexpr int64_t kTimeNotMeasured = -1;
502 int64_t foreground_time_in_microseconds = kTimeNotMeasured;
503 int64_t background_time_in_microseconds = kTimeNotMeasured;
504 };
505
509 class Source {
510 public:
511 // Source takes ownership of both CachedData and CodeCacheConsumeTask.
512 // The caller *must* ensure that the cached data is from a trusted source.
513 V8_INLINE Source(Local<String> source_string, const ScriptOrigin& origin,
514 CachedData* cached_data = nullptr,
515 ConsumeCodeCacheTask* consume_cache_task = nullptr);
516 // Source takes ownership of both CachedData and CodeCacheConsumeTask.
517 V8_INLINE explicit Source(
518 Local<String> source_string, CachedData* cached_data = nullptr,
519 ConsumeCodeCacheTask* consume_cache_task = nullptr);
520 V8_INLINE Source(Local<String> source_string, const ScriptOrigin& origin,
521 CompileHintCallback callback, void* callback_data);
522 V8_INLINE ~Source() = default;
523
524 // Ownership of the CachedData or its buffers is *not* transferred to the
525 // caller. The CachedData object is alive as long as the Source object is
526 // alive.
527 V8_INLINE const CachedData* GetCachedData() const;
528
529 V8_INLINE const ScriptOriginOptions& GetResourceOptions() const;
530
531 V8_INLINE const CompilationDetails& GetCompilationDetails() const;
532
533 private:
534 friend class ScriptCompiler;
535
536 Local<String> source_string;
537
538 // Origin information
539 Local<Value> resource_name;
540 int resource_line_offset = -1;
541 int resource_column_offset = -1;
542 ScriptOriginOptions resource_options;
543 Local<Value> source_map_url;
544 Local<Data> host_defined_options;
545
546 // Cached data from previous compilation (if a kConsume*Cache flag is
547 // set), or hold newly generated cache data (kProduce*Cache flags) are
548 // set when calling a compile method.
549 std::unique_ptr<CachedData> cached_data;
550 std::unique_ptr<ConsumeCodeCacheTask> consume_cache_task;
551
552 // For requesting compile hints from the embedder.
553 CompileHintCallback compile_hint_callback = nullptr;
554 void* compile_hint_callback_data = nullptr;
555
556 // V8 writes this data and never reads it. It exists only to be informative
557 // to the embedder.
558 CompilationDetails compilation_details;
559 };
560
566 public:
567 virtual ~ExternalSourceStream() = default;
568
590 virtual size_t GetMoreData(const uint8_t** src) = 0;
591 };
592
600 public:
601 enum Encoding { ONE_BYTE, TWO_BYTE, UTF8, WINDOWS_1252 };
602
603 StreamedSource(std::unique_ptr<ExternalSourceStream> source_stream,
604 Encoding encoding);
606
607 internal::ScriptStreamingData* impl() const { return impl_.get(); }
608
609 // Prevent copying.
612
613 CompilationDetails& compilation_details() { return compilation_details_; }
614
615 private:
616 std::unique_ptr<internal::ScriptStreamingData> impl_;
617
618 // V8 writes this data and never reads it. It exists only to be informative
619 // to the embedder.
620 CompilationDetails compilation_details_;
621 };
622
628 public:
629 void Run();
630
631 private:
632 friend class ScriptCompiler;
633
634 explicit ScriptStreamingTask(internal::ScriptStreamingData* data)
635 : data_(data) {}
636
637 internal::ScriptStreamingData* data_;
638 };
639
646 public:
648
649 void Run();
650
664 void SourceTextAvailable(Isolate* isolate, Local<String> source_text,
665 const ScriptOrigin& origin);
666
673
680
681 private:
682 friend class ScriptCompiler;
683
684 explicit ConsumeCodeCacheTask(
685 std::unique_ptr<internal::BackgroundDeserializeTask> impl);
686
687 std::unique_ptr<internal::BackgroundDeserializeTask> impl_;
688 };
689
691 kNoCompileOptions = 0,
692 kConsumeCodeCache = 1 << 0,
693 kEagerCompile = 1 << 1,
694 kProduceCompileHints = 1 << 2,
695 kConsumeCompileHints = 1 << 3,
696 kFollowCompileHintsMagicComment = 1 << 4,
697 kFollowCompileHintsPerFunctionMagicComment = 1 << 5,
698 };
699
700 static inline bool CompileOptionsIsValid(CompileOptions compile_options) {
701 // kConsumeCodeCache is mutually exclusive with all other flag bits.
702 if ((compile_options & kConsumeCodeCache) &&
703 compile_options != kConsumeCodeCache) {
704 return false;
705 }
706 // kEagerCompile is mutually exclusive with all other flag bits.
707 if ((compile_options & kEagerCompile) && compile_options != kEagerCompile) {
708 return false;
709 }
710 // We don't currently support producing and consuming compile hints at the
711 // same time.
712 constexpr int produce_and_consume = CompileOptions::kProduceCompileHints |
713 CompileOptions::kConsumeCompileHints;
714 if ((compile_options & produce_and_consume) == produce_and_consume) {
715 return false;
716 }
717 return true;
718 }
719
724 kNoCacheNoReason = 0,
740 };
741
757 Isolate* isolate, Source* source,
758 CompileOptions options = kNoCompileOptions,
759 NoCacheReason no_cache_reason = kNoCacheNoReason);
760
773 Local<Context> context, Source* source,
774 CompileOptions options = kNoCompileOptions,
775 NoCacheReason no_cache_reason = kNoCacheNoReason);
776
789 Isolate* isolate, StreamedSource* source,
790 ScriptType type = ScriptType::kClassic,
791 CompileOptions options = kNoCompileOptions,
792 CompileHintCallback compile_hint_callback = nullptr,
793 void* compile_hint_callback_data = nullptr);
794
796 Isolate* isolate, std::unique_ptr<CachedData> source);
798 Isolate* isolate, std::unique_ptr<CachedData> source);
799
808 Local<Context> context, StreamedSource* source,
809 Local<String> full_source_string, const ScriptOrigin& origin);
810
829 static uint32_t CachedDataVersionTag();
830
839 Isolate* isolate, Source* source,
840 CompileOptions options = kNoCompileOptions,
841 NoCacheReason no_cache_reason = kNoCacheNoReason);
842
851 Local<Context> context, StreamedSource* v8_source,
852 Local<String> full_source_string, const ScriptOrigin& origin);
853
865 Local<Context> context, Source* source, size_t arguments_count = 0,
866 Local<String> arguments[] = nullptr, size_t context_extension_count = 0,
867 Local<Object> context_extensions[] = nullptr,
868 CompileOptions options = kNoCompileOptions,
869 NoCacheReason no_cache_reason = kNoCacheNoReason);
870
877
884 Local<UnboundModuleScript> unbound_module_script);
885
893
894 private:
895 static V8_WARN_UNUSED_RESULT MaybeLocal<UnboundScript> CompileUnboundInternal(
896 Isolate* isolate, Source* source, CompileOptions options,
897 NoCacheReason no_cache_reason);
898
899 static V8_WARN_UNUSED_RESULT MaybeLocal<Function> CompileFunctionInternal(
900 Local<Context> context, Source* source, size_t arguments_count,
901 Local<String> arguments[], size_t context_extension_count,
902 Local<Object> context_extensions[], CompileOptions options,
903 NoCacheReason no_cache_reason,
904 Local<ScriptOrModule>* script_or_module_out);
905};
906
907ScriptCompiler::Source::Source(Local<String> string, const ScriptOrigin& origin,
908 CachedData* data,
909 ConsumeCodeCacheTask* consume_cache_task)
910 : source_string(string),
911 resource_name(origin.ResourceName()),
912 resource_line_offset(origin.LineOffset()),
913 resource_column_offset(origin.ColumnOffset()),
914 resource_options(origin.Options()),
915 source_map_url(origin.SourceMapUrl()),
916 host_defined_options(origin.GetHostDefinedOptions()),
917 cached_data(data),
918 consume_cache_task(consume_cache_task) {}
919
921 ConsumeCodeCacheTask* consume_cache_task)
922 : source_string(string),
923 cached_data(data),
924 consume_cache_task(consume_cache_task) {}
925
927 CompileHintCallback callback,
928 void* callback_data)
929 : source_string(string),
930 resource_name(origin.ResourceName()),
931 resource_line_offset(origin.LineOffset()),
932 resource_column_offset(origin.ColumnOffset()),
933 resource_options(origin.Options()),
934 source_map_url(origin.SourceMapUrl()),
935 host_defined_options(origin.GetHostDefinedOptions()),
936 compile_hint_callback(callback),
937 compile_hint_callback_data(callback_data) {}
938
940 const {
941 return cached_data.get();
942}
943
945 return resource_options;
946}
947
950 return compilation_details;
951}
952
954#ifdef V8_ENABLE_CHECKS
955 CheckCast(data);
956#endif
957 return reinterpret_cast<ModuleRequest*>(data);
958}
959
961#ifdef V8_ENABLE_CHECKS
962 CheckCast(data);
963#endif
964 return reinterpret_cast<Module*>(data);
965}
966
967} // namespace v8
968
969#endif // INCLUDE_V8_SCRIPT_H_
Definition: v8-script.h:358
std::vector< int > GetCompileHints(Isolate *isolate) const
Definition: v8-data.h:18
Definition: v8-data.h:77
Definition: v8-isolate.h:290
Definition: v8-local-handle.h:594
Definition: v8-local-handle.h:366
Definition: v8-script.h:112
int GetLineNumber()
Definition: v8-script.h:114
Location(int line_number, int column_number)
Definition: v8-script.h:117
int GetColumnNumber()
Definition: v8-script.h:115
Definition: v8-local-handle.h:734
Definition: v8-maybe.h:39
Definition: v8-memory-span.h:48
Definition: v8-script.h:125
static ModuleRequest * Cast(Data *data)
Definition: v8-script.h:953
Local< FixedArray > GetImportAttributes() const
Local< String > GetSpecifier() const
ModuleImportPhase GetPhase() const
int GetSourceOffset() const
Definition: v8-script.h:172
Location SourceOffsetToLocation(int offset) const
MaybeLocal< Value > Evaluate(Local< Context > context)
Local< Value > GetModuleNamespace()
Maybe< bool > InstantiateModule(Local< Context > context, ResolveModuleByIndexCallback module_callback, ResolveSourceByIndexCallback source_callback=nullptr)
Maybe< bool > SetSyntheticModuleExport(Isolate *isolate, Local< String > export_name, Local< Value > export_value)
Local< FixedArray > GetModuleRequests() const
bool IsGraphAsync() const
bool HasTopLevelAwait() const
int ScriptId() const
Status GetStatus() const
bool IsSyntheticModule() const
Local< Value > GetException() const
std::pair< LocalVector< Module >, LocalVector< Message > > GetStalledTopLevelAwaitMessages(Isolate *isolate)
Status
Definition: v8-script.h:181
@ kInstantiating
Definition: v8-script.h:183
@ kInstantiated
Definition: v8-script.h:184
@ kUninstantiated
Definition: v8-script.h:182
@ kEvaluating
Definition: v8-script.h:185
@ kEvaluated
Definition: v8-script.h:186
int GetIdentityHash() const
static Local< Module > CreateSyntheticModule(Isolate *isolate, Local< String > module_name, const MemorySpan< const Local< String > > &export_names, SyntheticModuleEvaluationSteps evaluation_steps)
Local< UnboundModuleScript > GetUnboundModuleScript()
static Module * Cast(Data *data)
Definition: v8-script.h:960
Maybe< bool > InstantiateModule(Local< Context > context, ResolveModuleCallback module_callback, ResolveSourceCallback source_callback=nullptr)
bool IsSourceTextModule() const
Definition: v8-script.h:645
void SourceTextAvailable(Isolate *isolate, Local< String > source_text, const ScriptOrigin &origin)
Definition: v8-script.h:565
virtual size_t GetMoreData(const uint8_t **src)=0
Definition: v8-script.h:627
Definition: v8-script.h:509
Source(Local< String > source_string, const ScriptOrigin &origin, CachedData *cached_data=nullptr, ConsumeCodeCacheTask *consume_cache_task=nullptr)
Definition: v8-script.h:907
const CompilationDetails & GetCompilationDetails() const
Definition: v8-script.h:949
const CachedData * GetCachedData() const
Definition: v8-script.h:939
const ScriptOriginOptions & GetResourceOptions() const
Definition: v8-script.h:944
Definition: v8-script.h:599
internal::ScriptStreamingData * impl() const
Definition: v8-script.h:607
Encoding
Definition: v8-script.h:601
CompilationDetails & compilation_details()
Definition: v8-script.h:613
StreamedSource & operator=(const StreamedSource &)=delete
StreamedSource(const StreamedSource &)=delete
StreamedSource(std::unique_ptr< ExternalSourceStream > source_stream, Encoding encoding)
Definition: v8-script.h:419
static CachedData * CreateCodeCacheForFunction(Local< Function > function)
static MaybeLocal< Function > CompileFunction(Local< Context > context, Source *source, size_t arguments_count=0, Local< String > arguments[]=nullptr, size_t context_extension_count=0, Local< Object > context_extensions[]=nullptr, CompileOptions options=kNoCompileOptions, NoCacheReason no_cache_reason=kNoCacheNoReason)
InMemoryCacheResult
Definition: v8-script.h:479
static bool CompileOptionsIsValid(CompileOptions compile_options)
Definition: v8-script.h:700
static CachedData * CreateCodeCache(Local< UnboundModuleScript > unbound_module_script)
NoCacheReason
Definition: v8-script.h:723
@ kNoCacheBecausePacScript
Definition: v8-script.h:735
@ kNoCacheBecauseV8Extension
Definition: v8-script.h:733
@ kNoCacheBecauseStreamingSource
Definition: v8-script.h:729
@ kNoCacheBecauseNoResource
Definition: v8-script.h:726
@ kNoCacheBecauseStaticCodeCache
Definition: v8-script.h:739
@ kNoCacheBecauseInspector
Definition: v8-script.h:730
@ kNoCacheBecauseCacheTooCold
Definition: v8-script.h:732
@ kNoCacheBecauseScriptTooSmall
Definition: v8-script.h:731
@ kNoCacheBecauseCachingDisabled
Definition: v8-script.h:725
@ kNoCacheBecauseDeferredProduceCodeCache
Definition: v8-script.h:738
@ kNoCacheBecauseExtensionModule
Definition: v8-script.h:734
@ kNoCacheBecauseInlineScript
Definition: v8-script.h:727
@ kNoCacheBecauseInDocumentWrite
Definition: v8-script.h:736
@ kNoCacheBecauseModule
Definition: v8-script.h:728
@ kNoCacheBecauseResourceWithNoCacheHandler
Definition: v8-script.h:737
static ConsumeCodeCacheTask * StartConsumingCodeCacheOnBackground(Isolate *isolate, std::unique_ptr< CachedData > source)
static CachedData * CreateCodeCache(Local< UnboundScript > unbound_script)
static MaybeLocal< Module > CompileModule(Local< Context > context, StreamedSource *v8_source, Local< String > full_source_string, const ScriptOrigin &origin)
CompileOptions
Definition: v8-script.h:690
static MaybeLocal< Script > Compile(Local< Context > context, StreamedSource *source, Local< String > full_source_string, const ScriptOrigin &origin)
static MaybeLocal< Script > Compile(Local< Context > context, Source *source, CompileOptions options=kNoCompileOptions, NoCacheReason no_cache_reason=kNoCacheNoReason)
static ScriptStreamingTask * StartStreaming(Isolate *isolate, StreamedSource *source, ScriptType type=ScriptType::kClassic, CompileOptions options=kNoCompileOptions, CompileHintCallback compile_hint_callback=nullptr, void *compile_hint_callback_data=nullptr)
static uint32_t CachedDataVersionTag()
static MaybeLocal< UnboundScript > CompileUnboundScript(Isolate *isolate, Source *source, CompileOptions options=kNoCompileOptions, NoCacheReason no_cache_reason=kNoCacheNoReason)
static ConsumeCodeCacheTask * StartConsumingCodeCache(Isolate *isolate, std::unique_ptr< CachedData > source)
static MaybeLocal< Module > CompileModule(Isolate *isolate, Source *source, CompileOptions options=kNoCompileOptions, NoCacheReason no_cache_reason=kNoCacheNoReason)
Definition: v8-script.h:42
Local< Value > GetResourceName()
Local< Data > HostDefinedOptions()
Definition: v8-message.h:29
Definition: v8-message.h:63
Definition: v8-script.h:370
static MaybeLocal< Script > Compile(Local< Context > context, Local< String > source, ScriptOrigin *origin=nullptr)
MaybeLocal< Value > Run(Local< Context > context)
Local< UnboundScript > GetUnboundScript()
MaybeLocal< Value > Run(Local< Context > context, Local< Data > host_defined_options)
Local< Value > GetResourceName()
Definition: v8-script.h:97
Local< Value > GetSourceURL()
Local< Value > GetSourceMappingURL()
Definition: v8-script.h:60
int GetColumnNumber(int code_pos=0)
Local< Value > GetSourceMappingURL()
Local< Value > GetScriptName()
int GetLineNumber(int code_pos=0)
Local< Value > GetSourceURL()
int GetId() const
Local< Script > BindToCurrentContext()
Definition: libplatform.h:15
bool(*)(int, void *) CompileHintCallback
Definition: v8-callbacks.h:417
ModuleImportPhase
Definition: v8-callbacks.h:335
ScriptType
Definition: v8-script.h:414
Definition: v8-script.h:430
BufferPolicy buffer_policy
Definition: v8-script.h:472
const uint8_t * data
Definition: v8-script.h:469
CachedData(const CachedData &)=delete
CompatibilityCheckResult
Definition: v8-script.h:447
bool rejected
Definition: v8-script.h:471
CachedData(const uint8_t *data, int length, BufferPolicy buffer_policy=BufferNotOwned)
BufferPolicy
Definition: v8-script.h:431
@ BufferNotOwned
Definition: v8-script.h:431
CachedData()
Definition: v8-script.h:433
int length
Definition: v8-script.h:470
CompatibilityCheckResult CompatibilityCheck(Isolate *isolate)
CachedData & operator=(const CachedData &)=delete
Definition: v8-script.h:497
#define V8_EXPORT
Definition: v8config.h:855
#define V8_INLINE
Definition: v8config.h:508
#define V8_DEPRECATE_SOON(message)
Definition: v8config.h:622
#define V8_DEPRECATED(message)
Definition: v8config.h:614
#define V8_WARN_UNUSED_RESULT
Definition: v8config.h:679