Open
Description
Might be related to
Your environment
Which OS do you use?
Ubuntu 22.04
Which version of GHC do you use and how did you install it?
9.10.1 from nixpkgs
How is your project built (alternative: link to the project)?
Which LSP client (editor/plugin) do you use?
I run it in VS Code with the mkhl.direnv
and haskell.haskell
extensions installed.
Which version of HLS do you use and how did you install it?
haskell-language-server version: 2.10.0.0 (GHC: 9.10.1) (PATH: /nix/store/0l89i2pwxn16lfzpi33iy5qlnnhwxjid-haskell-language-server-2.10.0.0/bin/haskell-language-server-wrapper)
Have you configured HLS in any way (especially: a hie.yaml
file)?
No
Steps to reproduce
Open VS Code in the package directory.
code hlsEvalPluginSetupDoesntImportFromLocalModule
Open src/AnotherModule.hs
in VS Code.
Click Evaluate
that appears over the line -- >>> someFunc
.
Expected behaviour
I click Evaluate for the first time and see:
-- >>> someFunc
-- "someFunc"
Actual behaviour
When I click Evaluate
for the first time, I see the following:
-- $setup
-- >>> import MyLib
attempting to use module `demo-0.1.0.0-inplace:MyLib' (**/Desktop/gh/gists/hlsEvalPluginSetupDoesntImportFromLocalModule/src/MyLib.hs) which is not loaded
-- >>> someFunc
-- Variable not in scope: someFunc
When I click Evaluate again, I see the following:
-- $setup
-- >>> import MyLib
-- >>> someFunc
-- Variable not in scope: someFunc