[PATCH] D72622: [clangd] Add a ruler after header in hover

Kadir Cetinkaya via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Tue Jan 14 02:09:59 PST 2020


kadircet added inline comments.


================
Comment at: clang-tools-extra/clangd/Hover.cpp:553
 
+  // Put a linebreak after header to increase readability.
+  Output.addRuler();
----------------
sammccall wrote:
> (When merging with D72623, I'm assuming return type will go below this line?)
yes it will


================
Comment at: clang-tools-extra/clangd/test/hover.test:12
 # CHECK-NEXT:      "kind": "plaintext",
-# CHECK-NEXT:      "value": "function foo → void\n\nvoid foo()"
+# CHECK-NEXT:      "value": "function foo → void\n\n\nvoid foo()"
 # CHECK-NEXT:    },
----------------
sammccall wrote:
> Why are we getting two blank lines here?
> 
> (I understand why this patch increases it by one, but don't understand why it was two before. Ideally I think we never want \n\n\n in plaintext)
it was two before because of extra padding around `codeblocks`.

but agreed that we shouldn't have that much spacing.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D72622





More information about the cfe-commits mailing list