diff options
author | Vibhav Pant <vibhavp@gmail.com> | 2017-12-02 11:08:34 +0530 |
---|---|---|
committer | Vibhav Pant <vibhavp@gmail.com> | 2017-12-02 11:08:34 +0530 |
commit | 4856ee17175a80dc105e060c1184d3b3df07e1cf (patch) | |
tree | 32116db93716853a590e8c90f1fb2a2a94b5ad05 /lisp | |
parent | 0b6f4f2c6086a04b27d87d4f06b71334da3933d5 (diff) | |
download | emacs-4856ee17175a80dc105e060c1184d3b3df07e1cf.tar.gz |
lisp/erc/erc.el: Use inline-letevals for when args are buffer local.
* lisp/erc/erc.el: (erc-get-server-user, erc-add-server-user,
erc-remove-server-user): Use inline-letevals for when the arguments
refer to buffer-local variables.
Diffstat (limited to 'lisp')
-rw-r--r-- | lisp/erc/erc.el | 19 |
1 files changed, 11 insertions, 8 deletions
diff --git a/lisp/erc/erc.el b/lisp/erc/erc.el index 9b4c6ac48a3..eee79464a9a 100644 --- a/lisp/erc/erc.el +++ b/lisp/erc/erc.el @@ -409,16 +409,18 @@ in the current buffer's `erc-channel-users' hash table." (define-inline erc-get-server-user (nick) "Find the USER corresponding to NICK in the current server's `erc-server-users' hash table." - (inline-quote (erc-with-server-buffer - (gethash (erc-downcase ,nick) erc-server-users)))) + (inline-letevals (nick) + (inline-quote (erc-with-server-buffer + (gethash (erc-downcase ,nick) erc-server-users))))) (define-inline erc-add-server-user (nick user) "This function is for internal use only. Adds USER with nickname NICK to the `erc-server-users' hash table." - (inline-quote - (erc-with-server-buffer - (puthash (erc-downcase ,nick) ,user erc-server-users)))) + (inline-letevals (nick user) + (inline-quote + (erc-with-server-buffer + (puthash (erc-downcase ,nick) ,user erc-server-users))))) (define-inline erc-remove-server-user (nick) "This function is for internal use only. @@ -428,9 +430,10 @@ hash table. This user is not removed from the `erc-channel-users' lists of other buffers. See also: `erc-remove-user'." - (inline-quote - (erc-with-server-buffer - (remhash (erc-downcase ,nick) erc-server-users)))) + (inline-letevals (nick) + (inline-quote + (erc-with-server-buffer + (remhash (erc-downcase ,nick) erc-server-users))))) (defun erc-change-user-nickname (user new-nick) "This function is for internal use only. |