Questions tagged [haskell-mode]

The haskell-mode package is a set of major modes for Emacs for writing Haskell code and working with Haskell projects.

The haskell-mode package is a set of major modes for Emacs for writing Haskell code and working with Haskell projects.

See https://github.com/haskell/haskell-mode

62 questions
0
votes
1 answer

Haskell files are not recognize by `haskell-mode`

I am fairly new to Emacs - transitioning from Neovim. I have the following line in my config file: (use-package haskell-mode) When I open any Haskell file, I see no effect, e.g., no syntax highlighting and in the lower right corner it says my major…
Refael Sheinker
  • 713
  • 7
  • 20
0
votes
1 answer

How to print the constructors of a type in GHCi?

Using :t I can print the type of an expression. But how do I see the constructors of that type? Also is there a shortcut for this in Haskell mode for emacs? This seems like a basic thing, but I can't find it. Maybe I'm just searching the wrong…
0
votes
1 answer

eldoc mode hangs emacs when fetching information to show in echo

I am fairly new to emacs and have been using Haskell mode and writing .hs scripts in emacs. I have noticed that it freezes whilst fetching information to show in the echo bar. Disabling global-eldoc-mode seems to fix this. I am sure this is not a…
Croote
  • 1,382
  • 1
  • 7
  • 15
0
votes
0 answers

Haskell autocompletion with general info and documentation in Emacs

I recently started learning Haskell and switched over to Emacs as well. I've installed haskell-mode. This is what my haskell section in my .emacs file looks like 79 (add-hook 'haskell-mode-hook 'font-lock-mode) …
atis
  • 881
  • 5
  • 22
0
votes
2 answers

Emacs haskell intero mode, import could not find module

Edit: this error occurs only when using emacs haskell mode and intero mode (C-c C-l to load into ghci). It works in command line using stack ghc Log.hs LogAnalysis.hs. I'm learning Haskell through CIS 194 (Spring 2013), and am running into this…
timokratia
  • 85
  • 1
  • 8
0
votes
0 answers

Setting up Emacs for Haskell development fights with Evil-mode

I've recently switched from vim to emacs using evil mode and while coding with clojure has been a pleasure, I've found out that the haskell environment doesn't cope well with evil-mode... in particular, the "o", "O" and "RET" (while in insert mode)…
Dr_Benway
  • 61
  • 5
0
votes
1 answer

Emacs haskell-mode: "Searching for program: no such file or directory, ghci"

For some reason emacs is not able to find my ghci. I am running Ubuntu 16.04, and followed the instructions in this tutorial to the book. Using which ghci I get the path /opt/ghc/7.10.3/bin/ghci. And executing M-: exec-path and M-: (getenv "PATH") I…
JasoonS
  • 1,432
  • 3
  • 13
  • 26
0
votes
1 answer

How do you get Emacs haskell-mode to find modules in other hs-source-dirs?

UPDATE: clarified that this is on Mac OS X I'm using Emacs Prelude (which uses haskell-mode) on Mac OS X and I've created a project with stack new hello. The project it generates is like…
Alain O'Dea
  • 21,033
  • 1
  • 58
  • 84
0
votes
0 answers

QuickCheck together with haskell-mode in emacs, ^H

When using QuickCheck together with haskell-mode in emacs, the output starts with (continuing up to the default of 100 tests): (0 tests)^H^H^H^H^H^H^H^H^H ^H^H^H^H^H^H^H^H^H(1 test) where ^H (Control H) is the UNIX terminal representation…
hkBst
  • 2,818
  • 10
  • 29
0
votes
1 answer

develop Haskell code with vim and haskelmode plugin

I have a silly question, I'm sure, I use vim with haskell-mode plugin to develop on haskell but I'm not sure how to enable the keys combination define on the haskellmode -vim, for example: |_ct| create |tags| file |_si| show info for id under…
srncristea
  • 121
  • 1
  • 8
0
votes
1 answer

Installing ghc-mod from melpa: Error during download request

I am following the instructions here to install ghc-mod in Emacs. I can add the melpa repos and list packages with M-x package-list-packages, then when I go to install the ghc package, this happens: Debugger entered--Lisp error: (error "Error during…
jaybee
  • 1,897
  • 2
  • 16
  • 29
0
votes
1 answer

Emacs init file cannot open load file OS X

I am trying to add haskell-mode to emacs, but I run into the error: cannot open load file. This is what I've done... First I downloaded the tar file for haskell-mode version 2.4 from here : http://projects.haskell.org/haskellmode-emacs/ After doing…
buydadip
  • 8,890
  • 22
  • 79
  • 154
0
votes
1 answer

Activate highlight code in haskell mode

I installed haskell-mode in order to have highlighted code when editing *.hs files. I have added the following line to my init.el file: (load "/usr/share/emacs/site-lisp/haskell-mode/haskell-package.el") As it can be understand from the manual…
user2820579
  • 3,261
  • 7
  • 30
  • 45
0
votes
2 answers

Some shortcuts don't work on emacs beginning with C-c

In Haskell-mode, the shortcut C-c C-= is defined to do something. Trying this shortcut, I realized that emacs do not recognize the shortcut C-c C-=. Indeed, when I try the shortcut on emacs, the buffer write C-c = is not defined although I pressed…
Saroupille
  • 609
  • 8
  • 14
0
votes
1 answer

Sum up distances of a permutation list (Haskell)

I have a list of Towns and a function, which gives out the distance between two of them. For example: dist!(Bielefeld,Muenchen) = 598 Now I want to make a function where I can calculate the full length of a random tour between all Towns. For…
haskellnoob
  • 211
  • 3
  • 13