repo.or.cz
/
gcc.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
ipa-cp: Perform operations in the appropriate types (PR 118097)
[gcc.git]
/
gcc
/
testsuite
/
g++.dg
/
template
/
access36.C
blob
72ca23c7017b1b76aa3f98cc0dc947513d2db83e
1
// PR c++/16617
2
3
class B
4
{
5
protected:
6
int i;
7
};
8
9
template <class T> void fr ();
10
11
class D2 : public B
12
{
13
friend void fr<int> ();
14
};
15
16
template<int B::*> struct X
17
{};
18
19
template <class T> void fr ()
20
{
21
X<&B::i> x1; // { dg-error "protected" }
22
X<&D2::i> x2; // { dg-error "protected" }
23
}
24
25
template void fr<char>();