lsp-inlayhints.nvim
lsp-inlayhints.nvim copied to clipboard
Inlay Hints style like JetBrains Soft
is there any options can make inlay hints like jetbrains intelij stuff? like in C programming
printf("Hello") will become printf(_Format:
"Hello")
Btw how to remove the bracket like ( )
around the inlay hints....
is there any options can make inlay hints like jetbrains intelij stuff? like in C programming printf("Hello") will become printf(
_Format:
"Hello")
We're blocked by anticonceal.
Btw how to remove the bracket like
( )
around the inlay hints....
I'll think about it, do note that this makes easier to differentiate between hints. See also https://github.com/lvimuser/lsp-inlayhints.nvim/pull/13#issuecomment-1221409211.
This is now possible on https://github.com/neovim/neovim/pull/20130 Work will be going on the anticonceal branch.
bravo!!!
I got the error today by using the branch mentioned:

I got the error today by using the branch mentioned:
The PR hasn't landed yet, you have to build neovim from source and manually apply the patch.
actually I'm pulling the latest source code from vim repo and built on myself.
actually I'm pulling the latest source code from vim repo and built on myself.
Did you also apply the patch?
wget https://patch-diff.githubusercontent.com/raw/neovim/neovim/pull/20130.patch && git apply 20130.patch
actually I'm pulling the latest source code from vim repo and built on myself.
Did you also apply the patch?
wget https://patch-diff.githubusercontent.com/raw/neovim/neovim/pull/20130.patch && git apply 20130.patch
It works like charm!! Thanks!

With clangd, I observe that in the case of nested function call, I see that only inner call has inlay-hints and not the outer call.
Can this be neovim/treesitter/LSP
issue? Can this be address in this plugin?
With clangd, I observe that in the case of nested function call, I see that only inner call has inlay-hints and not the outer call. Can this be
neovim/treesitter/LSP
issue? Can this be address in this plugin?
Try https://github.com/lvimuser/lsp-inlayhints.nvim/issues/11#issuecomment-1218269707 on the given range and check the output.
applying the patch on current neovim results in errors, I tried to merge it but get errors on compiling
Awesome, works for me! Looks essentially the same as vscode's inlay hints now. I did have to fix one thing when patching though: the patch includes a call to nonexistent macro STRLEN
at src/nvim/drawline.c:1649
. I changed that to strlen
, and it compiled just fine.
Awesome, works for me! Looks essentially the same as vscode's inlay hints now. I did have to fix one thing when patching though: the patch includes a call to nonexistent macro
STRLEN
atsrc/nvim/drawline.c:1649
. I changed that tostrlen
, and it compiled just fine.
Hello @willothy , could you please give a sh script from compelling vim to applying the patch ... I'm quite not familiar with the setup ... much appreciated ..
@zsmatrix62 Sure! Here's what I did. If you don't want to do it yourself, the "active" branch in my neovim fork is already patched if you just want to clone that.
#!/bin/sh
# Ensure you have basic C tools installed (make, cmake, gcc, etc.)
# Ensure you have the github CLI installed
# clone the neovim repo
gh repo clone neovim/neovim # or git clone [email protected]:neovim/neovim.git
# cd into project root
cd neovim
# checkout the patch PR
gh pr checkout 20130 # or git checkout a59e09c
# create a new branch with the patch
git checkout -b patch-20130
# checkout the latest nightly neovim
git checkout nightly
# merge the changes from the patch branch
git merge patch-20130
# fix any merge conflicts
# there should only be some in src/nvim/drawline.c and some in test/functional/ui/decorations_spec.lua
# accept incoming (patch-20130) changes in drawline.c
# accept HEAD (nightly) changes in test/functional/ui/decorations_spec.lua
# before you commit the merge
# go to src/nvim/drawline.c in your editor, find line 1649.
# It should look like this:
# n_extra = (int)STRLEN(p_extra);
# change it to this:
# n_extra = (int)strlen(p_extra);
# commit the changes
git add src/nvim/drawline.c
git add test/functional/ui/decorations_spec.lua
git commit -m "Merge inline hints patch"
# Build neovim
make CMAKE_BUILD_TYPE=RelWithDebInfo
sudo make install
@zsmatrix62 Sure! Here's what I did. If you don't want to do it yourself, the "active" branch in my neovim fork is already patched if you just want to clone that.
#!/bin/sh # Ensure you have basic C tools installed (make, cmake, gcc, etc.) # Ensure you have the github CLI installed # clone the neovim repo gh repo clone neovim/neovim # or git clone [email protected]:neovim/neovim.git # cd into project root cd neovim # checkout the patch PR gh pr checkout 20130 # or git checkout a59e09c # create a new branch with the patch git checkout -b patch-20130 # checkout the latest nightly neovim git checkout nightly # merge the changes from the patch branch git merge patch-20130 # fix any merge conflicts # there should only be some in src/nvim/drawline.c and some in test/functional/ui/decorations_spec.lua # accept incoming (patch-20130) changes in drawline.c # accept HEAD (nightly) changes in test/functional/ui/decorations_spec.lua # before you commit the merge # go to src/nvim/drawline.c in your editor, find line 1649. # It should look like this: # n_extra = (int)STRLEN(p_extra); # change it to this: # n_extra = (int)strlen(p_extra); # commit the changes git add src/nvim/drawline.c git add test/functional/ui/decorations_spec.lua git commit -m "Merge inline hints patch" # Build neovim make CMAKE_BUILD_TYPE=RelWithDebInfo sudo make install
Fantastic!thanks!
closing in favor of #46