commit | ffd79061ccfea4c884d4d2646992aa30cf6514a2 | [log] [tgz] |
---|---|---|
author | Chandler Carruth <chandlerc@gmail.com> | Tue Nov 26 00:54:44 2013 +0000 |
committer | Chandler Carruth <chandlerc@gmail.com> | Tue Nov 26 00:54:44 2013 +0000 |
tree | 820779ffbf112b404518d55f635d628001974851 | |
parent | b30824e1b97b9d2b4c8e11a5d684bef5b816b887 [diff] |
Lift self-copy protection up to the header file and add self-move protection to the same layer. This is in line with Howard's advice on how best to handle self-move assignment as he explained on SO[1]. It also ensures that implementing swap with move assignment continues to work in the case of self-swap. [1]: http://stackoverflow.com/questions/9322174/move-assignment-operator-and-if-this-rhs git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@195705 91177308-0d34-0410-b5e6-96231b3b80d8