Skip to content

Commit 4965d65

Browse files
committed
Fix test after rebase of #5195
1 parent 1b1e913 commit 4965d65

File tree

1 file changed

+3
-5
lines changed

1 file changed

+3
-5
lines changed

clang/test/SemaSYCL/wrong-address-taking.cpp

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -45,14 +45,12 @@ void basicUsage() {
4545

4646
template <typename T> void templatedContext() {
4747

48-
// FIXME: this is likely not diagnosed because of a common problem among
49-
// deferred diagnostics. They don't work from templated context if the
50-
// problematic code doesn't depend on a template parameter. See
51-
// https://github.com/intel/llvm/pull/5114 for an explanation of the problem
52-
// and possible solution.
48+
// expected-error@+1 {{taking address of a function not marked with 'intel::device_indirectly_callable' attribute is not allowed in SYCL device code}}
5349
int (*p)(int) = &badFoo;
50+
// expected-error@+1 {{taking address of a function not marked with 'intel::device_indirectly_callable' attribute is not allowed in SYCL device code}}
5451
auto p1 = &ForMembers::badMember;
5552

53+
// expected-error@+2 {{taking address of a function not marked with 'intel::device_indirectly_callable' attribute is not allowed in SYCL device code}}
5654
// expected-note@+1 {{called by 'templatedContext<int>'}}
5755
templateCaller1<badFoo>(1);
5856
}

0 commit comments

Comments
 (0)