repo.or.cz
/
official-gcc.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
Dead
[official-gcc.git]
/
gomp-20050608-branch
/
gcc
/
testsuite
/
g++.old-deja
/
g++.ns
/
koenig3.C
blob
58b1d571efc033c579d8688402b8e0d421824a32
1
// { dg-do run }
2
//Check association of member pointer in overload resolution.
3
struct A {
4
int m_val;
5
friend int operator ->* (A & other, int A::*pm)
6
{ return 31; }
7
};
8
9
int A::*pi = & A::m_val;
10
11
int
12
main(void)
13
{
14
A c;
15
c.m_val = 42;
16
int j = c ->* pi;
17
18
if (j == 31)
19
return 0;
20
else
21
return 1;
22
}