[PATCH] D25213: Fix PR28181: Prevent operator overloading related assertion failure crash that happens in C only

Bruno Cardoso Lopes via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed Jan 18 11:42:56 PST 2017


bruno accepted this revision.
bruno added a comment.
This revision is now accepted and ready to land.

LGTM!



================
Comment at: lib/Sema/SemaExpr.cpp:11523
     // being assigned to.
     if (Opc == BO_Assign && pty->getKind() == BuiltinType::Overload) {
+      if (getLangOpts().CPlusPlus &&
----------------
Looks like you can fold both conditions below into one and check `getLangOpts().CPlusPlus` only once


Repository:
  rL LLVM

https://reviews.llvm.org/D25213





More information about the cfe-commits mailing list