Commit fab2efa8 authored by vogelheim's avatar vogelheim Committed by Commit bot

Make LiteralBuffer + LiteralScope private.

Reduce the Scanner API, in order to make subsequent rework easier.

R=marja@chromium.org
BUG=v8:4947

Review-Url: https://codereview.chromium.org/2192883002
Cr-Commit-Position: refs/heads/master@{#38522}
parent 56b7a5fa
......@@ -5365,13 +5365,12 @@ IterationStatement* Parser::LookupContinueTarget(const AstRawString* label,
void Parser::HandleSourceURLComments(Isolate* isolate, Handle<Script> script) {
if (scanner_.source_url()->length() > 0) {
Handle<String> source_url = scanner_.source_url()->Internalize(isolate);
Handle<String> source_url = scanner_.SourceUrl(isolate);
if (!source_url.is_null()) {
script->set_source_url(*source_url);
}
if (scanner_.source_mapping_url()->length() > 0) {
Handle<String> source_mapping_url =
scanner_.source_mapping_url()->Internalize(isolate);
Handle<String> source_mapping_url = scanner_.SourceMappingUrl(isolate);
if (!source_mapping_url.is_null()) {
script->set_source_mapping_url(*source_mapping_url);
}
}
......
......@@ -19,8 +19,7 @@
namespace v8 {
namespace internal {
Handle<String> LiteralBuffer::Internalize(Isolate* isolate) const {
Handle<String> Scanner::LiteralBuffer::Internalize(Isolate* isolate) const {
if (is_one_byte()) {
return isolate->factory()->InternalizeOneByteString(one_byte_literal());
}
......
This diff is collapsed.
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