@@ -43,7 +43,7 @@ var MODE = 'throw';
43
43
* @param {IntegerArray } x.strides - stride lengths
44
44
* @param {NonNegativeInteger } x.offset - index offset
45
45
* @param {string } x.order - specifies whether `x` is row-major (C-style) or column-major (Fortran-style)
46
- * @param {Function } x.getter - callback for accessing `x` data buffer elements
46
+ * @param {Array< Function> } x.accessors - accessors for accessing data buffer elements
47
47
* @param {Object } y - object containing output ndarray meta data
48
48
* @param {string } y.dtype - data type
49
49
* @param {Collection } y.data - data buffer
@@ -52,7 +52,7 @@ var MODE = 'throw';
52
52
* @param {IntegerArray } y.strides - stride lengths
53
53
* @param {NonNegativeInteger } y.offset - index offset
54
54
* @param {string } y.order - specifies whether `y` is row-major (C-style) or column-major (Fortran-style)
55
- * @param {Function } y.setter - callback for setting `y` data buffer elements
55
+ * @param {Array< Function> } y.accessors - accessors for accessing data buffer elements
56
56
* @param {Function } fcn - function to apply
57
57
* @param {* } thisArg - function execution context
58
58
* @returns {void }
@@ -102,7 +102,7 @@ var MODE = 'throw';
102
102
* 'strides': sx,
103
103
* 'offset': ox,
104
104
* 'order': 'row-major',
105
- * 'getter ': getter
105
+ * 'accessors ': [ getter, setter ]
106
106
* };
107
107
* x.ref = x;
108
108
*
@@ -115,7 +115,7 @@ var MODE = 'throw';
115
115
* 'strides': sy,
116
116
* 'offset': oy,
117
117
* 'order': 'row-major',
118
- * 'setter ': setter
118
+ * 'accessors ': [ getter, setter ]
119
119
* };
120
120
*
121
121
* // Apply the unary function:
@@ -172,8 +172,8 @@ function mapRight( x, y, fcn, thisArg ) {
172
172
ordy = y . order ;
173
173
174
174
// Cache accessors:
175
- get = x . getter ;
176
- set = y . setter ;
175
5090
+ get = x . accessors [ 0 ] ;
176
+ set = y . accessors [ 1 ] ;
177
177
178
178
// Cache the reference to the original input array:
179
179
ref = x . ref ;
0 commit comments