Index: third_party/WebKit/Source/bindings/templates/interface_base.cpp |
diff --git a/third_party/WebKit/Source/bindings/templates/interface_base.cpp b/third_party/WebKit/Source/bindings/templates/interface_base.cpp |
index 1ea037fe52ae7869108177bcca360bbdd6bb7cd7..8a09d03aef554f20fb15b4ee27aaf12330e88ca3 100644 |
--- a/third_party/WebKit/Source/bindings/templates/interface_base.cpp |
+++ b/third_party/WebKit/Source/bindings/templates/interface_base.cpp |
@@ -28,15 +28,23 @@ namespace blink { |
#if defined(COMPONENT_BUILD) && defined(WIN32) && COMPILER(CLANG) |
#pragma clang diagnostic pop |
#endif |
+{% if not is_typed_array_type %} |
// This static member must be declared by DEFINE_WRAPPERTYPEINFO in {{cpp_class}}.h. |
// For details, see the comment of DEFINE_WRAPPERTYPEINFO in |
// bindings/core/v8/ScriptWrappable.h. |
-{% if not is_typed_array_type %} |
const WrapperTypeInfo& {{cpp_class}}::s_wrapperTypeInfo = {{v8_class}}::wrapperTypeInfo; |
{% endif %} |
+{% if not active_scriptwrappable %} |
+static_assert( |
+ !std::is_base_of<ActiveScriptWrappable, {{cpp_class}}>::value, |
+ "{{cpp_class}} inherits from ActiveScriptWrappable, but does not specify " |
+ "[ActiveScriptWrappable] extended attribute in the IDL file. " |
+ "Be consistent."); |
peria
2016/08/16 07:24:43
Don't we need to care the inverted situation?
I me
Yuki
2016/08/16 08:43:27
In that case, a compile error is already happening
Yuki
2016/08/16 08:44:36
Just FYI, it's the same that T* does not inherit f
|
{% endif %} |
+ |
+{% endif %}{# not is_partial #} |
{% if not is_array_buffer_or_view %} |
namespace {{cpp_class_or_partial}}V8Internal { |
{% if has_partial_interface %} |