1 // RUN: %clang_cc1 -verify -fopenmp -ferror-limit 200 %s -Wno-openmp-target 2 3 // RUN: %clang_cc1 -verify -fopenmp-simd -ferror-limit 200 %s -Wno-openmp-target 4 // RUN: %clang_cc1 -DCCODE -verify -fopenmp -ferror-limit 200 -x c %s -Wno-openmp-target 5 #ifdef CCODE 6 void foo(int arg) { 7 const int n = 0; 8 9 double marr[10][10][10]; 10 11 #pragma omp target teams map(marr[2][0:2][0:2]) // expected-error {{array section does not specify contiguous storage}} 12 {} 13 #pragma omp target teams map(marr[:][0:][:]) 14 {} 15 #pragma omp target teams map(marr[:][1:][:]) // expected-error {{array section does not specify contiguous storage}} 16 {} 17 #pragma omp target teams map(marr[:][n:][:]) 18 {} 19 } 20 #else 21 template <typename T, int I> 22 struct SA { 23 static int ss; 24 #pragma omp threadprivate(ss) // expected-note {{defined as threadprivate or thread local}} 25 float a; 26 int b[12]; 27 float *c; 28 T d; 29 float e[I]; 30 T *f; 31 void func(int arg) { 32 #pragma omp target teams map(arg,a,d) 33 {} 34 #pragma omp target teams map(arg[2:2],a,d) // expected-error {{subscripted value is not an array or pointer}} 35 {} 36 #pragma omp target teams map(arg,a*2) // expected-error {{expected expression containing only member accesses and/or array sections based on named variables}} 37 {} 38 #pragma omp target teams map(arg,(c+1)[2]) // expected-error {{expected expression containing only member accesses and/or array sections based on named variables}} 39 {} 40 #pragma omp target teams map(arg,a[:2],d) // expected-error {{subscripted value is not an array or pointer}} 41 {} 42 #pragma omp target teams map(arg,a,d[:2]) // expected-error {{subscripted value is not an array or pointer}} 43 {} 44 45 #pragma omp target teams map(to:ss) // expected-error {{threadprivate variables are not allowed in 'map' clause}} 46 {} 47 48 #pragma omp target teams map(to:b,e) 49 {} 50 #pragma omp target teams map(to:b,e) map(to:b) // expected-error {{variable already marked as mapped in current construct}} expected-note {{used here}} 51 {} 52 #pragma omp target teams map(to:b[:2],e) 53 {} 54 #pragma omp target teams map(to:b,e[:]) 55 {} 56 #pragma omp target teams map(b[-1:]) // expected-error {{array section must be a subset of the original array}} 57 {} 58 #pragma omp target teams map(b[:-1]) // expected-error {{section length is evaluated to a negative value -1}} 59 {} 60 #pragma omp target teams map(b[true:true]) 61 {} 62 63 #pragma omp target teams map(always, tofrom: c,f) 64 {} 65 #pragma omp target teams map(always, tofrom: c[1:2],f) 66 {} 67 #pragma omp target teams map(always, tofrom: c,f[1:2]) 68 {} 69 #pragma omp target teams map(always, tofrom: c[:],f) // expected-error {{section length is unspecified and cannot be inferred because subscripted value is not an array}} 70 {} 71 #pragma omp target teams map(always, tofrom: c,f[:]) // expected-error {{section length is unspecified and cannot be inferred because subscripted value is not an array}} 72 {} 73 return; 74 } 75 }; 76 77 struct SB { 78 unsigned A; 79 unsigned B; 80 float Arr[100]; 81 float *Ptr; 82 float *foo() { 83 return &Arr[0]; 84 } 85 }; 86 87 struct SC { 88 unsigned A : 2; 89 unsigned B : 3; 90 unsigned C; 91 unsigned D; 92 float Arr[100]; 93 SB S; 94 SB ArrS[100]; 95 SB *PtrS; 96 SB *&RPtrS; 97 float *Ptr; 98 99 SC(SB *&_RPtrS) : RPtrS(_RPtrS) {} 100 }; 101 102 union SD { 103 unsigned A; 104 float B; 105 }; 106 107 void SAclient(int arg) { 108 SA<int,123> s; 109 s.func(arg); // expected-note {{in instantiation of member function}} 110 double marr[10][10][10]; 111 double marr2[5][10][1]; 112 double mvla[5][arg][10]; 113 double ***mptr; 114 const int n = 0; 115 const int m = 1; 116 double mvla2[5][arg][m+n+10]; 117 118 SB *p; 119 120 SD u; 121 SC r(p),t(p); 122 #pragma omp target teams map(r) 123 {} 124 #pragma omp target teams map(marr[2][0:2][0:2]) // expected-error {{array section does not specify contiguous storage}} 125 {} 126 #pragma omp target teams map(marr[:][0:2][0:2]) // expected-error {{array section does not specify contiguous storage}} 127 {} 128 #pragma omp target teams map(marr[2][3][0:2]) 129 {} 130 #pragma omp target teams map(marr[:][:][:]) 131 {} 132 #pragma omp target teams map(marr[:2][:][:]) 133 {} 134 #pragma omp target teams map(marr[arg:][:][:]) 135 {} 136 #pragma omp target teams map(marr[arg:]) 137 {} 138 #pragma omp target teams map(marr[arg:][:arg][:]) // correct if arg is the size of dimension 2 139 {} 140 #pragma omp target teams map(marr[:arg][:]) 141 {} 142 #pragma omp target teams map(marr[:arg][n:]) 143 {} 144 #pragma omp target teams map(marr[:][:arg][n:]) // correct if arg is the size of dimension 2 145 {} 146 #pragma omp target teams map(marr[:][:m][n:]) // expected-error {{array section does not specify contiguous storage}} 147 {} 148 #pragma omp target teams map(marr[n:m][:arg][n:]) 149 {} 150 #pragma omp target teams map(marr[:2][:1][:]) // expected-error {{array section does not specify contiguous storage}} 151 {} 152 #pragma omp target teams map(marr[:2][1:][:]) // expected-error {{array section does not specify contiguous storage}} 153 {} 154 #pragma omp target teams map(marr[:2][:][:1]) // expected-error {{array section does not specify contiguous storage}} 155 {} 156 #pragma omp target teams map(marr[:2][:][1:]) // expected-error {{array section does not specify contiguous storage}} 157 {} 158 #pragma omp target teams map(marr[:1][:2][:]) 159 {} 160 #pragma omp target teams map(marr[:1][0][:]) 161 {} 162 #pragma omp target teams map(marr[:arg][:2][:]) // correct if arg is 1 163 {} 164 #pragma omp target teams map(marr[:1][3:1][:2]) 165 {} 166 #pragma omp target teams map(marr[:1][3:arg][:2]) // correct if arg is 1 167 {} 168 #pragma omp target teams map(marr[:1][3:2][:2]) // expected-error {{array section does not specify contiguous storage}} 169 {} 170 #pragma omp target teams map(marr[:2][:10][:]) 171 {} 172 #pragma omp target teams map(marr[:2][:][:5+5]) 173 {} 174 #pragma omp target teams map(marr[:2][2+2-4:][0:5+5]) 175 {} 176 177 #pragma omp target teams map(marr[:1][:2][0]) // expected-error {{array section does not specify contiguous storage}} 178 {} 179 #pragma omp target teams map(marr2[:1][:2][0]) 180 {} 181 182 #pragma omp target teams map(mvla[:1][:][0]) // correct if the size of dimension 2 is 1. 183 {} 184 #pragma omp target teams map(mvla[:2][:arg][:]) // correct if arg is the size of dimension 2. 185 {} 186 #pragma omp target teams map(mvla[:1][:2][0]) // expected-error {{array section does not specify contiguous storage}} 187 {} 188 #pragma omp target teams map(mvla[1][2:arg][:]) 189 {} 190 #pragma omp target teams map(mvla[:1][:][:]) 191 {} 192 #pragma omp target teams map(mvla2[:1][:2][:11]) 193 {} 194 #pragma omp target teams map(mvla2[:1][:2][:10]) // expected-error {{array section does not specify contiguous storage}} 195 {} 196 197 #pragma omp target teams map(mptr[:2][2+2-4:1][0:5+5]) // expected-error {{array section does not specify contiguous storage}} 198 {} 199 #pragma omp target teams map(mptr[:1][:2-1][2:4-3]) 200 {} 201 #pragma omp target teams map(mptr[:1][:arg][2:4-3]) // correct if arg is 1. 202 {} 203 #pragma omp target teams map(mptr[:1][:2-1][0:2]) 204 {} 205 #pragma omp target teams map(mptr[:1][:2][0:2]) // expected-error {{array section does not specify contiguous storage}} 206 {} 207 #pragma omp target teams map(mptr[:1][:][0:2]) // expected-error {{section length is unspecified and cannot be inferred because subscripted value is not an array}} 208 {} 209 #pragma omp target teams map(mptr[:2][:1][0:2]) // expected-error {{array section does not specify contiguous storage}} 210 {} 211 212 #pragma omp target teams map(r.ArrS[0].B) 213 {} 214 #pragma omp target teams map(r.ArrS[:1].B) // expected-error {{OpenMP array section is not allowed here}} 215 {} 216 #pragma omp target teams map(r.ArrS[:arg].B) // expected-error {{OpenMP array section is not allowed here}} 217 {} 218 #pragma omp target teams map(r.ArrS[0].Arr[1:23]) 219 {} 220 #pragma omp target teams map(r.ArrS[0].Arr[1:arg]) 221 {} 222 #pragma omp target teams map(r.ArrS[0].Arr[arg:23]) 223 {} 224 #pragma omp target teams map(r.ArrS[0].Error) // expected-error {{no member named 'Error' in 'SB'}} 225 {} 226 #pragma omp target teams map(r.ArrS[0].A, r.ArrS[1].A) // expected-error {{multiple array elements associated with the same variable are not allowed in map clauses of the same construct}} expected-note {{used here}} 227 {} 228 #pragma omp target teams map(r.ArrS[0].A, t.ArrS[1].A) 229 {} 230 #pragma omp target teams map(r.PtrS[0], r.PtrS->B) // expected-error {{same pointer dereferenced in multiple different ways in map clause expressions}} expected-note {{used here}} 231 {} 232 #pragma omp target teams map(r.PtrS, r.PtrS->B) // expected-error {{pointer cannot be mapped along with a section derived from itself}} expected-note {{used here}} 233 {} 234 #pragma omp target teams map(r.PtrS->A, r.PtrS->B) 235 {} 236 #pragma omp target teams map(r.RPtrS[0], r.RPtrS->B) // expected-error {{same pointer dereferenced in multiple different ways in map clause expressions}} expected-note {{used here}} 237 {} 238 #pragma omp target teams map(r.RPtrS, r.RPtrS->B) // expected-error {{pointer cannot be mapped along with a section derived from itself}} expected-note {{used here}} 239 {} 240 #pragma omp target teams map(r.RPtrS->A, r.RPtrS->B) 241 {} 242 #pragma omp target teams map(r.S.Arr[:12]) 243 {} 244 #pragma omp target teams map(r.S.foo()[:12]) // expected-error {{expected expression containing only member accesses and/or array sections based on named variables}} 245 {} 246 #pragma omp target teams map(r.C, r.D) 247 {} 248 #pragma omp target teams map(r.C, r.C) // expected-error {{variable already marked as mapped in current construct}} expected-note {{used here}} 249 {} 250 #pragma omp target teams map(r.C) map(r.C) // expected-error {{variable already marked as mapped in current construct}} expected-note {{used here}} 251 {} 252 #pragma omp target teams map(r.C, r.S) // this would be an error only caught at runtime - Sema would have to make sure there is not way for the missing data between fields to be mapped somewhere else. 253 {} 254 #pragma omp target teams map(r, r.S) // expected-error {{variable already marked as mapped in current construct}} expected-note {{used here}} 255 {} 256 #pragma omp target teams map(r.C, t.C) 257 {} 258 #pragma omp target teams map(r.A) // expected-error {{bit fields cannot be used to specify storage in a 'map' clause}} 259 {} 260 #pragma omp target teams map(r.Arr) 261 {} 262 #pragma omp target teams map(r.Arr[3:5]) 263 {} 264 #pragma omp target teams map(r.Ptr[3:5]) 265 {} 266 #pragma omp target teams map(r.ArrS[3:5].A) // expected-error {{OpenMP array section is not allowed here}} 267 {} 268 #pragma omp target teams map(r.ArrS[3:5].Arr[6:7]) // expected-error {{OpenMP array section is not allowed here}} 269 {} 270 #pragma omp target teams map(r.ArrS[3].Arr[6:7]) 271 {} 272 #pragma omp target teams map(r.S.Arr[4:5]) 273 {} 274 #pragma omp target teams map(r.S.Ptr[4:5]) 275 {} 276 #pragma omp target teams map(r.S.Ptr[:]) // expected-error {{section length is unspecified and cannot be inferred because subscripted value is not an array}} 277 {} 278 #pragma omp target teams map((p+1)->A) // expected-error {{expected expression containing only member accesses and/or array sections based on named variables}} 279 {} 280 #pragma omp target teams map(u.B) // expected-error {{mapping of union members is not allowed}} 281 {} 282 283 #pragma omp target data map(to: r.C) //expected-note {{used here}} 284 { 285 #pragma omp target teams map(r.D) // expected-error {{original storage of expression in data environment is shared but data environment do not fully contain mapped expression storage}} 286 {} 287 } 288 289 #pragma omp target data map(to: t.Ptr) //expected-note {{used here}} 290 { 291 #pragma omp target teams map(t.Ptr[:23]) // expected-error {{pointer cannot be mapped along with a section derived from itself}} 292 {} 293 } 294 295 #pragma omp target data map(to: t.C, t.D) 296 { 297 #pragma omp target data map(to: t.C) 298 { 299 #pragma omp target teams map(t.D) 300 {} 301 } 302 } 303 304 #pragma omp target data map(to: t) 305 { 306 #pragma omp target data map(to: t.C) 307 { 308 #pragma omp target teams map(t.D) 309 {} 310 } 311 } 312 } 313 void foo() { 314 } 315 316 bool foobool(int argc) { 317 return argc; 318 } 319 320 struct S1; // expected-note 2 {{declared here}} 321 extern S1 a; 322 class S2 { 323 mutable int a; 324 public: 325 S2():a(0) { } 326 S2(S2 &s2):a(s2.a) { } 327 static float S2s; 328 static const float S2sc; 329 }; 330 const float S2::S2sc = 0; 331 const S2 b; 332 const S2 ba[5]; 333 class S3 { 334 int a; 335 public: 336 S3():a(0) { } 337 S3(S3 &s3):a(s3.a) { } 338 }; 339 const S3 c; 340 const S3 ca[5]; 341 extern const int f; 342 class S4 { 343 int a; 344 S4(); 345 S4(const S4 &s4); 346 public: 347 S4(int v):a(v) { } 348 }; 349 class S5 { 350 int a; 351 S5():a(0) {} 352 S5(const S5 &s5):a(s5.a) { } 353 public: 354 S5(int v):a(v) { } 355 }; 356 357 template <class T> 358 struct S6; 359 360 template<> 361 struct S6<int> 362 { 363 virtual void foo(); 364 }; 365 366 S3 h; 367 #pragma omp threadprivate(h) // expected-note 2 {{defined as threadprivate or thread local}} 368 369 typedef int from; 370 371 template <typename T, int I> // expected-note {{declared here}} 372 T tmain(T argc) { 373 const T d = 5; 374 const T da[5] = { 0 }; 375 S4 e(4); 376 S5 g(5); 377 T i, t[20]; 378 T &j = i; 379 T *k = &j; 380 T x; 381 T y; 382 T to, tofrom, always; 383 const T (&l)[5] = da; 384 #pragma omp target teams map // expected-error {{expected '(' after 'map'}} 385 {} 386 #pragma omp target teams map( // expected-error {{expected ')'}} expected-note {{to match this '('}} expected-error {{expected expression}} 387 {} 388 #pragma omp target teams map() // expected-error {{expected expression}} 389 {} 390 #pragma omp target teams map(alloc) // expected-error {{use of undeclared identifier 'alloc'}} 391 {} 392 #pragma omp target teams map(to argc // expected-error {{expected ')'}} expected-note {{to match this '('}} expected-error {{expected ',' or ')' in 'map' clause}} 393 {} 394 #pragma omp target teams map(to:) // expected-error {{expected expression}} 395 {} 396 #pragma omp target teams map(from: argc, // expected-error {{expected expression}} expected-error {{expected ')'}} expected-note {{to match this '('}} 397 {} 398 #pragma omp target teams map(x: y) // expected-error {{incorrect map type, expected one of 'to', 'from', 'tofrom', 'alloc', 'release', or 'delete'}} 399 {} 400 #pragma omp target teams map(x) 401 foo(); 402 #pragma omp target teams map(tofrom: t[:I]) 403 foo(); 404 #pragma omp target teams map(T: a) // expected-error {{incorrect map type, expected one of 'to', 'from', 'tofrom', 'alloc', 'release', or 'delete'}} expected-error {{incomplete type 'S1' where a complete type is required}} 405 foo(); 406 #pragma omp target teams map(T) // expected-error {{'T' does not refer to a value}} 407 foo(); 408 #pragma omp target teams map(I) // expected-error 2 {{expected expression containing only member accesses and/or array sections based on named variables}} 409 foo(); 410 #pragma omp target teams map(S2::S2s) 411 foo(); 412 #pragma omp target teams map(S2::S2sc) 413 foo(); 414 #pragma omp target teams map(x) 415 foo(); 416 #pragma omp target teams map(to: x) 417 foo(); 418 #pragma omp target teams map(to: to) 419 foo(); 420 #pragma omp target teams map(to) 421 foo(); 422 #pragma omp target teams map(to, x) 423 foo(); 424 425 #pragma omp target data map(to x) // expected-error {{expected ',' or ')' in 'map' clause}} 426 #pragma omp target data map(tofrom: argc > 0 ? x : y) // expected-error 2 {{expected expression containing only member accesses and/or array sections based on named variables}} 427 #pragma omp target data map(argc) 428 #pragma omp target data map(S1) // expected-error {{'S1' does not refer to a value}} 429 #pragma omp target data map(a, b, c, d, f) // expected-error {{incomplete type 'S1' where a complete type is required}} 430 #pragma omp target data map(ba) 431 #pragma omp target data map(ca) 432 #pragma omp target data map(da) 433 #pragma omp target data map(S2::S2s) 434 #pragma omp target data map(S2::S2sc) 435 #pragma omp target data map(e, g) 436 #pragma omp target data map(h) // expected-error {{threadprivate variables are not allowed in 'map' clause}} 437 #pragma omp target data map(k) map(k) // expected-error 2 {{variable already marked as mapped in current construct}} expected-note 2 {{used here}} 438 #pragma omp target teams map(k), map(k[:5]) // expected-error 2 {{pointer cannot be mapped along with a section derived from itself}} expected-note 2 {{used here}} 439 foo(); 440 441 #pragma omp target data map(da) 442 #pragma omp target teams map(da[:4]) 443 foo(); 444 445 #pragma omp target data map(k, j, l) // expected-note 2 {{used here}} 446 #pragma omp target data map(k[:4]) // expected-error 2 {{pointer cannot be mapped along with a section derived from itself}} 447 #pragma omp target data map(j) 448 #pragma omp target teams map(l) map(l[:5]) // expected-error 2 {{variable already marked as mapped in current construct}} expected-note 2 {{used here}} 449 foo(); 450 451 #pragma omp target data map(k[:4], j, l[:5]) // expected-note 2 {{used here}} 452 #pragma omp target data map(k) // expected-error 2 {{pointer cannot be mapped along with a section derived from itself}} 453 #pragma omp target data map(j) 454 #pragma omp target teams map(l) 455 foo(); 456 457 #pragma omp target data map(always, tofrom: x) 458 #pragma omp target data map(always: x) // expected-error {{missing map type}} 459 #pragma omp target data map(tofrom, always: x) // expected-error {{incorrect map type modifier, expected 'always', 'close', or 'mapper'}} expected-error {{missing map type}} 460 #pragma omp target data map(always, tofrom: always, tofrom, x) 461 #pragma omp target teams map(tofrom j) // expected-error {{expected ',' or ')' in 'map' clause}} 462 foo(); 463 return 0; 464 } 465 466 int main(int argc, char **argv) { 467 const int d = 5; 468 const int da[5] = { 0 }; 469 S4 e(4); 470 S5 g(5); 471 int i; 472 int &j = i; 473 int *k = &j; 474 S6<int> m; 475 int x; 476 int y; 477 int to, tofrom, always; 478 const int (&l)[5] = da; 479 #pragma omp target data map // expected-error {{expected '(' after 'map'}} expected-error {{expected at least one 'map' or 'use_device_ptr' clause for '#pragma omp target data'}} 480 #pragma omp target data map( // expected-error {{expected ')'}} expected-note {{to match this '('}} expected-error {{expected expression}} 481 #pragma omp target data map() // expected-error {{expected expression}} 482 #pragma omp target data map(alloc) // expected-error {{use of undeclared identifier 'alloc'}} 483 #pragma omp target data map(to argc // expected-error {{expected ')'}} expected-note {{to match this '('}} expected-error {{expected ',' or ')' in 'map' clause}} 484 #pragma omp target data map(to:) // expected-error {{expected expression}} 485 #pragma omp target data map(from: argc, // expected-error {{expected expression}} expected-error {{expected ')'}} expected-note {{to match this '('}} 486 #pragma omp target data map(x: y) // expected-error {{incorrect map type, expected one of 'to', 'from', 'tofrom', 'alloc', 'release', or 'delete'}} 487 #pragma omp target teams map(x) 488 foo(); 489 490 #pragma omp target teams map(to: x) 491 foo(); 492 #pragma omp target teams map(to: to) 493 foo(); 494 #pragma omp target teams map(to) 495 foo(); 496 #pragma omp target teams map(to, x) 497 foo(); 498 499 #pragma omp target data map(to x) // expected-error {{expected ',' or ')' in 'map' clause}} 500 #pragma omp target data map(tofrom: argc > 0 ? argv[1] : argv[2]) // expected-error {{xpected expression containing only member accesses and/or array sections based on named variables}} 501 #pragma omp target data map(argc) 502 #pragma omp target data map(S1) // expected-error {{'S1' does not refer to a value}} 503 #pragma omp target data map(a, b, c, d, f) // expected-error {{incomplete type 'S1' where a complete type is required}} 504 #pragma omp target data map(argv[1]) 505 #pragma omp target data map(ba) 506 #pragma omp target data map(ca) 507 #pragma omp target data map(da) 508 #pragma omp target data map(S2::S2s) 509 #pragma omp target data map(S2::S2sc) 510 #pragma omp target data map(e, g) 511 #pragma omp target data map(h) // expected-error {{threadprivate variables are not allowed in 'map' clause}} 512 #pragma omp target data map(k), map(k) // expected-error {{variable already marked as mapped in current construct}} expected-note {{used here}} 513 #pragma omp target teams map(k), map(k[:5]) // expected-error {{pointer cannot be mapped along with a section derived from itself}} expected-note {{used here}} 514 foo(); 515 516 #pragma omp target data map(da) 517 #pragma omp target teams map(da[:4]) 518 foo(); 519 520 #pragma omp target data map(k, j, l) // expected-note {{used here}} 521 #pragma omp target data map(k[:4]) // expected-error {{pointer cannot be mapped along with a section derived from itself}} 522 #pragma omp target data map(j) 523 #pragma omp target teams map(l) map(l[:5]) // expected-error {{variable already marked as mapped in current construct}} expected-note {{used here}} 524 foo(); 525 526 #pragma omp target data map(k[:4], j, l[:5]) // expected-note {{used here}} 527 #pragma omp target data map(k) // expected-error {{pointer cannot be mapped along with a section derived from itself}} 528 #pragma omp target data map(j) 529 #pragma omp target teams map(l) 530 foo(); 531 532 #pragma omp target data map(always, tofrom: x) 533 #pragma omp target data map(always: x) // expected-error {{missing map type}} 534 #pragma omp target data map(tofrom, always: x) // expected-error {{incorrect map type modifier, expected 'always', 'close', or 'mapper'}} expected-error {{missing map type}} 535 #pragma omp target data map(always, tofrom: always, tofrom, x) 536 #pragma omp target teams map(tofrom j) // expected-error {{expected ',' or ')' in 'map' clause}} 537 foo(); 538 539 #pragma omp target teams private(j) map(j) // expected-error {{private variable cannot be in a map clause in '#pragma omp target teams' directive}} expected-note {{defined as private}} 540 {} 541 542 #pragma omp target teams firstprivate(j) map(j) // expected-error {{firstprivate variable cannot be in a map clause in '#pragma omp target teams' directive}} expected-note {{defined as firstprivate}} 543 {} 544 545 #pragma omp target teams map(m) 546 {} 547 548 return tmain<int, 3>(argc)+tmain<from, 4>(argc); // expected-note {{in instantiation of function template specialization 'tmain<int, 3>' requested here}} expected-note {{in instantiation of function template specialization 'tmain<int, 4>' requested here}} 549 } 550 #endif 551