imm_union value;
java_handle_t *o;
+ if (a == NULL) {
+ exceptions_throw_nullpointerexception();
+ return NULL;
+ }
+
v = LLNI_vftbl_direct(a);
type = v->arraydesc->arraytype;
int type;
imm_union value;
+ if (a == NULL) {
+ exceptions_throw_nullpointerexception();
+ value.a = NULL;
+ return value;
+ }
+
v = LLNI_vftbl_direct(a);
type = v->arraydesc->arraytype;
vftbl_t *v;
int type;
+ if (a == NULL) {
+ exceptions_throw_nullpointerexception();
+ return;
+ }
+
v = LLNI_vftbl_direct(a);
type = v->arraydesc->arraytype;
void array_objectarray_element_set(java_handle_objectarray_t *a, int32_t index, java_handle_t *value)
{
- int32_t size;
+ arraydescriptor *ad;
+ classinfo *cc;
+ int32_t size;
if (a == NULL) {
exceptions_throw_nullpointerexception();
return;
}
+ /* TODO Write inline functions for that and use LLNI. */
+
+ LLNI_CRITICAL_START;
+
+ ad = a->header.objheader.vftbl->arraydesc;
+ cc = ad->componentvftbl->class;
+
+ LLNI_CRITICAL_END;
+
+ if (ad->arraytype == ARRAYTYPE_OBJECT) {
+ if (value != NULL) {
+ if (builtin_instanceof(value, cc) == false) {
+ exceptions_throw_illegalargumentexception();
+ return;
+ }
+ }
+ }
+
size = LLNI_array_size(a);
if ((index < 0) || (index >= size)) {