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 /*
68 * A unique id.
69 */
70 int ScriptId() const;
71 V8_DEPRECATE_SOON("Use ScriptId")
72 int GetId() const;
73
74 Local<Value> GetScriptName();
75
79 Local<Value> GetSourceURL();
83 Local<Value> GetSourceMappingURL();
84
89 int GetLineNumber(int code_pos = 0);
90
95 int GetColumnNumber(int code_pos = 0);
96
97 static const int kNoScriptId = 0;
98};
99
104 public:
113
114 /*
115 * A unique id.
116 */
117 int ScriptId() const;
118
119 static const int kNoScriptId = 0;
120};
121
122static_assert(UnboundModuleScript::kNoScriptId == UnboundScript::kNoScriptId);
123
128 public:
129 int GetLineNumber() { return line_number_; }
130 int GetColumnNumber() { return column_number_; }
131
132 Location(int line_number, int column_number)
133 : line_number_(line_number), column_number_(column_number) {}
134
135 private:
136 int line_number_;
137 int column_number_;
138};
139
141 public:
146
151
156 int GetSourceOffset() const;
157
172
173 V8_DEPRECATED("Use GetImportAttributes instead")
174 Local<FixedArray> GetImportAssertions() const {
175 return GetImportAttributes();
176 }
177
178 V8_INLINE static ModuleRequest* Cast(Data* data);
179
180 private:
181 static void CheckCast(Data* obj);
182};
183
187class V8_EXPORT Module : public Data {
188 public:
196 enum Status {
202 kErrored
203 };
204
211
216
221
226
232
236 int GetIdentityHash() const;
237
239 Local<Context> context, Local<String> specifier,
240 Local<FixedArray> import_attributes, Local<Module> referrer);
242 Local<Context> context, Local<String> specifier,
243 Local<FixedArray> import_attributes, Local<Module> referrer);
244
246 Local<Context> context, size_t module_request_index,
247 Local<Module> referrer);
249 Local<Context> context, size_t module_request_index,
250 Local<Module> referrer);
251
260 Local<Context> context, ResolveModuleCallback module_callback,
261 ResolveSourceCallback source_callback = nullptr);
262
270 Local<Context> context, ResolveModuleByIndexCallback module_callback,
271 ResolveSourceByIndexCallback source_callback = nullptr);
272
284
296 Local<Context> context);
297
305
313
319 int ScriptId() const;
320
327 bool IsGraphAsync() const;
328
334 bool HasTopLevelAwait() const;
335
339 bool IsSourceTextModule() const;
340
344 bool IsSyntheticModule() const;
345
346 /*
347 * Callback defined in the embedder. This is responsible for setting
348 * the module's exported values with calls to SetSyntheticModuleExport().
349 * The callback must return a resolved Promise to indicate success (where no
350 * exception was thrown) and return an empy MaybeLocal to indicate falure
351 * (where an exception was thrown).
352 */
355
364 Isolate* isolate, Local<String> module_name,
365 const MemorySpan<const Local<String>>& export_names,
366 SyntheticModuleEvaluationSteps evaluation_steps);
367
376 Isolate* isolate, Local<String> export_name, Local<Value> export_value);
377
385 std::pair<LocalVector<Module>, LocalVector<Message>>
387
388 V8_INLINE static Module* Cast(Data* data);
389
390 private:
391 static void CheckCast(Data* obj);
392};
393
395 public:
399 std::vector<int> GetCompileHints(Isolate* isolate) const;
400};
401
406class V8_EXPORT Script : public Data {
407 public:
412 Local<Context> context, Local<String> source,
413 ScriptOrigin* origin = nullptr);
414
422 Local<Data> host_defined_options);
423
428
432 int ScriptId() const;
433
439
444 V8_DEPRECATE_SOON("Use GetCompileHintsCollector instead")
445 std::vector<int> GetProducedCompileHints() const;
446
452 Local<CompileHintsCollector> GetCompileHintsCollector() const;
453};
454
456
461 public:
463
472 enum BufferPolicy { BufferNotOwned, BufferOwned };
473
475 : data(nullptr),
476 length(0),
477 rejected(false),
478 buffer_policy(BufferNotOwned) {}
479
480 // If buffer_policy is BufferNotOwned, the caller keeps the ownership of
481 // data and guarantees that it stays alive until the CachedData object is
482 // destroyed. If the policy is BufferOwned, the given data will be deleted
483 // (with delete[]) when the CachedData object is destroyed.
484 CachedData(const uint8_t* data, int length,
485 BufferPolicy buffer_policy = BufferNotOwned);
487
489 // Don't change order/existing values of this enum since it keys into the
490 // `code_cache_reject_reason` histogram. Append-only!
492 kMagicNumberMismatch = 1,
493 kVersionMismatch = 2,
494 kSourceMismatch = 3,
495 kFlagsMismatch = 5,
496 kChecksumMismatch = 6,
497 kInvalidHeader = 7,
498 kLengthMismatch = 8,
499 kReadOnlySnapshotChecksumMismatch = 9,
500
501 // This should always point at the last real enum value.
502 kLast = kReadOnlySnapshotChecksumMismatch
503 };
504
505 // Check if the CachedData can be loaded in the given isolate.
507
508 // TODO(marja): Async compilation; add constructors which take a callback
509 // which will be called when V8 no longer needs the data.
510 const uint8_t* data;
514
515 // Prevent copying.
516 CachedData(const CachedData&) = delete;
517 CachedData& operator=(const CachedData&) = delete;
518 };
519
521 // V8 did not attempt to find this script in its in-memory cache.
522 kNotAttempted,
523
524 // V8 found a previously compiled copy of this script in its in-memory
525 // cache. Any data generated by a streaming compilation or background
526 // deserialization was abandoned.
527 kHit,
528
529 // V8 didn't have any previously compiled data for this script.
530 kMiss,
531
532 // V8 had some previously compiled data for an identical script, but the
533 // data was incomplete.
534 kPartial,
535 };
536
537 // Details about what happened during a compilation.
539 InMemoryCacheResult in_memory_cache_result =
540 InMemoryCacheResult::kNotAttempted;
541
542 static constexpr int64_t kTimeNotMeasured = -1;
543 int64_t foreground_time_in_microseconds = kTimeNotMeasured;
544 int64_t background_time_in_microseconds = kTimeNotMeasured;
545 };
546
550 class Source {
551 public:
552 // Source takes ownership of both CachedData and CodeCacheConsumeTask.
553 // The caller *must* ensure that the cached data is from a trusted source.
554 V8_INLINE Source(Local<String> source_string, const ScriptOrigin& origin,
555 CachedData* cached_data = nullptr,
556 ConsumeCodeCacheTask* consume_cache_task = nullptr);
557 // Source takes ownership of both CachedData and CodeCacheConsumeTask.
558 V8_INLINE explicit Source(
559 Local<String> source_string, CachedData* cached_data = nullptr,
560 ConsumeCodeCacheTask* consume_cache_task = nullptr);
561 V8_INLINE Source(Local<String> source_string, const ScriptOrigin& origin,
562 CompileHintCallback callback, void* callback_data);
563 V8_INLINE ~Source() = default;
564
565 // Ownership of the CachedData or its buffers is *not* transferred to the
566 // caller. The CachedData object is alive as long as the Source object is
567 // alive.
568 V8_INLINE const CachedData* GetCachedData() const;
569
570 V8_INLINE const ScriptOriginOptions& GetResourceOptions() const;
571
572 V8_INLINE const CompilationDetails& GetCompilationDetails() const;
573
574 private:
575 friend class ScriptCompiler;
576
577 Local<String> source_string;
578
579 // Origin information
580 Local<Value> resource_name;
581 int resource_line_offset = -1;
582 int resource_column_offset = -1;
583 ScriptOriginOptions resource_options;
584 Local<Value> source_map_url;
585 Local<Data> host_defined_options;
586
587 // Cached data from previous compilation (if a kConsume*Cache flag is
588 // set), or hold newly generated cache data (kProduce*Cache flags) are
589 // set when calling a compile method.
590 std::unique_ptr<CachedData> cached_data;
591 std::unique_ptr<ConsumeCodeCacheTask> consume_cache_task;
592
593 // For requesting compile hints from the embedder.
594 CompileHintCallback compile_hint_callback = nullptr;
595 void* compile_hint_callback_data = nullptr;
596
597 // V8 writes this data and never reads it. It exists only to be informative
598 // to the embedder.
599 CompilationDetails compilation_details;
600 };
601
607 public:
608 virtual ~ExternalSourceStream() = default;
609
631 virtual size_t GetMoreData(const uint8_t** src) = 0;
632 };
633
641 public:
642 enum Encoding { ONE_BYTE, TWO_BYTE, UTF8, WINDOWS_1252 };
643
644 StreamedSource(std::unique_ptr<ExternalSourceStream> source_stream,
645 Encoding encoding);
647
648 internal::ScriptStreamingData* impl() const { return impl_.get(); }
649
650 // Prevent copying.
653
654 CompilationDetails& compilation_details() { return compilation_details_; }
655
656 private:
657 std::unique_ptr<internal::ScriptStreamingData> impl_;
658
659 // V8 writes this data and never reads it. It exists only to be informative
660 // to the embedder.
661 CompilationDetails compilation_details_;
662 };
663
669 public:
670 void Run();
671
672 private:
673 friend class ScriptCompiler;
674
675 explicit ScriptStreamingTask(internal::ScriptStreamingData* data)
676 : data_(data) {}
677
678 internal::ScriptStreamingData* data_;
679 };
680
687 public:
689
690 void Run();
691
705 void SourceTextAvailable(Isolate* isolate, Local<String> source_text,
706 const ScriptOrigin& origin);
707
714
721
722 private:
723 friend class ScriptCompiler;
724
725 explicit ConsumeCodeCacheTask(
726 std::unique_ptr<internal::BackgroundDeserializeTask> impl);
727
728 std::unique_ptr<internal::BackgroundDeserializeTask> impl_;
729 };
730
732 kNoCompileOptions = 0,
733 kConsumeCodeCache = 1 << 0,
734 kEagerCompile = 1 << 1,
735 kProduceCompileHints = 1 << 2,
736 kConsumeCompileHints = 1 << 3,
737 kFollowCompileHintsMagicComment = 1 << 4,
738 kFollowCompileHintsPerFunctionMagicComment = 1 << 5,
739 };
740
741 static inline bool CompileOptionsIsValid(CompileOptions compile_options) {
742 // kConsumeCodeCache is mutually exclusive with all other flag bits.
743 if ((compile_options & kConsumeCodeCache) &&
744 compile_options != kConsumeCodeCache) {
745 return false;
746 }
747 // kEagerCompile is mutually exclusive with all other flag bits.
748 if ((compile_options & kEagerCompile) && compile_options != kEagerCompile) {
749 return false;
750 }
751 // We don't currently support producing and consuming compile hints at the
752 // same time.
753 constexpr int produce_and_consume = CompileOptions::kProduceCompileHints |
754 CompileOptions::kConsumeCompileHints;
755 if ((compile_options & produce_and_consume) == produce_and_consume) {
756 return false;
757 }
758 return true;
759 }
760
765 kNoCacheNoReason = 0,
781 };
782
798 Isolate* isolate, Source* source,
799 CompileOptions options = kNoCompileOptions,
800 NoCacheReason no_cache_reason = kNoCacheNoReason);
801
814 Local<Context> context, Source* source,
815 CompileOptions options = kNoCompileOptions,
816 NoCacheReason no_cache_reason = kNoCacheNoReason);
817
830 Isolate* isolate, StreamedSource* source,
831 ScriptType type = ScriptType::kClassic,
832 CompileOptions options = kNoCompileOptions,
833 CompileHintCallback compile_hint_callback = nullptr,
834 void* compile_hint_callback_data = nullptr);
835
837 Isolate* isolate, std::unique_ptr<CachedData> source);
839 Isolate* isolate, std::unique_ptr<CachedData> source);
840
849 Local<Context> context, StreamedSource* source,
850 Local<String> full_source_string, const ScriptOrigin& origin);
851
870 static uint32_t CachedDataVersionTag();
871
880 Isolate* isolate, Source* source,
881 CompileOptions options = kNoCompileOptions,
882 NoCacheReason no_cache_reason = kNoCacheNoReason);
883
892 Local<Context> context, StreamedSource* v8_source,
893 Local<String> full_source_string, const ScriptOrigin& origin);
894
906 Local<Context> context, Source* source, size_t arguments_count = 0,
907 Local<String> arguments[] = nullptr, size_t context_extension_count = 0,
908 Local<Object> context_extensions[] = nullptr,
909 CompileOptions options = kNoCompileOptions,
910 NoCacheReason no_cache_reason = kNoCacheNoReason);
911
918
925 Local<UnboundModuleScript> unbound_module_script);
926
934
935 private:
936 static V8_WARN_UNUSED_RESULT MaybeLocal<UnboundScript> CompileUnboundInternal(
937 Isolate* isolate, Source* source, CompileOptions options,
938 NoCacheReason no_cache_reason);
939
940 static V8_WARN_UNUSED_RESULT MaybeLocal<Function> CompileFunctionInternal(
941 Local<Context> context, Source* source, size_t arguments_count,
942 Local<String> arguments[], size_t context_extension_count,
943 Local<Object> context_extensions[], CompileOptions options,
944 NoCacheReason no_cache_reason,
945 Local<ScriptOrModule>* script_or_module_out);
946};
947
948ScriptCompiler::Source::Source(Local<String> string, const ScriptOrigin& origin,
949 CachedData* data,
950 ConsumeCodeCacheTask* consume_cache_task)
951 : source_string(string),
952 resource_name(origin.ResourceName()),
953 resource_line_offset(origin.LineOffset()),
954 resource_column_offset(origin.ColumnOffset()),
955 resource_options(origin.Options()),
956 source_map_url(origin.SourceMapUrl()),
957 host_defined_options(origin.GetHostDefinedOptions()),
958 cached_data(data),
959 consume_cache_task(consume_cache_task) {}
960
962 ConsumeCodeCacheTask* consume_cache_task)
963 : source_string(string),
964 cached_data(data),
965 consume_cache_task(consume_cache_task) {}
966
968 CompileHintCallback callback,
969 void* callback_data)
970 : source_string(string),
971 resource_name(origin.ResourceName()),
972 resource_line_offset(origin.LineOffset()),
973 resource_column_offset(origin.ColumnOffset()),
974 resource_options(origin.Options()),
975 source_map_url(origin.SourceMapUrl()),
976 host_defined_options(origin.GetHostDefinedOptions()),
977 compile_hint_callback(callback),
978 compile_hint_callback_data(callback_data) {}
979
981 const {
982 return cached_data.get();
983}
984
986 return resource_options;
987}
988
991 return compilation_details;
992}
993
995#ifdef V8_ENABLE_CHECKS
996 CheckCast(data);
997#endif
998 return reinterpret_cast<ModuleRequest*>(data);
999}
1000
1002#ifdef V8_ENABLE_CHECKS
1003 CheckCast(data);
1004#endif
1005 return reinterpret_cast<Module*>(data);
1006}
1007
1008} // namespace v8
1009
1010#endif // INCLUDE_V8_SCRIPT_H_
Definition: v8-script.h:394
std::vector< int > GetCompileHints(Isolate *isolate) const
Definition: v8-data.h:18
Definition: v8-data.h:77
Definition: v8-isolate.h:291
Definition: v8-local-handle.h:594
Definition: v8-local-handle.h:366
Definition: v8-script.h:127
int GetLineNumber()
Definition: v8-script.h:129
Location(int line_number, int column_number)
Definition: v8-script.h:132
int GetColumnNumber()
Definition: v8-script.h:130
Definition: v8-local-handle.h:734
Definition: v8-maybe.h:39
Definition: v8-memory-span.h:48
Definition: v8-script.h:140
static ModuleRequest * Cast(Data *data)
Definition: v8-script.h:994
Local< FixedArray > GetImportAttributes() const
Local< String > GetSpecifier() const
ModuleImportPhase GetPhase() const
int GetSourceOffset() const
Definition: v8-script.h:187
Local< Value > GetResourceName() const
Location SourceOffsetToLocation(int offset) const
MaybeLocal< Value > Evaluate(Local< Context > context)
MaybeLocal< Value > EvaluateForImportDefer(Local< Context > context)
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:196
@ kInstantiating
Definition: v8-script.h:198
@ kInstantiated
Definition: v8-script.h:199
@ kUninstantiated
Definition: v8-script.h:197
@ kEvaluating
Definition: v8-script.h:200
@ kEvaluated
Definition: v8-script.h:201
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()
Local< Value > GetModuleNamespace(v8::ModuleImportPhase phase=v8::ModuleImportPhase::kEvaluation)
static Module * Cast(Data *data)
Definition: v8-script.h:1001
Maybe< bool > InstantiateModule(Local< Context > context, ResolveModuleCallback module_callback, ResolveSourceCallback source_callback=nullptr)
bool IsSourceTextModule() const
Definition: v8-script.h:686
void SourceTextAvailable(Isolate *isolate, Local< String > source_text, const ScriptOrigin &origin)
Definition: v8-script.h:606
virtual size_t GetMoreData(const uint8_t **src)=0
Definition: v8-script.h:668
Definition: v8-script.h:550
Source(Local< String > source_string, const ScriptOrigin &origin, CachedData *cached_data=nullptr, ConsumeCodeCacheTask *consume_cache_task=nullptr)
Definition: v8-script.h:948
const CompilationDetails & GetCompilationDetails() const
Definition: v8-script.h:990
const CachedData * GetCachedData() const
Definition: v8-script.h:980
const ScriptOriginOptions & GetResourceOptions() const
Definition: v8-script.h:985
Definition: v8-script.h:640
internal::ScriptStreamingData * impl() const
Definition: v8-script.h:648
Encoding
Definition: v8-script.h:642
CompilationDetails & compilation_details()
Definition: v8-script.h:654
StreamedSource & operator=(const StreamedSource &)=delete
StreamedSource(const StreamedSource &)=delete
StreamedSource(std::unique_ptr< ExternalSourceStream > source_stream, Encoding encoding)
Definition: v8-script.h:460
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:520
static bool CompileOptionsIsValid(CompileOptions compile_options)
Definition: v8-script.h:741
static CachedData * CreateCodeCache(Local< UnboundModuleScript > unbound_module_script)
NoCacheReason
Definition: v8-script.h:764
@ kNoCacheBecausePacScript
Definition: v8-script.h:776
@ kNoCacheBecauseV8Extension
Definition: v8-script.h:774
@ kNoCacheBecauseStreamingSource
Definition: v8-script.h:770
@ kNoCacheBecauseNoResource
Definition: v8-script.h:767
@ kNoCacheBecauseStaticCodeCache
Definition: v8-script.h:780
@ kNoCacheBecauseInspector
Definition: v8-script.h:771
@ kNoCacheBecauseCacheTooCold
Definition: v8-script.h:773
@ kNoCacheBecauseScriptTooSmall
Definition: v8-script.h:772
@ kNoCacheBecauseCachingDisabled
Definition: v8-script.h:766
@ kNoCacheBecauseDeferredProduceCodeCache
Definition: v8-script.h:779
@ kNoCacheBecauseExtensionModule
Definition: v8-script.h:775
@ kNoCacheBecauseInlineScript
Definition: v8-script.h:768
@ kNoCacheBecauseInDocumentWrite
Definition: v8-script.h:777
@ kNoCacheBecauseModule
Definition: v8-script.h:769
@ kNoCacheBecauseResourceWithNoCacheHandler
Definition: v8-script.h:778
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:731
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:406
static MaybeLocal< Script > Compile(Local< Context > context, Local< String > source, ScriptOrigin *origin=nullptr)
MaybeLocal< Value > Run(Local< Context > context)
Local< UnboundScript > GetUnboundScript()
int ScriptId() const
MaybeLocal< Value > Run(Local< Context > context, Local< Data > host_defined_options)
Local< Value > GetResourceName()
Definition: v8-script.h:103
Local< Value > GetSourceURL()
Local< Value > GetSourceMappingURL()
Definition: v8-script.h:60
int ScriptId() const
Local< Script > BindToCurrentContext()
Definition: v8-value.h:32
Definition: libplatform.h:15
bool(*)(int, void *) CompileHintCallback
Definition: v8-callbacks.h:431
ModuleImportPhase
Definition: v8-callbacks.h:348
ScriptType
Definition: v8-script.h:455
Definition: v8-script.h:471
BufferPolicy buffer_policy
Definition: v8-script.h:513
const uint8_t * data
Definition: v8-script.h:510
CachedData(const CachedData &)=delete
CompatibilityCheckResult
Definition: v8-script.h:488
bool rejected
Definition: v8-script.h:512
CachedData(const uint8_t *data, int length, BufferPolicy buffer_policy=BufferNotOwned)
BufferPolicy
Definition: v8-script.h:472
@ BufferNotOwned
Definition: v8-script.h:472
CachedData()
Definition: v8-script.h:474
int length
Definition: v8-script.h:511
CompatibilityCheckResult CompatibilityCheck(Isolate *isolate)
CachedData & operator=(const CachedData &)=delete
Definition: v8-script.h:538
#define V8_EXPORT
Definition: v8config.h:854
#define V8_INLINE
Definition: v8config.h:508
#define V8_DEPRECATE_SOON(message)
Definition: v8config.h:621
#define V8_DEPRECATED(message)
Definition: v8config.h:613
#define V8_WARN_UNUSED_RESULT
Definition: v8config.h:678