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

Unified Diff: Source/bindings/tests/results/V8TestInterfaceWillBeGarbageCollected.cpp

Issue 353623003: Remove obsolete document wrapper creation in named constructors (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@idl-document-cleanup
Patch Set: Created 6 years, 6 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/bindings/tests/results/V8TestInterfaceNamedConstructor2.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/bindings/tests/results/V8TestInterfaceWillBeGarbageCollected.cpp
diff --git a/Source/bindings/tests/results/V8TestInterfaceWillBeGarbageCollected.cpp b/Source/bindings/tests/results/V8TestInterfaceWillBeGarbageCollected.cpp
index e06f83c9b23f410c744741666df40113024a5ab1..57df20d212c30c8a4355605604b4376e94d7300f 100644
--- a/Source/bindings/tests/results/V8TestInterfaceWillBeGarbageCollected.cpp
+++ b/Source/bindings/tests/results/V8TestInterfaceWillBeGarbageCollected.cpp
@@ -139,13 +139,7 @@ static void V8TestInterfaceWillBeGarbageCollectedConstructorCallback(const v8::F
return;
}
- Document* documentPtr = currentDOMWindow(isolate)->document();
- ASSERT(documentPtr);
- Document& document = *documentPtr;
-
- // Make sure the document is added to the DOM Node map. Otherwise, the TestInterfaceWillBeGarbageCollected instance
- // may end up being the only node in the map and get garbage-collected prematurely.
- toV8(documentPtr, info.Holder(), isolate);
+ Document& document = *toDocument(currentExecutionContext(isolate));
if (UNLIKELY(info.Length() < 1)) {
throwMinimumArityTypeErrorForConstructor("TestInterfaceWillBeGarbageCollected", 1, info.Length(), info.GetIsolate());
« no previous file with comments | « Source/bindings/tests/results/V8TestInterfaceNamedConstructor2.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698