Open weakit opened 11 months ago
Hi, thank you for the bug report!
Is this happening on a plain .hs
file? I can not reproduce on linux :/
I created the file Main.hs
:
sieve = sx [2..]
where
sx (p:xs) = p : sx [x|x <- xs, x `mod` p > 0]
main = do
print (take 10000 sieve)
And all these commands
ghcup run --ghc 9.0.2 --hls 2.4.0.0 -- haskell-language-server-9.0.2 Main.hs
ghcup run --ghc 9.4.7 --hls 2.4.0.0 -- haskell-language-server-9.4.7 Main.hs
ghcup run --ghc 9.6.3 --hls 2.5.0.0 -- haskell-language-server-9.6.3 Main.hs
complete successfully for me.
Yup. Simple .hs file.
I just installed Haskell, and then wanted to test it out with a very simple program and that's what I did.
Please let me know if there's any information I can help you with.
The information from the issue template would be helpful! Please provide the output of haskell-language-server-wrapper --debug primes.hs
, executed in the terminal.
If you use vscode-haskell, you may also follow the steps described here: https://github.com/haskell/vscode-haskell#investigating-and-reporting-problems
the syntax color part.
Seems the do
is missing color.
It should be syntax highlighting problem.
Since HLS does not provide the syntax highlighting, it is not a problem related to HLS.
here: https://github.com/JustusAdam/language-haskell.git
the format part
Error condition, please check your setup and/or the [issue tracker](https://github.com/haskell/haskell-language-server/issues): ormolu: Internal Error: ormoluCmd: OrmoluParsingFailed (RealSrcSpan SrcSpanMultiLine "/Users/ares/src/extend-property/hls-plugin-api/test/Ide/PluginUtilsTest.hs" 204 27 208 1 Nothing) "[GHC-21231] unterminated quasiquotation at end of input"
Considered a ormolu
bug?
Environment
Everything is installed from ghcup on Windows. I am using the VSCode plugin.
Steps to reproduce
I have this simple script in primes.hs
Expected behaviour
No errors, correct syntax highlighting,
Actual behaviour
Syntax highlighting doesn't seem to work correctly.
And this error on trying to format the code in Visual Studio code
Debug Information
Unsure if this is supposed to belong here, but I'm opening this issue.
Adding spaces between
x|x
seems to resolve the issue.