[PATCH] D39259: [lld] unified COFF and ELF error handling on new Common/ErrorHandler

Bob Haarman via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Oct 25 14:58:56 PDT 2017


inglorion added inline comments.


================
Comment at: lld/include/lld/Common/ErrorHandler.h:50-54
+  ErrorHandler(llvm::raw_ostream *Stream, StringRef LogName)
+      : ErrorLimitExceededMsg("too many errors emitted, stopping now (use "
+                              "-error-limit=0 to see all errors)"),
+        LogName(LogName), ErrorOS(Stream),
+        ColorDiagnostics(Stream->has_colors()) {}
----------------
ruiu wrote:
> inglorion wrote:
> > ruiu wrote:
> > > I believe you are not using this ctor.
> > The default ctor delegates to it. I suppose I could just only have a default ctor.
> Yeah, and initializing a member with an ELF-ish default value seems a bit odd if you move this file to Common directory.
Yeah. The thinking is basically that this is the common case, with the Windows variant being the odd one out, but I'm happy to do it a different way if you have suggestions. I wasn't able to think of a way I really like better.


https://reviews.llvm.org/D39259





More information about the llvm-commits mailing list