Opened 8 years ago

Closed 6 years ago

#11226 closed Bugs (fixed)

let statements fail to compile for void return types

Reported by: edaskel@… Owned by: Thomas Heller
Milestone: To Be Determined Component: phoenix
Version: Boost 1.58.0 Severity: Problem
Keywords: Cc:

Description

A let expression whose result is void will fail to compile, starting in 1.58. It appears to be related to commit b959ed0c33ef28ec978689a8b1235661fcde93fe and specifically the change from code of the form

return result-expression;

to

result_type r = result-expression; return r;

which will fail for result_type void, as assignments are not permitted.

A small test case that compiles in 1.57 but fails in 1.58 (gcc 4.8.2) is attached.

Attachments (1)

let_testcase.cpp (450 bytes ) - added by edaskel@… 8 years ago.
Test case illustrating compile failure for void result type

Download all attachments as: .zip

Change History (5)

by edaskel@…, 8 years ago

Attachment: let_testcase.cpp added

Test case illustrating compile failure for void result type

comment:1 by edaskel@…, 8 years ago

commit f63e401ea5cac691dcb91a6edaf8f92dbcaa91bc has been merged to fix this issue

comment:2 by bugs@…, 8 years ago

I think this might be related to other compilation issues that exist for some time when targetting Phoenix V3:

comment:3 by edaskel@…, 6 years ago

This bug was fixed and can be closed.

comment:4 by Kohei Takahashi, 6 years ago

Resolution: fixed
Status: newclosed
Note: See TracTickets for help on using tickets.