emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] Changes to emacs/lisp/net/rcompile.el,v


From: Stefan Monnier
Subject: [Emacs-diffs] Changes to emacs/lisp/net/rcompile.el,v
Date: Thu, 31 Jan 2008 15:09:21 +0000

CVSROOT:        /sources/emacs
Module name:    emacs
Changes by:     Stefan Monnier <monnier>        08/01/31 15:09:21

Index: net/rcompile.el
===================================================================
RCS file: /sources/emacs/emacs/lisp/net/rcompile.el,v
retrieving revision 1.17
retrieving revision 1.18
diff -u -b -r1.17 -r1.18
--- net/rcompile.el     8 Jan 2008 20:45:53 -0000       1.17
+++ net/rcompile.el     31 Jan 2008 15:09:19 -0000      1.18
@@ -115,25 +115,17 @@
 
 ;;;; entry point
 
-;; We use the Tramp internal functions `with-parsed-tramp-file-name'
-;; and `tramp-make-tramp-file-name'.  Better would be, if there are
-;; functions to provide user, host and localname of a remote filename,
-;; independent of Tramp's implementation.  The function calls are
-;; wrapped by `funcall' in order to pacify the byte compiler.
-;; ange-ftp check removed, because it is handled also by Tramp.
+;; We use the Tramp internal function`tramp-make-tramp-file-name'.
+;; Better would be, if there are functions to provide user, host and
+;; localname of a remote filename, independent of Tramp's implementation.
+;; The function calls are wrapped by `funcall' in order to pacify the byte
+;; compiler.  ange-ftp check removed, because it is handled also by Tramp.
 ;;;###autoload
 (defun remote-compile (host user command)
   "Compile the current buffer's directory on HOST.  Log in as USER.
 See \\[compile]."
   (interactive
-   (let ((parsed (and (featurep 'tramp)
-                     (file-remote-p default-directory)))
-         host user command prompt l l-host l-user)
-     (if parsed
-        (funcall (symbol-function 'with-parsed-tramp-file-name)
-                 default-directory l
-                 (setq host l-host
-                       user l-user))
+   (let (host user command prompt l l-host l-user)
        (setq prompt (if (stringp remote-compile-host)
                         (format "Compile on host (default %s): "
                                 remote-compile-host)
@@ -151,7 +143,7 @@
                                                  (user-login-name)))
                                             "" nil nil
                                             'remote-compile-user-history)
-                    remote-compile-user)))
+                  remote-compile-user))
      (setq command (read-from-minibuffer "Compile command: "
                                          compile-command nil nil
                                          '(compile-history . 1)))
@@ -164,8 +156,6 @@
         ((null remote-compile-user)
          (setq remote-compile-user (user-login-name))))
   (let* (localname ;; Pacify byte-compiler.
-        (parsed (and (featurep 'tramp)
-                     (file-remote-p default-directory)))
          (compile-command
           (format "%s %s -l %s \"(%scd %s; %s)\""
                  remote-shell-program
@@ -174,10 +164,7 @@
                   (if remote-compile-run-before
                       (concat remote-compile-run-before "; ")
                     "")
-                 (if parsed
-                     (funcall (symbol-function 'with-parsed-tramp-file-name)
-                              default-directory nil localname)
-                   "")
+                  ""
                   compile-command)))
     (setq remote-compile-host host)
     (save-some-buffers nil nil)
@@ -185,13 +172,13 @@
     ;; Set comint-file-name-prefix in the compilation buffer so
     ;; compilation-parse-errors will find referenced files by Tramp.
     (with-current-buffer compilation-last-buffer
-      (when (featurep 'tramp)
+      (when (fboundp 'tramp-make-tramp-file-name)
        (set (make-local-variable 'comint-file-name-prefix)
-            (funcall (symbol-function 'tramp-make-tramp-file-name)
+            (tramp-make-tramp-file-name
              nil ;; method.
              remote-compile-user
              remote-compile-host
              ""))))))
 
-;;; arch-tag: 2866a132-ece4-4ce9-9f91-ec147f803f73
+;; arch-tag: 2866a132-ece4-4ce9-9f91-ec147f803f73
 ;;; rcompile.el ends here




reply via email to

[Prev in Thread] Current Thread [Next in Thread]