Mercurial > emacs
comparison lisp/net/tramp.el @ 55864:dc60eb9fbbdc
Sync with Tramp.
(tramp-let-maybe): ReportReverse args of `get'.
(tramp-let-maybe): Move to an earlier spot in the file. Patch by
Andreas Schwab.
author | Kai Großjohann <kgrossjo@eu.uu.net> |
---|---|
date | Sun, 30 May 2004 21:00:53 +0000 |
parents | 4bc6cb45c326 |
children | d863bc830907 4c90ffeb71c5 |
comparison
equal
deleted
inserted
replaced
55863:ac44232c68e1 | 55864:dc60eb9fbbdc |
---|---|
1883 | 1883 |
1884 (put 'with-parsed-tramp-file-name 'lisp-indent-function 2) | 1884 (put 'with-parsed-tramp-file-name 'lisp-indent-function 2) |
1885 ;; To be activated for debugging containing this macro | 1885 ;; To be activated for debugging containing this macro |
1886 (def-edebug-spec with-parsed-tramp-file-name t) | 1886 (def-edebug-spec with-parsed-tramp-file-name t) |
1887 | 1887 |
1888 (defmacro tramp-let-maybe (variable value &rest body) | |
1889 "Let-bind VARIABLE to VALUE in BODY, but only if VARIABLE is not obsolete. | |
1890 BODY is executed whether or not the variable is obsolete. | |
1891 The intent is to protect against `obsolete variable' warnings." | |
1892 `(if (get ',variable 'byte-obsolete-variable) | |
1893 (progn ,@body) | |
1894 (let ((,variable ,value)) | |
1895 ,@body))) | |
1896 (put 'tramp-let-maybe 'lisp-indent-function 2) | |
1897 | |
1888 ;;; Config Manipulation Functions: | 1898 ;;; Config Manipulation Functions: |
1889 | 1899 |
1890 (defun tramp-set-completion-function (method function-list) | 1900 (defun tramp-set-completion-function (method function-list) |
1891 "Sets the list of completion functions for METHOD. | 1901 "Sets the list of completion functions for METHOD. |
1892 FUNCTION-LIST is a list of entries of the form (FUNCTION FILE). | 1902 FUNCTION-LIST is a list of entries of the form (FUNCTION FILE). |
6788 (if (fboundp 'set-process-query-on-exit-flag) | 6798 (if (fboundp 'set-process-query-on-exit-flag) |
6789 (set-process-query-on-exit-flag process flag) | 6799 (set-process-query-on-exit-flag process flag) |
6790 (funcall (symbol-function 'process-kill-without-query) | 6800 (funcall (symbol-function 'process-kill-without-query) |
6791 process flag))) | 6801 process flag))) |
6792 | 6802 |
6793 (defmacro tramp-let-maybe (variable value &rest body) | |
6794 "Let-bind VARIABLE to VALUE in BODY, but only if VARIABLE is not obsolete. | |
6795 BODY is executed whether or not the variable is obsolete. | |
6796 The intent is to protect against `obsolete variable' warnings." | |
6797 `(if (get 'byte-obsolete-variable ',variable) | |
6798 (progn ,@body) | |
6799 (let ((,variable ,value)) | |
6800 ,@body))) | |
6801 (put 'tramp-let-maybe 'lisp-indent-function 2) | |
6802 | |
6803 | 6803 |
6804 ;; ------------------------------------------------------------ | 6804 ;; ------------------------------------------------------------ |
6805 ;; -- Kludges section -- | 6805 ;; -- Kludges section -- |
6806 ;; ------------------------------------------------------------ | 6806 ;; ------------------------------------------------------------ |
6807 | 6807 |