In Lisp or Scheme buffers it is possible to evaluate a single expression by pressing C-x C-e which calls eval-last-sexp
. But eval-last-sexp
works only for literals in Haskell. What is the equivalent way to do the same in the Haskell mode?
Asked
Active
Viewed 973 times
7

ceving
- 21,900
- 13
- 104
- 178
-
1In fact, `eval-last-sexp` does not work with Haskell mode at all. If it appears to be working with a literal, it is because that the literal syntax is similar in Haskell and in Lisp. – Tsuyoshi Ito Jun 20 '11 at 12:49
1 Answers
1
eval-last-sexp
is a command from emacs-lisp-mode
, and has no bearing on Haskell Mode which is presumably what you want.
If you've correctly set up inf-haskell.el, then C-c C-i
will bring up a ghci
session with your current buffer interpreted.

Raeez
- 2,423
- 15
- 12
-
2I have the mode already installed and I want to evaluate a single expression not the buffer. – ceving Jun 25 '11 at 18:03