Debian Codegraph @

gcc/testsuite/g++.dg/concepts/abbrev6.C

raw
1 // { dg-do compile { target concepts } }
2
3 const auto &f(auto)
4 {
5 static int n;
6 return n;
7 }
8
9 void foo()
10 {
11 f(5) = 0; // { dg-error "read-only" }
12 }