diff options
author | Sebastien Hertz <shertz@google.com> | 2013-07-01 07:21:33 +0000 |
---|---|---|
committer | Android (Google) Code Review <android-gerrit@google.com> | 2013-07-01 07:21:34 +0000 |
commit | 60c70c77d10ea2cea9ca73bb3d6e550ac167f3a1 (patch) | |
tree | e840540444a6bdb823f33340dc2633af7a54531e /src | |
parent | 55163b8c34f40c9107cc3aa72e0d2f542f7a164e (diff) | |
parent | 9897be996580db9de86f880f9ad9d36c66057a52 (diff) | |
download | art-60c70c77d10ea2cea9ca73bb3d6e550ac167f3a1.zip art-60c70c77d10ea2cea9ca73bb3d6e550ac167f3a1.tar.gz art-60c70c77d10ea2cea9ca73bb3d6e550ac167f3a1.tar.bz2 |
Merge "Make Array's throw routines void." into dalvik-dev
Diffstat (limited to 'src')
-rw-r--r-- | src/mirror/array.cc | 6 | ||||
-rw-r--r-- | src/mirror/array.h | 7 |
2 files changed, 6 insertions, 7 deletions
diff --git a/src/mirror/array.cc b/src/mirror/array.cc index e2e63a6..88cd309 100644 --- a/src/mirror/array.cc +++ b/src/mirror/array.cc @@ -134,14 +134,12 @@ Array* Array::CreateMultiArray(Thread* self, Class* element_class, IntArray* dim return new_array; } -bool Array::ThrowArrayIndexOutOfBoundsException(int32_t index) const { +void Array::ThrowArrayIndexOutOfBoundsException(int32_t index) const { art::ThrowArrayIndexOutOfBoundsException(index, GetLength()); - return false; } -bool Array::ThrowArrayStoreException(Object* object) const { +void Array::ThrowArrayStoreException(Object* object) const { art::ThrowArrayStoreException(object->GetClass(), this->GetClass()); - return false; } template<typename T> diff --git a/src/mirror/array.h b/src/mirror/array.h index 33c0aeb..98b8ea0 100644 --- a/src/mirror/array.h +++ b/src/mirror/array.h @@ -73,15 +73,16 @@ class MANAGED Array : public Object { bool IsValidIndex(int32_t index) const SHARED_LOCKS_REQUIRED(Locks::mutator_lock_) { if (UNLIKELY(index < 0 || index >= GetLength())) { - return ThrowArrayIndexOutOfBoundsException(index); + ThrowArrayIndexOutOfBoundsException(index); + return false; } return true; } protected: - bool ThrowArrayIndexOutOfBoundsException(int32_t index) const + void ThrowArrayIndexOutOfBoundsException(int32_t index) const SHARED_LOCKS_REQUIRED(Locks::mutator_lock_); - bool ThrowArrayStoreException(Object* object) const + void ThrowArrayStoreException(Object* object) const SHARED_LOCKS_REQUIRED(Locks::mutator_lock_); private: |