[PATCH] D151575: [clang][diagnostics] Always show include stacks on errors

Erich Keane via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Jun 5 09:39:28 PDT 2023


erichkeane added a comment.

I don't have much of an opinion on the commit itself.  It seems that suppressing that include stack does at least SOME work to make our error-novels less 'War and Peace', but I don't really get the bug report well enough to know whether we should be doing this.



================
Comment at: clang/lib/Frontend/DiagnosticRenderer.cpp:175
   // Skip redundant include stacks altogether.
   if (LastIncludeLoc == IncludeLoc)
     return;
----------------
I'd probably just implement this as 

`if (Level != DiagnosticsEngine::Error && LastIncludeLoc == IncludeLoc)`, rather than the 2 + an assignment.



Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D151575/new/

https://reviews.llvm.org/D151575



More information about the cfe-commits mailing list