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
FSF GCC merge 02/23/03
[official-gcc.git]
/
gcc
/
testsuite
/
g++.old-deja
/
g++.jason
/
overload12.C
blob
61d3740ed4155552ae03a64fcd272bd4bede22b3
1
// PRMS Id: 4066
2
// Bug: g++ doesn't notice the const on reference returns.
3
4
struct B {
5
int foo() { return 1; }
6
int foo() const { return 0; }
7
};
8
9
B b_;
10
const B &b () { return b_; }
11
12
int main()
13
{
14
return b().foo();
15
}