Index: Source/bindings/dart/DartDOMWrapper.h |
diff --git a/Source/bindings/dart/DartDOMWrapper.h b/Source/bindings/dart/DartDOMWrapper.h |
index a7c6cc080495f19a290c9d088f4ec70b7a0c28a0..2133508bcd6883edafc891052ad61fa97c6d7ba9 100644 |
--- a/Source/bindings/dart/DartDOMWrapper.h |
+++ b/Source/bindings/dart/DartDOMWrapper.h |
@@ -188,8 +188,12 @@ private: |
{ |
intptr_t value; |
Dart_Handle result = Dart_GetNativeInstanceField(wrapper, index, &value); |
- ASSERT(!Dart_IsError(result)); |
- UNUSED_PARAM(result); |
+ // FIXME: the fact that we return 0 on error rather than asserting is |
+ // somewhat of a hack. We currently make this method return 0 because |
+ // we reuse this method to verify that objects are actually native |
+ // Node objects rather than objects that implement the Node interface. |
+ if (Dart_IsError(result)) |
+ return 0; |
return reinterpret_cast<void*>(value); |
} |