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

Unified Diff: Source/bindings/core/v8/ScriptWrappable.cpp

Issue 422873002: bindings: Introduces ScriptWrappableBase to provide the internal pointer. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Fixed copyright notice. Created 6 years, 5 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/core/v8/ScriptWrappable.h ('k') | Source/bindings/core/v8/v8.gypi » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/bindings/core/v8/ScriptWrappable.cpp
diff --git a/Source/bindings/core/v8/ScriptWrappable.cpp b/Source/bindings/core/v8/ScriptWrappable.cpp
new file mode 100644
index 0000000000000000000000000000000000000000..76890acca3651af77f74c9b2aa9ff4d85e60ea99
--- /dev/null
+++ b/Source/bindings/core/v8/ScriptWrappable.cpp
@@ -0,0 +1,21 @@
+// Copyright 2014 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#include "config.h"
+#include "bindings/core/v8/ScriptWrappable.h"
+
+namespace blink {
+
+struct SameSizeAsScriptWrappableBase { };
+
+COMPILE_ASSERT(sizeof(ScriptWrappableBase) <= sizeof(SameSizeAsScriptWrappableBase), ScriptWrappableBase_should_stay_small);
+
+struct SameSizeAsScriptWrappable : public ScriptWrappableBase {
+ virtual ~SameSizeAsScriptWrappable() { }
+ uintptr_t m_wrapperOrTypeInfo;
+};
+
+COMPILE_ASSERT(sizeof(ScriptWrappable) <= sizeof(SameSizeAsScriptWrappable), ScriptWrappable_should_stay_small);
+
+} // namespace blink
« no previous file with comments | « Source/bindings/core/v8/ScriptWrappable.h ('k') | Source/bindings/core/v8/v8.gypi » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698