Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(108)

Unified Diff: src/objects.h

Issue 1188073003: Return void from array setters since the return value needs to be ignored (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/elements.cc ('k') | src/objects.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/objects.h
diff --git a/src/objects.h b/src/objects.h
index 462e7aa97698325e9dd6da942029b8dc05dcba59..84bafab59c5e5917c86bda8d8c079bb753f66dff 100644
--- a/src/objects.h
+++ b/src/objects.h
@@ -2432,9 +2432,8 @@ class FixedArray: public FixedArrayBase {
public:
// Setter and getter for elements.
inline Object* get(int index) const;
- static Handle<Object> SetValue(Handle<JSObject> holder,
- Handle<FixedArray> array, uint32_t index,
- Handle<Object> value);
+ static void SetValue(Handle<JSObject> holder, Handle<FixedArray> array,
+ uint32_t index, Handle<Object> value);
static inline Handle<Object> get(Handle<FixedArray> array, int index);
// Setter that uses write barrier.
inline void set(int index, Object* value);
@@ -2557,9 +2556,8 @@ class FixedDoubleArray: public FixedArrayBase {
inline uint64_t get_representation(int index);
static inline Handle<Object> get(Handle<FixedDoubleArray> array, int index);
// This accessor has to get a Number as |value|.
- static Handle<Object> SetValue(Handle<JSObject> holder,
- Handle<FixedDoubleArray> array, uint32_t index,
- Handle<Object> value);
+ static void SetValue(Handle<JSObject> holder, Handle<FixedDoubleArray> array,
+ uint32_t index, Handle<Object> value);
inline void set(int index, double value);
inline void set_the_hole(int index);
@@ -4394,9 +4392,9 @@ class ExternalUint8ClampedArray: public ExternalArray {
// This accessor applies the correct conversion from Smi, HeapNumber
// and undefined and clamps the converted value between 0 and 255.
- static Handle<Object> SetValue(Handle<JSObject> holder,
- Handle<ExternalUint8ClampedArray> array,
- uint32_t index, Handle<Object> value);
+ static void SetValue(Handle<JSObject> holder,
+ Handle<ExternalUint8ClampedArray> array, uint32_t index,
+ Handle<Object> value);
DECLARE_CAST(ExternalUint8ClampedArray)
@@ -4418,9 +4416,8 @@ class ExternalInt8Array: public ExternalArray {
// This accessor applies the correct conversion from Smi, HeapNumber
// and undefined.
- static Handle<Object> SetValue(Handle<JSObject> holder,
- Handle<ExternalInt8Array> array,
- uint32_t index, Handle<Object> value);
+ static void SetValue(Handle<JSObject> holder, Handle<ExternalInt8Array> array,
+ uint32_t index, Handle<Object> value);
DECLARE_CAST(ExternalInt8Array)
@@ -4442,9 +4439,9 @@ class ExternalUint8Array: public ExternalArray {
// This accessor applies the correct conversion from Smi, HeapNumber
// and undefined.
- static Handle<Object> SetValue(Handle<JSObject> holder,
- Handle<ExternalUint8Array> array,
- uint32_t index, Handle<Object> value);
+ static void SetValue(Handle<JSObject> holder,
+ Handle<ExternalUint8Array> array, uint32_t index,
+ Handle<Object> value);
DECLARE_CAST(ExternalUint8Array)
@@ -4466,9 +4463,9 @@ class ExternalInt16Array: public ExternalArray {
// This accessor applies the correct conversion from Smi, HeapNumber
// and undefined.
- static Handle<Object> SetValue(Handle<JSObject> holder,
- Handle<ExternalInt16Array> array,
- uint32_t index, Handle<Object> value);
+ static void SetValue(Handle<JSObject> holder,
+ Handle<ExternalInt16Array> array, uint32_t index,
+ Handle<Object> value);
DECLARE_CAST(ExternalInt16Array)
@@ -4491,9 +4488,9 @@ class ExternalUint16Array: public ExternalArray {
// This accessor applies the correct conversion from Smi, HeapNumber
// and undefined.
- static Handle<Object> SetValue(Handle<JSObject> holder,
- Handle<ExternalUint16Array> array,
- uint32_t index, Handle<Object> value);
+ static void SetValue(Handle<JSObject> holder,
+ Handle<ExternalUint16Array> array, uint32_t index,
+ Handle<Object> value);
DECLARE_CAST(ExternalUint16Array)
@@ -4515,9 +4512,9 @@ class ExternalInt32Array: public ExternalArray {
// This accessor applies the correct conversion from Smi, HeapNumber
// and undefined.
- static Handle<Object> SetValue(Handle<JSObject> holder,
- Handle<ExternalInt32Array> array,
- uint32_t index, Handle<Object> value);
+ static void SetValue(Handle<JSObject> holder,
+ Handle<ExternalInt32Array> array, uint32_t index,
+ Handle<Object> value);
DECLARE_CAST(ExternalInt32Array)
@@ -4540,9 +4537,9 @@ class ExternalUint32Array: public ExternalArray {
// This accessor applies the correct conversion from Smi, HeapNumber
// and undefined.
- static Handle<Object> SetValue(Handle<JSObject> holder,
- Handle<ExternalUint32Array> array,
- uint32_t index, Handle<Object> value);
+ static void SetValue(Handle<JSObject> holder,
+ Handle<ExternalUint32Array> array, uint32_t index,
+ Handle<Object> value);
DECLARE_CAST(ExternalUint32Array)
@@ -4565,9 +4562,9 @@ class ExternalFloat32Array: public ExternalArray {
// This accessor applies the correct conversion from Smi, HeapNumber
// and undefined.
- static Handle<Object> SetValue(Handle<JSObject> holder,
- Handle<ExternalFloat32Array> array,
- uint32_t index, Handle<Object> value);
+ static void SetValue(Handle<JSObject> holder,
+ Handle<ExternalFloat32Array> array, uint32_t index,
+ Handle<Object> value);
DECLARE_CAST(ExternalFloat32Array)
@@ -4590,9 +4587,9 @@ class ExternalFloat64Array: public ExternalArray {
// This accessor applies the correct conversion from Smi, HeapNumber
// and undefined.
- static Handle<Object> SetValue(Handle<JSObject> holder,
- Handle<ExternalFloat64Array> array,
- uint32_t index, Handle<Object> value);
+ static void SetValue(Handle<JSObject> holder,
+ Handle<ExternalFloat64Array> array, uint32_t index,
+ Handle<Object> value);
DECLARE_CAST(ExternalFloat64Array)
@@ -4660,9 +4657,9 @@ class FixedTypedArray: public FixedTypedArrayBase {
// This accessor applies the correct conversion from Smi, HeapNumber
// and undefined.
- static Handle<Object> SetValue(Handle<JSObject> holder,
- Handle<FixedTypedArray<Traits> > array,
- uint32_t index, Handle<Object> value);
+ static void SetValue(Handle<JSObject> holder,
+ Handle<FixedTypedArray<Traits> > array, uint32_t index,
+ Handle<Object> value);
DECLARE_PRINTER(FixedTypedArray)
DECLARE_VERIFIER(FixedTypedArray)
« no previous file with comments | « src/elements.cc ('k') | src/objects.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698