Chromium Code Reviews| Index: runtime/lib/byte_array.cc |
| =================================================================== |
| --- runtime/lib/byte_array.cc (revision 9649) |
| +++ runtime/lib/byte_array.cc (working copy) |
| @@ -46,7 +46,7 @@ |
| #define SETTER(ArrayT, ObjectT, Getter, ValueT) \ |
| SETTER_ARGUMENTS(ArrayT, ObjectT, ValueT); \ |
| RangeCheck(array, index.Value() * sizeof(ValueT), sizeof(ValueT)); \ |
| - ValueT value = value_object.Getter(); \ |
| + ValueT value = value_object.Getter(); \ |
| array.SetAt(index.Value(), value); |
| @@ -62,10 +62,7 @@ |
| SETTER_ARGUMENTS(ArrayT, ObjectT, ValueT); \ |
| RangeCheck(array, index.Value(), sizeof(ValueT)); \ |
| ValueT src = value_object.Getter(); \ |
| - ByteArray::Copy(array, index.Value(), &src, sizeof(ValueT)); \ |
| - Integer& result = Integer::Handle(); \ |
| - result ^= Integer::New(index.Value() + sizeof(ValueT)); \ |
| - arguments->SetReturn(result); |
| + ByteArray::Copy(array, index.Value(), &src, sizeof(ValueT)); |
|
siva
2012/07/16 16:41:33
I think the setter methods of byte array need to r
regis
2012/07/16 18:05:34
Good point! I reverted the change here and instead
|
| #define UINT64_TO_INTEGER(value, integer) \ |
| @@ -124,10 +121,7 @@ |
| RangeCheck(array, index.Value(), sizeof(uint64_t)); \ |
| uint64_t value; \ |
| INTEGER_TO_UINT64(value_object, value); \ |
| - ByteArray::Copy(array, index.Value(), &value, sizeof(uint64_t)); \ |
| - Integer& result = Integer::Handle(); \ |
| - result ^= Integer::New(index.Value() + sizeof(uint64_t)); \ |
| - arguments->SetReturn(result); |
| + ByteArray::Copy(array, index.Value(), &value, sizeof(uint64_t)); |
|
siva
2012/07/16 16:41:33
Ditto.
regis
2012/07/16 18:05:34
Done.
|
| DEFINE_NATIVE_ENTRY(ByteArray_getLength, 1) { |