Skip to content

Commit f50173b

Browse files
committed
Updated test to verify error detection with fully templated type.
1 parent a1fa5cc commit f50173b

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

clang/test/OpenMP/teams_reduction_messages.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -108,7 +108,7 @@ S3 h, k;
108108
#pragma omp threadprivate(h) // expected-note 2 {{defined as threadprivate or thread local}}
109109

110110
template <class T, class S> // expected-note {{declared here}}
111-
T tfoobar2(T argc, S ub[]) {
111+
T tfoobar2(T argc, S ub) {
112112
const T d = T(); // expected-note 4 {{'d' defined here}}
113113
const T da[5] = {T()}; // expected-note 2 {{'da' defined here}}
114114
T qa[5] = {T()};
@@ -379,5 +379,5 @@ int foobar2(int argc, float ub[]) {
379379
#pragma omp teams reduction(* : ub[:]) // expected-error {{section length is unspecified and cannot be inferred because subscripted value is an array of unknown bound}}
380380
foo();
381381

382-
return tfoobar2(argc, ub) + tfoobar2(fl, ub); // expected-note {{in instantiation of function template specialization 'tfoobar2<int, float>' requested here}} expected-note {{in instantiation of function template specialization 'tfoobar2<float, float>' requested here}}
382+
return tfoobar2<int, float []>(argc, ub) + tfoobar2<float, float []>(fl, ub); // expected-note {{in instantiation of function template specialization 'tfoobar2<int, float[]>' requested here}} expected-note {{in instantiation of function template specialization 'tfoobar2<float, float[]>' requested here}}
383383
}

0 commit comments

Comments
 (0)