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
PR middle-end/77674
[official-gcc.git]
/
gcc
/
testsuite
/
g++.dg
/
warn
/
Winit-self-3.C
blob
dd06ad017e96f442662e72d54d2cda4861c30bc6
1
// PR c++/64667
2
// { dg-options "-Winit-self" }
3
4
class A
5
{
6
public:
7
A(const A&) : a(a) {} // { dg-warning "initialized with itself" }
8
private:
9
int a;
10
};
11
12
class B
13
{
14
public:
15
B(const B&) : b(b) {} // { dg-warning "initialized with itself" }
16
private:
17
int* b;
18
};
19
20
class C
21
{
22
public:
23
C(const C&) : c(c) {} // { dg-warning "initialized with itself" }
24
private:
25
int& c;
26
};