Opened 13 years ago

Closed 12 years ago

#4043 closed Bugs (fixed)

Lambda: Right-hand-side of compound assignment operators are stored by reference

Reported by: Takano Akio <aljee@…> Owned by: No-Maintainer
Milestone: Boost 1.43.0 Component: lambda
Version: Boost 1.42.0 Severity: Problem
Keywords: Cc:

Description

In the section "Storing bound arguments in lambda functions", the document says "The left argument of compound assignment operators (+=, *=, etc.) are stored as references to non-const". However, it actually stores both arguments as a reference.

Attachments (1)

test.cpp (327 bytes ) - added by Takano Akio <aljee@…> 13 years ago.
test case

Download all attachments as: .zip

Change History (2)

by Takano Akio <aljee@…>, 13 years ago

Attachment: test.cpp added

test case

comment:1 by Jeremiah Willcock, 12 years ago

Resolution: fixed
Status: newclosed

(In [62620]) Changed compound assignment (and actually all binary operators) to copy their RHS arguments like the documentation said; added a test for this; fixes #4043

Note: See TracTickets for help on using tickets.