| 189 | } |
| 190 | |
| 191 | void array::copy_shared_buffer( |
| 192 | const array& other, |
| 193 | const Strides& strides, |
| 194 | Flags flags, |
| 195 | size_t data_size, |
| 196 | int64_t offset /* = 0 */) { |
| 197 | array_desc_->data = other.array_desc_->data; |
| 198 | array_desc_->strides = strides; |
| 199 | array_desc_->flags = flags; |
| 200 | array_desc_->data_size = data_size; |
| 201 | array_desc_->offset = |
| 202 | sizeof(char) * itemsize() * offset + other.array_desc_->offset; |
| 203 | } |
| 204 | |
| 205 | void array::copy_shared_buffer(const array& other) { |
| 206 | copy_shared_buffer(other, other.strides(), other.flags(), other.data_size()); |
no test coverage detected