| Index: runtime/vm/object.cc
|
| diff --git a/runtime/vm/object.cc b/runtime/vm/object.cc
|
| index 380565bc664165f06ac37d35032b30488288b1c4..2f9857f2fda703a5d1a5529da81ac7fedd9e172f 100644
|
| --- a/runtime/vm/object.cc
|
| +++ b/runtime/vm/object.cc
|
| @@ -40,6 +40,7 @@
|
| #include "vm/scopes.h"
|
| #include "vm/stack_frame.h"
|
| #include "vm/symbols.h"
|
| +#include "vm/tags.h"
|
| #include "vm/timer.h"
|
| #include "vm/unicode.h"
|
|
|
| @@ -7364,17 +7365,19 @@ void Script::set_tokens(const TokenStream& value) const {
|
|
|
|
|
| void Script::Tokenize(const String& private_key) const {
|
| - const TokenStream& tkns = TokenStream::Handle(tokens());
|
| + Isolate* isolate = Isolate::Current();
|
| + const TokenStream& tkns = TokenStream::Handle(isolate, tokens());
|
| if (!tkns.IsNull()) {
|
| // Already tokenized.
|
| return;
|
| }
|
| -
|
| // Get the source, scan and allocate the token stream.
|
| + VMTagScope tagScope(isolate, VMTag::kCompileTagId);
|
| TimerScope timer(FLAG_compiler_stats, &CompilerStats::scanner_timer);
|
| - const String& src = String::Handle(Source());
|
| + const String& src = String::Handle(isolate, Source());
|
| Scanner scanner(src, private_key);
|
| - set_tokens(TokenStream::Handle(TokenStream::New(scanner.GetStream(),
|
| + set_tokens(TokenStream::Handle(isolate,
|
| + TokenStream::New(scanner.GetStream(),
|
| private_key)));
|
| if (FLAG_compiler_stats) {
|
| CompilerStats::src_length += src.Length();
|
|
|