Skip to content

Commit 8d47b44

Browse files
committed
Use multi_ptr<const> for vec::load
1 parent b609744 commit 8d47b44

File tree

1 file changed

+13
-1
lines changed

1 file changed

+13
-1
lines changed

multi_ptr-cast/sycl-2.2/index.md

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -151,7 +151,19 @@ template <typename ElementTypeU, typename ElementTypeT, access::address_space Sp
151151

152152
## Add `const` to existing functions taking a `multi_ptr`
153153

154-
TODO(Peter)
154+
For the class `vec`,
155+
use a const-qualified `multi_ptr` for the `load` member function:
156+
157+
```cpp
158+
template <typename dataT, int numElements>
159+
class vec {
160+
public:
161+
/// Existing members
162+
163+
template <access::address_space addressSpace>
164+
void load(size_t offset, multi_ptr<const dataT, addressSpace> ptr);
165+
};
166+
```
155167
156168
## Examples
157169

0 commit comments

Comments
 (0)