[PATCH] D13643: [Sema] Warn on ternary comparison

Aaron Ballman via cfe-commits cfe-commits at lists.llvm.org
Sun Nov 1 17:38:45 PST 2015

aaron.ballman added a comment.

Mostly looks good; the only thing left is a test to ensure the fixits are placing the parens in the expected location.

Comment at: lib/Sema/SemaChecking.cpp:6725
@@ -6706,1 +6724,3 @@
 static void AnalyzeComparison(Sema &S, BinaryOperator *E) {
+  // We want to do this, no matter the types
+  DiagnoseTernaryComparison(S, E);
Missing a period to end the sentence.


More information about the cfe-commits mailing list