tahonermann added a comment. Hmm, it seems exceptionally unlikely for a move assignment operator to be invoked on an object with itself as the source argument. That would require an explicit use of `std::move()` as in:
Value x = ...; x = std::move(x); Rather than protecting against that and making it a no-opt, I think we would want to be informed of code that manages to do so because it is probably not intended. We could instead `assert(this !=RHS)`, but I'm not sure that is warranted either. I'm assuming this patch was made in response to a static analysis report. If so, I suggest we follow up with the static analysis vendor. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D155776/new/ https://reviews.llvm.org/D155776 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits