Ticket #1 (new defect)

Opened 8 years ago

Last modified 7 years ago

keep a single GHCi/GHC API session for each project

Reported by: claus Owned by: claus
Priority: major Milestone:
Component: --- Version:
Keywords: Cc:


Due to Vim not providing a standard API for keeping connections to external tool sessions running in the background (:help design-not; this is my main gripe with Vim), haskellmode currently uses tools like ghc, ghc-pkg as short-term filters.

In theory, it is possible to work around this Vim limitation, but this raises issues of portability (eg, Vim's client-server communication relies on GUI access, so it won't work in a terminal-only situation), complexity (the most promising approach would be to communicate via sockets), dependencies (several of Vim's plugin script languages support asynchronous subprocess control, but which one to depend on - python/perl/..?), and stability (Vim supports dynamic linking, so one might try to use Haskell's own facilities via FFI, but any bugs there can bring down the Vim session).

On recent machines, the short-term filter approach is just fast enough, but it is a waste, and doesn't scale to large projects (workaround: compile all modules, so only the currently edited module will need to be interpreted).

Change History

Changed 8 years ago by sol

Again (as suggested in #2) Scion may be helpful.

Changed 7 years ago by haskellmode

note to self: add IDE features (debugger integration, shell window) currently tops the Vim features vote results. If that gets implemented in a generic form, rather than yet another special purpose connections, we might be in business.

Note: See TracTickets for help on using tickets.