From ae22ff40d417199d1b639bc76bb891d162a2ca12 Mon Sep 17 00:00:00 2001 From: Kazu Yamamoto Date: Wed, 17 Nov 2010 14:41:38 +0900 Subject: [PATCH] current dir hack for ghc-info.el. --- elisp/ghc-info.el | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/elisp/ghc-info.el b/elisp/ghc-info.el index 8dac464..2b9afb3 100644 --- a/elisp/ghc-info.el +++ b/elisp/ghc-info.el @@ -16,8 +16,10 @@ (message "%s not found" ghc-module-command) (let* ((expr0 (thing-at-point 'symbol)) (expr (if ask (ghc-read-expression expr0) expr0)) + (cdir default-directory) (file (buffer-name))) (with-temp-buffer + (cd cdir) (call-process ghc-module-command nil t nil "type" file expr) (message (buffer-substring (point-min) (1- (point-max)))))))) @@ -27,12 +29,14 @@ (message "%s not found" ghc-module-command) (let* ((expr0 (thing-at-point 'symbol)) (expr (if ask (ghc-read-expression expr0) expr0)) + (cdir default-directory) (file (buffer-name)) (buf (get-buffer-create ghc-error-buffer-name))) (with-current-buffer buf (erase-buffer) (insert (with-temp-buffer + (cd cdir) (call-process ghc-module-command nil t nil "info" file expr) (buffer-substring (point-min) (1- (point-max)))))) (display-buffer buf))))