Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(5)

Side by Side Diff: third_party/WebKit/Source/bindings/core/v8/ScriptModule.cpp

Issue 2834053003: Split V8Binding (Closed)
Patch Set: Rebase Created 3 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2017 The Chromium Authors. All rights reserved. 1 // Copyright 2017 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "bindings/core/v8/ScriptModule.h" 5 #include "bindings/core/v8/ScriptModule.h"
6 6
7 #include "bindings/core/v8/V8Binding.h" 7 #include "bindings/core/v8/V8BindingForCore.h"
8 #include "core/dom/Modulator.h" 8 #include "core/dom/Modulator.h"
9 #include "core/dom/ScriptModuleResolver.h" 9 #include "core/dom/ScriptModuleResolver.h"
10 10
11 namespace blink { 11 namespace blink {
12 12
13 ScriptModule::ScriptModule(v8::Isolate* isolate, v8::Local<v8::Module> module) 13 ScriptModule::ScriptModule(v8::Isolate* isolate, v8::Local<v8::Module> module)
14 : module_(SharedPersistent<v8::Module>::Create(module, isolate)), 14 : module_(SharedPersistent<v8::Module>::Create(module, isolate)),
15 identity_hash_(static_cast<unsigned>(module->GetIdentityHash())) { 15 identity_hash_(static_cast<unsigned>(module->GetIdentityHash())) {
16 DCHECK(!module_->IsEmpty()); 16 DCHECK(!module_->IsEmpty());
17 } 17 }
(...skipping 91 matching lines...) Expand 10 before | Expand all | Expand 10 after
109 if (resolved.IsNull()) { 109 if (resolved.IsNull()) {
110 DCHECK(exception_state.HadException()); 110 DCHECK(exception_state.HadException());
111 return v8::MaybeLocal<v8::Module>(); 111 return v8::MaybeLocal<v8::Module>();
112 } 112 }
113 113
114 DCHECK(!exception_state.HadException()); 114 DCHECK(!exception_state.HadException());
115 return v8::MaybeLocal<v8::Module>(resolved.module_->NewLocal(isolate)); 115 return v8::MaybeLocal<v8::Module>(resolved.module_->NewLocal(isolate));
116 } 116 }
117 117
118 } // namespace blink 118 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698