-
-
Notifications
You must be signed in to change notification settings - Fork 367
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Inline function with guard only pick first guard case #4374
Comments
Hi, thanks for the bug report! Iirc, this feature is implemented by |
I manually test it in retrie, It is retrie's problem. |
Issue created in retire facebookincubator/retrie#71 |
Thank you for the test with retrie |
Given that retrie is apparently not being actively maintained, perhaps we should deprecate the retrie plugin? |
Yes, for sure. However, the fold / unfold (e.g. replace symbol by implementation) is part of our refactoring logic (we export "deprecated" pattern synonyms and "smart constructor" and ask our (internal) users to just unfold at call site using the code action. This thing is a terrific quality of life tool. Do you think a subset of edit I really have the feeling that I'm programming with "The Rocq Prover" in my haskell editor and that's something which makes me like my job ;) |
I mean, we don't need to take it out urgently, perhaps |
Your environment
Which OS do you use? Linux
Which version of GHC do you use and how did you install it?
Tested with ghc 9.6.5 and 9.8.2 installed with nix.
How is your project built (alternative: link to the project)?
Single file
Which LSP client (editor/plugin) do you use?
neovim + neovim-lsp
Which version of HLS do you use and how did you install it?
2.9.0.0 installed from nixpkgs.
Have you configured HLS in any way (especially: a
hie.yaml
file)?No hie file, single file support
Steps to reproduce
The following file:
The code action on the
foo
call, calledinline foo
Expected behaviour
foo
(inbar
)should be replaced by equivalent piece of code, so I assume something like:(or something equivalent).
Actual behaviour
Looks like only the first case of
foo
implementation is taken into account, and hence, I get:See for yourself:
hls_inline_bug.mp4
Debug information
The text was updated successfully, but these errors were encountered: