[PATCH] D45685: [Sema] Add -wtest global flag that silences -Wself-assign for overloaded operators.

Arthur O'Dwyer via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Apr 16 11:10:24 PDT 2018


Quuxplusone added a comment.

I don't understand the spelling of this option. You spell it `-wtest` (because rjmccall suggested that spelling); but for my money it should be spelled `-Wno-self-assign-nonfield`.
Also, if you go this route, you miss the true positive reported by someone on the other patch, where the self-assignment involved a local variable named `color`.
Sorry I can't find the example right now. You'd have to trawl through all the patches opened on this subject in the past couple of weeks.


Repository:
  rC Clang

https://reviews.llvm.org/D45685





More information about the cfe-commits mailing list