[LLVMbugs] [Bug 14971] New: Warn on = vs == typos in more contexts

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Wed Jan 16 16:27:41 PST 2013


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

             Bug #: 14971
           Summary: Warn on = vs == typos in more contexts
           Product: clang
           Version: trunk
          Platform: PC
        OS/Version: Linux
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: Frontend
        AssignedTo: unassignedclangbugs at nondot.org
        ReportedBy: matthewbg at google.com
                CC: llvmbugs at cs.uiuc.edu
    Classification: Unclassified


Clang just failed to catch this bug, but fortunately GCC spotted it:

     friend bool operator==(filtered_category_iterator X,
                            filtered_category_iterator Y) {
       return X.Current = Y.Current;
     }

Our -Wparentheses catches this in the condition of an if statement, but
apparently not other boolean contexts.

-- 
Configure bugmail: http://llvm.org/bugs/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.



More information about the llvm-bugs mailing list