better loading of symbols.
symbols of modules are loaded when a Haskell file is opened on Emacs. idle timer is still effective. M-C-e is obsoleted. M-C-m loads symbols of all un-loaded modules.
This commit is contained in:
@@ -162,6 +162,13 @@
|
||||
;;; Loading keywords
|
||||
;;;
|
||||
|
||||
(add-hook 'find-file-hook 'ghc-load-module-buffer)
|
||||
|
||||
(defun ghc-load-module-buffer ()
|
||||
(interactive)
|
||||
(when (eq major-mode 'haskell-mode)
|
||||
(mapc 'ghc-load-module (ghc-gather-import-modules-buffer))))
|
||||
|
||||
(defun ghc-load-module (mod)
|
||||
(when (and (member mod ghc-module-names)
|
||||
(not (member mod ghc-loaded-module)))
|
||||
@@ -176,11 +183,6 @@
|
||||
(uniq-sorted (sort (ghc-uniq-lol keywords) 'string<)))
|
||||
(setq ghc-merged-keyword uniq-sorted)))
|
||||
|
||||
(defun ghc-import-module ()
|
||||
(interactive)
|
||||
(ghc-load-module (ghc-read-module-name (ghc-extract-module)))
|
||||
(ghc-merge-keywords))
|
||||
|
||||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||
;;;
|
||||
;;; Background Idle Timer
|
||||
|
||||
Reference in New Issue
Block a user