Package: haskell-mode
Version: 2.1-1
Severity: normal
If I open up a new emacs session and try to load a file into ghci (via
turn-on-haskell-ghci and C-c C-l) I get an error message about a
missing keymap:
------------------------------------------------------------
Debugger entered--Lisp error: (void-variable haskell-ghci-mode-map)
(if haskell-ghci-mode-map nil (setq haskell-ghci-mode-map (copy-keymap
comint-mode-map)))
haskell-ghci-mode()
haskell-ghci-start-process(nil)
(if (and haskell-ghci-process-buffer (eq ... ...)) (set-buffer
haskell-ghci-process-buffer) (haskell-ghci-start-process nil))
(let ((file ...) (dir ...) (cmd ...)) (if (and haskell-ghci-process-buffer
...) (set-buffer haskell-ghci-process-buffer) (haskell-ghci-start-process nil))
(if cd (haskell-ghci-send ...)) (haskell-ghci-wait-for-output)
(haskell-ghci-send load-command file) (setq haskell-ghci-load-end
(marker-position comint-last-input-end)) (setq haskell-ghci-error-pos
haskell-ghci-load-end) (if cmd (haskell-ghci-send cmd))
(haskell-ghci-wait-for-output))
haskell-ghci-go(":load " nil)
(save-excursion (haskell-ghci-go cmd cd))
haskell-ghci-gen-load-file(":load " nil)
haskell-ghci-load-file(nil)
call-interactively(haskell-ghci-load-file)
------------------------------------------------------------
The problem is that comint needs to be loaded before using its
keymap. I fixed this by adding a (require 'comint) a little before
this line (patch attached).
I don't know why the call to (comint-mode) just above doesn't fail
(there's no autoload by default for comint-mode on my emacs, the
emacs-snapshot-gtk listed below).
Presumably the same thing would happen with hugs.
Peace,
Dylan Thurston
-- System Information:
Debian Release: testing/unstable
APT prefers unstable
APT policy: (500, 'unstable'), (500, 'testing')
Architecture: i386 (i686)
Shell: /bin/sh linked to /bin/bash
Kernel: Linux 2.6.17-rc5
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8)
Versions of packages haskell-mode depends on:
ii emacs-snapshot [emacsen] 1:20060524-1 The GNU Emacs editor (development
ii emacs-snapshot-gtk [emacsen 1:20060524-1 The GNU Emacs editor (with GTK+ 2.
ii emacs21 [emacsen] 21.4a-6 The GNU Emacs editor
ii xemacs21 21.4.19-1 highly customizable text editor
ii xemacs21-mule [xemacs21] 21.4.19-1 highly customizable text editor --
haskell-mode recommends no packages.
-- no debconf information
--- haskell-ghci.el 2006-06-02 02:33:09.000000000 -0400
+++ /usr/share/emacs/site-lisp/haskell-mode/haskell-ghci.el 2005-11-17
02:03:13.000000000 -0500
@@ -114,7 +114,6 @@
\\[comint-interrupt-subjob] interrupts the comint or its current subjob if any.
\\[comint-stop-subjob] stops, likewise. \\[comint-quit-subjob] sends quit
signal."
(interactive)
- (require 'comint)
(comint-mode)
(setq major-mode 'haskell-ghci-mode)
(setq mode-name "Haskell GHCi")