Index: runtime/vm/object.h |
diff --git a/runtime/vm/object.h b/runtime/vm/object.h |
index 387b7342767efaa66ede3877fb27bd9e3b949900..dc278a8f98823ab6ee3ed216d914ef31fd0b79a8 100644 |
--- a/runtime/vm/object.h |
+++ b/runtime/vm/object.h |
@@ -5615,7 +5615,8 @@ class TypedData : public Instance { |
} |
void* DataAddr(intptr_t byte_offset) const { |
- ASSERT((byte_offset >= 0) && (byte_offset < LengthInBytes())); |
+ ASSERT((byte_offset == 0) || |
+ ((byte_offset > 0) && (byte_offset < LengthInBytes()))); |
return reinterpret_cast<void*>(raw_ptr()->data_ + byte_offset); |
} |
@@ -5747,7 +5748,8 @@ class ExternalTypedData : public Instance { |
} |
void* DataAddr(intptr_t byte_offset) const { |
- ASSERT((byte_offset >= 0) && (byte_offset < LengthInBytes())); |
+ ASSERT((byte_offset == 0) || |
+ ((byte_offset > 0) && (byte_offset < LengthInBytes()))); |
return reinterpret_cast<void*>(raw_ptr()->data_ + byte_offset); |
} |