This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/50025] C++0x initialization syntax doesn't work for class members of reference type
- From: "redi at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Tue, 16 Aug 2011 16:21:37 +0000
- Subject: [Bug c++/50025] C++0x initialization syntax doesn't work for class members of reference type
- Auto-submitted: auto-generated
- References: <bug-50025-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=50025
--- Comment #4 from Jonathan Wakely <redi at gcc dot gnu.org> 2011-08-16 16:21:37 UTC ---
sorry, I meant bullets 5 and 6 in paragraph 3
the 5th bullet applies before the 6th one, and that says for a reference type a
temporary is created. The 6th bullet is never reached for references.
Your example with int& works because GCC doesn't implement the FDIS wording
yet, according to the FDIS it should be rejected too, see
http://gcc.gnu.org/ml/gcc-help/2011-07/msg00053.html
this is a wording problem in the FDIS and will be core issue 1288 in the next
issues list