[PATCH] D45069: [clangd] synthesize fix message when the diagnostic doesn't provide one.

Sam McCall via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Thu Mar 29 16:18:14 PDT 2018


sammccall created this revision.
sammccall added a reviewer: ilya-biryukov.
Herald added subscribers: cfe-commits, MaskRay, ioeric, jkorous-apple, klimek.

Currently if a fix is attached directly to a diagnostic, we repeat the
diagnostic message as the fix message. From eyeballing the top diagnostics,
it seems describing the textual replacement would be much clearer.

e.g.
error: use of undeclared identifier 'goo'; did you mean 'foo'?
action before: use of undeclared identifier 'goo'; did you mean 'foo'?
action after: change 'goo' to 'foo'


Repository:
  rCTE Clang Tools Extra

https://reviews.llvm.org/D45069

Files:
  clangd/Diagnostics.cpp
  unittests/clangd/ClangdUnitTests.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D45069.140357.patch
Type: text/x-patch
Size: 4984 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20180329/478628f8/attachment.bin>


More information about the cfe-commits mailing list