This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/50025] [DR 1288] C++0x initialization syntax doesn't work for class members of reference type
- From: "ville.voutilainen at gmail dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Sat, 01 Mar 2014 11:22:39 +0000
- Subject: [Bug c++/50025] [DR 1288] C++0x initialization syntax doesn't work for class members of reference type
- Auto-submitted: auto-generated
- References: <bug-50025-4 at http dot gcc dot gnu dot org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=50025
Ville Voutilainen <ville.voutilainen at gmail dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |ville.voutilainen at gmail dot com
--- Comment #14 from Ville Voutilainen <ville.voutilainen at gmail dot com> ---
This bug seems to be fixed with the current trunk. Both the example
in the original report and similar examples compile correctly, like
std::string& f() {static std::string s; return s;}
int main()
{
std::string& ri{f()};
}
and
int& f() {static int i = 42; return i;}
int main()
{
int& ri{f()};
}
Please close as resolved.