Chromium Code Reviews| Index: Source/bindings/scripts/CodeGeneratorV8.pm |
| diff --git a/Source/bindings/scripts/CodeGeneratorV8.pm b/Source/bindings/scripts/CodeGeneratorV8.pm |
| index ba38bb6987608368159bb8aa9ef736af889ee1b9..dd3f9c18217e158049013f4cf3bcb6722d629e1e 100644 |
| --- a/Source/bindings/scripts/CodeGeneratorV8.pm |
| +++ b/Source/bindings/scripts/CodeGeneratorV8.pm |
| @@ -581,6 +581,11 @@ inline v8::Handle<v8::Object> wrap(${nativeType}* impl, v8::Handle<v8::Object> c |
| { |
| ASSERT(impl); |
| ASSERT(DOMDataStore::getWrapper(impl, isolate).IsEmpty()); |
| + if (ScriptWrappable::wrapperCanBeStoredInObject(impl)) { |
| + const WrapperTypeInfo* actualInfo = ScriptWrappable::getTypeInfoFromObject(impl); |
| + if (actualInfo != &${v8InterfaceName}::info) |
| + CRASH(); |
|
abarth-chromium
2013/04/23 21:09:48
Should we be using RELEASE_ASSERT? cevans seemed
|
| + } |
| return ${returningCreatedWrapperOpening}$createWrapperCall(impl, creationContext, isolate)${returningCreatedWrapperClosing}; |
| } |
| END |