Index: test/cctest/test-parsing.cc |
diff --git a/test/cctest/test-parsing.cc b/test/cctest/test-parsing.cc |
index 7d38aab1f3db84d0a467e128259c8a24554ee359..4093bdd25920adff69f44ec2d8da819a2ab99d2f 100644 |
--- a/test/cctest/test-parsing.cc |
+++ b/test/cctest/test-parsing.cc |
@@ -819,9 +819,10 @@ void TestScanRegExp(const char* re_source, const char* expected) { |
i::Zone zone(CcTest::i_isolate()->allocator()); |
i::AstValueFactory ast_value_factory(&zone, |
CcTest::i_isolate()->heap()->HashSeed()); |
+ const i::AstRawString* current_symbol = |
+ scanner.CurrentSymbol(&ast_value_factory); |
ast_value_factory.Internalize(CcTest::i_isolate()); |
- i::Handle<i::String> val = |
- scanner.CurrentSymbol(&ast_value_factory)->string(); |
+ i::Handle<i::String> val = current_symbol->string(); |
i::DisallowHeapAllocation no_alloc; |
i::String::FlatContent content = val->GetFlatContent(); |
CHECK(content.IsOneByte()); |
@@ -3397,8 +3398,8 @@ TEST(SerializationOfMaybeAssignmentFlag) { |
i::Handle<i::JSFunction> f = i::Handle<i::JSFunction>::cast(o); |
i::Context* context = f->context(); |
i::AstValueFactory avf(&zone, isolate->heap()->HashSeed()); |
- avf.Internalize(isolate); |
const i::AstRawString* name = avf.GetOneByteString("result"); |
+ avf.Internalize(isolate); |
i::Handle<i::String> str = name->string(); |
CHECK(str->IsInternalizedString()); |
i::DeclarationScope* script_scope = |
@@ -3446,6 +3447,7 @@ TEST(IfArgumentsArrayAccessedThenParametersMaybeAssigned) { |
i::Handle<i::JSFunction> f = i::Handle<i::JSFunction>::cast(o); |
i::Context* context = f->context(); |
i::AstValueFactory avf(&zone, isolate->heap()->HashSeed()); |
+ const i::AstRawString* name_x = avf.GetOneByteString("x"); |
avf.Internalize(isolate); |
i::DeclarationScope* script_scope = |
@@ -3453,7 +3455,6 @@ TEST(IfArgumentsArrayAccessedThenParametersMaybeAssigned) { |
i::Scope* s = i::Scope::DeserializeScopeChainForTesting( |
isolate, &zone, context, script_scope, &avf); |
CHECK(s != script_scope); |
- const i::AstRawString* name_x = avf.GetOneByteString("x"); |
// Get result from f's function context (that is g's outer context) |
i::Variable* var_x = s->Lookup(name_x); |