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
fortran/openmp.cc: Fix var init and locus use to avoid uninit values [PR fortran...
[official-gcc.git]
/
gcc
/
testsuite
/
g++.dg
/
cpp1y
/
auto-fn41.C
blob
25a879da118d6223cd249e51a04f439b759a6fec
1
// PR c++/80873
2
// { dg-do compile { target c++14 } }
3
4
struct S {};
5
6
auto overloaded(S &);
7
8
template <typename T>
9
int overloaded(T &) {
10
return 0;
11
}
12
13
template <typename T>
14
auto returns_lambda(T ¶m) {
15
return [&] {
16
overloaded(param); // { dg-error "before deduction" }
17
};
18
}
19
20
int main() {
21
S s;
22
returns_lambda(s);
23
}