We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 1d99344 commit 116db44Copy full SHA for 116db44
sycl/unittests/helpers/PiImage.hpp
@@ -129,13 +129,20 @@ template <typename T> class PiArray {
129
updateEntries();
130
}
131
132
+ if (MEntries.empty())
133
+ return nullptr;
134
+
135
return &*MEntries.begin();
136
137
typename T::NativeType *end() {
138
if (MEntriesNeedUpdate) {
139
140
- return &*MEntries.end();
141
142
143
144
145
+ return &*MEntries.rbegin() + 1;
146
147
148
private:
@@ -176,7 +183,7 @@ class PiPropertySet {
176
183
_pi_device_binary_property_set_struct *end() {
177
184
if (MProperties.empty())
178
185
return nullptr;
179
- return &*MProperties.end();
186
+ return &*MProperties.rbegin() + 1;
180
187
181
188
182
189
0 commit comments