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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [g++.dg/] [cpp0x/] [fntmpdefarg2.C] - Blame information for rev 774

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

Line No. Rev Author Line
1 693 jeremybenn
// PR c++/46831
2
// { dg-options -std=c++0x }
3
 
4
struct B { };
5
struct D : B { };
6
struct A {
7
  template operator D&(); // { dg-message "template conversion" }
8
  operator long();
9
};
10
 
11
void f(long);
12
void f(B&);
13
 
14
struct A2 {
15
  template operator B&();
16
};
17
 
18
void f2(const B&);
19
 
20
int main() {
21
  f(A());
22
  f2(A2());
23
  f2(A());                      // { dg-error "" }
24
}

powered by: WebSVN 2.1.0

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