[PATCH] D125175: Show location info with a new line in diagnostics

Ken Matsui via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Sat May 7 12:09:58 PDT 2022


ken-matsui created this revision.
Herald added subscribers: arphaman, atanasyan, jrtc27, kbarton, nemanjai.
Herald added a project: All.
ken-matsui requested review of this revision.
Herald added subscribers: cfe-commits, sstefan1, MaskRay.
Herald added a reviewer: jdoerfert.
Herald added a project: clang.

I implemented a feature to show location info with a new line in diagnostics.
This patch intends to make diagnostics much clearer by displaying location info with a new line and putting a line break between each diagnostic.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D125175

Files:
  clang/include/clang/Basic/DiagnosticOptions.def
  clang/include/clang/Driver/Options.td
  clang/lib/Driver/ToolChains/Clang.cpp
  clang/lib/Frontend/TextDiagnostic.cpp
  clang/test/ASTMerge/category/test.m
  clang/test/ASTMerge/class-template-partial-spec/test.cpp
  clang/test/ASTMerge/class-template/test.cpp
  clang/test/ASTMerge/class/test.cpp
  clang/test/ASTMerge/enum/test.c
  clang/test/ASTMerge/function/test.c
  clang/test/ASTMerge/interface/test.m
  clang/test/ASTMerge/namespace/test.cpp
  clang/test/ASTMerge/property/test.m
  clang/test/ASTMerge/struct/test.c
  clang/test/ASTMerge/typedef/test.c
  clang/test/ASTMerge/var/test.c
  clang/test/Analysis/Checkers/WebKit/uncounted-lambda-captures.cpp
  clang/test/Analysis/cstring-ranges.c
  clang/test/Analysis/diagnostics/text-diagnostics.c
  clang/test/Analysis/virtualcall-fixits.cpp
  clang/test/ClangScanDeps/error.cpp
  clang/test/CodeCompletion/crash-skipped-bodies-template-inst.cpp
  clang/test/CodeCompletion/skip-auto-funcs.cpp
  clang/test/CodeGen/invalid_global_asm.c
  clang/test/CodeGen/mips-type-sizes-int128.c
  clang/test/CodeGen/mrtd.c
  clang/test/CodeGen/opt-record-MIR.c
  clang/test/Driver/ppc-inlineasm-sf.c
  clang/test/FixIt/fixit-eof-space.c
  clang/test/FixIt/fixit-newline-style.c
  clang/test/FixIt/no-diagnostics-fixit-info.c
  clang/test/Frontend/absolute-paths-symlinks.c
  clang/test/Frontend/absolute-paths.c
  clang/test/Frontend/arm-branch-protection-default-arch.c
  clang/test/Frontend/arm-ignore-branch-protection-option.c
  clang/test/Frontend/ir-support-errors.ll
  clang/test/Frontend/no-diagnostics-show-loc-separated.c
  clang/test/Frontend/optimization-remark-analysis.c
  clang/test/Frontend/optimization-remark-options.c
  clang/test/Frontend/rewrite-includes-conditions.c
  clang/test/Frontend/rewrite-includes.c
  clang/test/Frontend/source-col-map.c
  clang/test/Frontend/system-header-prefix.c
  clang/test/Headers/ppc-intrinsics.c
  clang/test/Index/recover-bad-code-rdar_7487294.c
  clang/test/Lexer/SourceLocationsOverflow.c
  clang/test/Lexer/builtin_redef.c
  clang/test/Lexer/header.cpp
  clang/test/Misc/attr-source-range.cpp
  clang/test/Misc/caret-diags-macros.c
  clang/test/Misc/caret-diags-multiline.cpp
  clang/test/Misc/diag-format.c
  clang/test/Misc/diag-greatergreater.cpp
  clang/test/Misc/diag-line-wrapping.cpp
  clang/test/Misc/diag-macro-backtrace.c
  clang/test/Misc/diag-macro-backtrace2.c
  clang/test/Misc/diag-null-bytes-in-line.cpp
  clang/test/Misc/diag-presumed.c
  clang/test/Misc/error-limit-multiple-notes.cpp
  clang/test/Misc/error-limit.c
  clang/test/Misc/inline-asm-clobber-warning.c
  clang/test/Misc/macro-backtrace.c
  clang/test/Misc/ppc-inline-asm-clobber-warning.c
  clang/test/Misc/reduced-diags-macros-backtrace.cpp
  clang/test/Misc/reduced-diags-macros.cpp
  clang/test/Misc/remap-file.c
  clang/test/Misc/show-diag-options.c
  clang/test/Modules/auto-import-unavailable.cpp
  clang/test/Modules/build-fail-notes.m
  clang/test/Modules/cxx20-export-import.cpp
  clang/test/Modules/cycles.c
  clang/test/Modules/diagnostics.modulemap
  clang/test/Modules/explicit-build-missing-files.cpp
  clang/test/Modules/export_as_test.c
  clang/test/Modules/incomplete-umbrella.m
  clang/test/Modules/load_failure.c
  clang/test/Modules/malformed.cpp
  clang/test/Modules/missing-header.m
  clang/test/Modules/recursive.c
  clang/test/OpenMP/crash-skipped-bodies-template-inst.cpp
  clang/test/PCH/line-directive-nofilename.c
  clang/test/Preprocessor/expr_invalid_tok.c
  clang/test/Preprocessor/line-directive.c
  clang/test/Preprocessor/macro_arg_slocentry_merge.c
  clang/test/Preprocessor/ucn-pp-identifier.c
  clang/test/Refactor/LocalRename/NoSymbolSelectedError.cpp
  clang/test/Sema/pr32985.c
  clang/test/Sema/uninit-det-order.c
  clang/test/Sema/warn-logical-not-compare.c
  clang/test/Sema/warn-unused-parameters.c
  clang/test/SemaCXX/ambiguous-conversion-show-overload.cpp
  clang/test/SemaCXX/constexpr-backtrace-limit.cpp
  clang/test/SemaCXX/warn-logical-not-compare.cpp
  clang/test/SemaObjC/warn-missing-super.m
  clang/test/SemaObjC/warn-retain-block-property.m
  clang/test/Tooling/clang-check-fixit.cpp
  clang/test/VFS/external-names.c
  clang/test/VFS/relative-path-errors.c
  clang/unittests/Frontend/TextDiagnosticTest.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D125175.427886.patch
Type: text/x-patch
Size: 124712 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20220507/7e319cfd/attachment-0001.bin>


More information about the cfe-commits mailing list