Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
use System.arraycopy in one more place in VMArray.
  • Loading branch information
timo committed Jul 25, 2013
1 parent 24c14a7 commit 3e222b8
Show file tree
Hide file tree
Showing 7 changed files with 7 additions and 14 deletions.
Expand Up @@ -87,8 +87,7 @@ private void set_size_internal(ThreadContext tc, long n) {
}
else {
SixModelObject[] new_slots = new SixModelObject[(int)ssize];
for (int i = 0; i < slots.length; i++)
new_slots[i] = slots[i];
System.arraycopy(slots, 0, new_slots, 0, slots.length);
slots = new_slots;
}

Expand Down
Expand Up @@ -87,8 +87,7 @@ private void set_size_internal(ThreadContext tc, long n) {
}
else {
long[] new_slots = new long[(int)ssize];
for (int i = 0; i < slots.length; i++)
new_slots[i] = slots[i];
System.arraycopy(slots, 0, new_slots, 0, slots.length);
slots = new_slots;
}

Expand Down
Expand Up @@ -87,8 +87,7 @@ private void set_size_internal(ThreadContext tc, long n) {
}
else {
short[] new_slots = new short[(int)ssize];
for (int i = 0; i < slots.length; i++)
new_slots[i] = slots[i];
System.arraycopy(slots, 0, new_slots, 0, slots.length);
slots = new_slots;
}

Expand Down
Expand Up @@ -87,8 +87,7 @@ private void set_size_internal(ThreadContext tc, long n) {
}
else {
int[] new_slots = new int[(int)ssize];
for (int i = 0; i < slots.length; i++)
new_slots[i] = slots[i];
System.arraycopy(slots, 0, new_slots, 0, slots.length);
slots = new_slots;
}

Expand Down
Expand Up @@ -87,8 +87,7 @@ private void set_size_internal(ThreadContext tc, long n) {
}
else {
byte[] new_slots = new byte[(int)ssize];
for (int i = 0; i < slots.length; i++)
new_slots[i] = slots[i];
System.arraycopy(slots, 0, new_slots, 0, slots.length);
slots = new_slots;
}

Expand Down
Expand Up @@ -87,8 +87,7 @@ private void set_size_internal(ThreadContext tc, long n) {
}
else {
double[] new_slots = new double[(int)ssize];
for (int i = 0; i < slots.length; i++)
new_slots[i] = slots[i];
System.arraycopy(slots, 0, new_slots, 0, slots.length);
slots = new_slots;
}

Expand Down
Expand Up @@ -87,8 +87,7 @@ private void set_size_internal(ThreadContext tc, long n) {
}
else {
String[] new_slots = new String[(int)ssize];
for (int i = 0; i < slots.length; i++)
new_slots[i] = slots[i];
System.arraycopy(slots, 0, new_slots, 0, slots.length);
slots = new_slots;
}

Expand Down

0 comments on commit 3e222b8

Please sign in to comment.