| Summary: | Parser gives error for initializer-list return | ||
|---|---|---|---|
| Product: | [Tools] CDT | Reporter: | Nathan Ridge <zeratul976> |
| Component: | cdt-codan | Assignee: | CDT Codan Inbox <cdt-codan-inbox> |
| Status: | CLOSED DUPLICATE | QA Contact: | Elena Laskavaia <elaskavaia.cdt> |
| Severity: | normal | ||
| Priority: | P3 | CC: | cdtdoug, malaperle |
| Version: | 8.0 | ||
| Target Milestone: | --- | ||
| Hardware: | All | ||
| OS: | All | ||
| Whiteboard: | |||
This was fixed in 8.0.1 and master > 20110715, see bug 333599. *** This bug has been marked as a duplicate of bug 333599 *** |
The parser gives the error "Return without value, in function returning non-void" for the following code: struct S { int a; double b; }; S foo() { return {0, 0.0}; // ERROR HERE } This is valid C++0x and is accepted by gcc since version 4.4.