[PATCH] lld] handle the case of errors from createLinkerInput

Rui Ueyama ruiu at google.com
Tue Sep 3 13:31:36 PDT 2013


  LGTM with the following change.


================
Comment at: lib/Driver/GnuLdDriver.cpp:101
@@ +100,3 @@
+  if (errorMsg.empty())
+    return "Unknown Error";
+  return std::move(errorMsg);
----------------
nit: instead of checking errorMsg.empty() we can just write it in "else". Also early return is preferred.


http://llvm-reviews.chandlerc.com/D1571



More information about the llvm-commits mailing list