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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [g++.dg/] [template/] [crash72.C] - Blame information for rev 801

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

Line No. Rev Author Line
1 693 jeremybenn
// PR c++/29225
2
// { dg-do compile }
3
 
4
template  bool operator< (L x, R y);
5
struct T { int t (); };
6
class S {};
7
 
8
struct U
9
{
10
   typedef int (T::* M) ();
11
   M m;
12
 
13
   bool operator() (S &x)
14
   {
15
     T a;
16
     return (a.*m) < x; // { dg-error "invalid use of non-static member" }
17
   }
18
};
19
 
20
void foo (S &x)
21
{
22
  U m;
23
  m.m = &T::t;
24
  m (x);
25
}

powered by: WebSVN 2.1.0

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