[PATCH] D16564: Fix an issue where backend crashes after frontend emits an error message

Akira Hatanaka via cfe-commits cfe-commits at lists.llvm.org
Tue Jan 26 17:08:37 PST 2016


ahatanak added inline comments.

================
Comment at: lib/CodeGen/ModuleBuilder.cpp:219
@@ -211,2 +218,3 @@
+      }
     }
 
----------------
Is it possible to avoid the code duplication if the condition is inverted as shown below?

if (!Diags.hasErrorOccurred())
  // call Builder->Release()

if (!Diags.hasErrorOccurred())
  return;

// Clear Builder and reset M



http://reviews.llvm.org/D16564





More information about the cfe-commits mailing list