[LLVMbugs] [Bug 16993] Assign rvalue to self

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Wed Apr 16 13:10:03 PDT 2014


http://llvm.org/bugs/show_bug.cgi?id=16993

David Rodríguez <dibeas at ieee.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|REOPENED                    |RESOLVED
         Resolution|---                         |INVALID

--- Comment #6 from David Rodríguez <dibeas at ieee.org> ---
Sorry for the confusion, I did not take into account 17.6.4.9/1, bullet 3:

- If a function argument binds to an rvalue reference parameter, the
implementation may assume that this parameter is a unique reference to this
argument.

The program calling 'a = std::move(a)' is violating the requirements placed on
programs in the standard and the behavior of the library is not guaranteed. It
could even 'assert' if it wants to.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20140416/be100ed5/attachment.html>


More information about the llvm-bugs mailing list