 ;;; Background Idle Timer
 ;;;
 
-(defalias 'ghc-idle-timer 'ghc-load-module-all-buffers)
-
 (provide 'ghc-comp)


(defun ghc-module-keyword (mod)
  (symbol-value (ghc-module-symbol mod)))


;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;

(ghc-defstruct buffer name file)

(defun ghc-buffer-name-file (buf)
  (ghc-make-buffer
   :name (buffer-name buf)
   :file (buffer-file-name buf)))

(defun ghc-gather-import-modules-all-buffers ()
  (let ((bufs (mapcar 'ghc-buffer-name-file (buffer-list)))
	ret file)
    (save-excursion
      (dolist (buf bufs (ghc-uniq-lol ret))
	(setq file (ghc-buffer-get-file buf))
	(when (and file (string-match "\\.hs$" file))
	  (set-buffer (ghc-buffer-get-name buf))
	  (ghc-add ret (ghc-gather-import-modules-buffer)))))))

(defun ghc-gather-import-modules-buffer ()
  (let (ret)

			"Data.Maybe"
			"System.Directory"
			"System.FilePath"
			"System.IO")))

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;;
