OpenCores
URL https://opencores.org/ocsvn/openrisc/openrisc/trunk

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [g++.dg/] [abi/] [mangle45.C] - Blame information for rev 701

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 693 jeremybenn
// Testcase for mangling of parameters used other than in a trailing return type
2
// { dg-options "-std=c++0x -fabi-version=5" }
3
 
4
template void f(T p, decltype(p)) { }                // L = 1
5
template void g(T p, decltype(p) (*)()) { }          // L = 1
6
// G++ incorrectly rejects these currently.
7
// template void h(T p, auto (*)()->decltype(p));    // L = 1
8
// template void i(T p, auto (*)(T q)->decltype(q)); // L = 0
9
// template void j(T p, auto (*)(decltype(p))->T);   // L = 2
10
template void k(T p, int (*(*)(T* p))[sizeof(p)]) {} // L = 1
11
 
12
int garg();
13
int (*karg (int*))[sizeof(int)];
14
int main()
15
{
16
  // { dg-final { scan-assembler  "_Z1fIiEvT_DtfL0p_E" } }
17
  f (1,0);
18
  // { dg-final { scan-assembler  "_Z1gIiEvT_PFDtfL0p_EvE" } }
19
  g (1,garg);
20
  // h (1,0);
21
  // i (1,0);
22
  // j (1,0);
23
  // { dg-final { scan-assembler  "_Z1kIiEvT_PFPAszfL0p__iPS0_E" } }
24
  k (1,karg);
25
}

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.