Skip to content

Commit d5699d4

Browse files
committed
[SYCL] Fix fail in the post commit testing
Signed-off-by: Artur Gainullin <[email protected]>
1 parent c6c2ecd commit d5699d4

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

sycl/test/basic_tests/handler/handler_set_args.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -22,31 +22,31 @@ using AccessorT = cl::sycl::accessor<int, 1, cl::sycl::access::mode::read_write,
2222
struct SingleTaskFunctor {
2323
SingleTaskFunctor(AccessorT acc) : MAcc(acc) {}
2424

25-
void operator()() { MAcc[0] = 10; }
25+
void operator()() const { MAcc[0] = 10; }
2626

2727
AccessorT MAcc;
2828
};
2929

3030
template <bool useOffset> struct ParallelForRangeIdFunctor {
3131
ParallelForRangeIdFunctor(AccessorT acc) : MAcc(acc) {}
3232

33-
void operator()(cl::sycl::id<1> id) { MAcc[0] = 10; }
33+
void operator()(cl::sycl::id<1> id) const { MAcc[0] = 10; }
3434

3535
AccessorT MAcc;
3636
};
3737

3838
template <bool useOffset> struct ParallelForRangeItemFunctor {
3939
ParallelForRangeItemFunctor(AccessorT acc) : MAcc(acc) {}
4040

41-
void operator()(cl::sycl::item<1> item) { MAcc[0] = 10; }
41+
void operator()(cl::sycl::item<1> item) const { MAcc[0] = 10; }
4242

4343
AccessorT MAcc;
4444
};
4545

4646
struct ParallelForNdRangeFunctor {
4747
ParallelForNdRangeFunctor(AccessorT acc) : MAcc(acc) {}
4848

49-
void operator()(cl::sycl::nd_item<1> ndItem) { MAcc[0] = 10; }
49+
void operator()(cl::sycl::nd_item<1> ndItem) const { MAcc[0] = 10; }
5050

5151
AccessorT MAcc;
5252
};

0 commit comments

Comments
 (0)