Comments (14)
I was able to get things working with Chris Done's flycheck-haskell which uses ghci instead of ghc:
https://github.com/chrisdone/haskell-flycheck
I don't think this runs hlint though.
from flycheck-haskell.
@lukehoersten It chains to the built-in hlint checker, so hlint should run either way.
As for the actual issue, please show me the output of C-c ! C-c RET haskell-ghc
.
from flycheck-haskell.
13 18 error Could not find module ‘Control.Monad.Trans.Except’
Perhaps you meant
Control.Monad.Trans.Cont (from transformers-0.3.0.0)
Control.Monad.Trans.Error (from transformers-0.3.0.0)
Control.Monad.Trans.List (from transformers-0.3.0.0)
Use -v to see a list of the files searched for.... (haskell-ghc)
from flycheck-haskell.
@chrisdone and I have done some work to bring his chrisdone/haskell-flycheck#1 up to snuff. Basically modern haskell-mode
uses haskell-interactive-mode
for a REPL which is cabal repl
underneath. This unifies sandbox management etc all under one roof. With Chris' haskell-flycheck
, it actually shares that cabal repl
process for type checking etc. I really think this is the way to go for flycheck-haskell
. Also, I think it simplifies a lot of what flycheck-haskell
is doing by leveraging cabal repl
for it instead (so less for you to maintain). What do you think @lunaryorn?
from flycheck-haskell.
@lukehoersten That's the output of the error list, not of C-c ! C-c
…
With regards to haskell-flycheck: This extension does not actually implement a syntax checker. It merely configures the built-in GHC syntax checker of Flycheck accordingly.
Flycheck itself will never use Haskell Interactive Mode for syntax checking: I want no dependencies on specific 3rd party modes in Flycheck, and it's too much code for me to maintain anyway.
We could merge this extension with Chris' syntax checker, though, and distribute it as one package on MELPA.
But in any case, the standard GHC syntax checker and the functionality provided by this extension will stay. Not everyone uses Interactive Haskell Mode…
from flycheck-haskell.
- I think we can close this issue. I can't reproduce the issue with the
haskell-ghc
checker. - The
haskell-process
stuff is included inhaskell-mode
. Do you mean you don't want to depend onhaskell-mode
as a 3rd party mode?
from flycheck-haskell.
@lukehoersten Ad 1) Closing as invalid then.
Ad 2) Exactly. I do not want to depend on Emacs Lisp functionality from other modes. That'd open a kitchen sink, and amount to more code than I could reasonably maintain. For this reason, I prefer to have syntax checkers with such dependencies in external packages.
from flycheck-haskell.
OK that makes a lot of sense. Can we do what you suggested then and add the haskell-process
checker to the flycheck-haskell
package? My main motivation is to just get it into emacs package management so installation is easy and having flycheck-haskell
and haskell-flycheck
will just be confusing for new users.
from flycheck-haskell.
@lukehoersten Yes, if @chrisdone agrees.
from flycheck-haskell.
I'm okay with merging this into flycheck-haskell if it unifies a common thing and avoids confusion. I'm concerned about pissing off your users by swapping out the backend with something that requires starting a session and ghci (things that people regularly complain about as being such a chore).
from flycheck-haskell.
I was thinking flycheck-haskell
would default to it's current behavior and whether by manual config or auto-config on availability of haskell-process
, would switch from haskell-ghc
checker to haskell-process
checker. @chrisdone mentioned on IRC that this would have a conditional dependency, though, which may not be desirable. I'm not sure what's best here.
from flycheck-haskell.
@lukehoersten What do you mean with “conditional dependency”? This extension already depends on Haskell Mode.
@chrisdone With a proper predicate, Flycheck won't use the checker unless there is a session already. Is there a function that checks whether the current Haskell Mode has an interactive session attached?
from flycheck-haskell.
There's haskell-session-maybe
which returns nil
if there is no session.
from flycheck-haskell.
@chrisdone That looks like the right function to call, i.e. :predicate haskell-session-maybe
…
from flycheck-haskell.
Related Issues (20)
- flycheck-disable-checked not disabling haskell-stack-ghci HOT 6
- `flycheck-haskell-setup` signals error on Windows HOT 4
- Support for Haskell scripts made with Stack HOT 1
- Using flycheck in a docker-based stack project? HOT 1
- Bug in get-cabal-configuration.hs HOT 2
- call to stack / get-cabal-configuration delays editing file HOT 2
- IO mzero error when reading cabal configuration HOT 2
- cabal new-style builds HOT 1
- running hlint when installed using --copy-compiler-bins HOT 2
- Awkward to use without stack HOT 2
- Very bad performance HOT 4
- no errors HOT 7
- Paths_* modules cannot be found HOT 11
- Support hpack files directly HOT 3
- Flycheck with nix: Could not find module HOT 4
- Flycheck-haskell hangs indefinitely on NixOS HOT 6
- weird output from haskell-hlint checker HOT 2
- Support for cabal.project? HOT 1
- flycheck-haskell is very slow when stack.yaml is not pressent HOT 10
- Reference to Distribution.Parsec.Common needs to be updated for Cabal-3.0.0.0 HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from flycheck-haskell.