comparison lisp/window-xemacs.el @ 5753:dbd8305e13cb

Warn about non-string non-integer ARG to #'gensym, bytecomp.el. lisp/ChangeLog addition: 2013-08-21 Aidan Kehoe <kehoea@parhasard.net> * bytecomp.el: * bytecomp.el (gensym): * bytecomp.el (byte-compile-gensym): New. Warn that gensym called in a for-effect context is unlikely to be useful. Warn about non-string non-integer ARGs, this is incorrect. Am not changing the function to error with same, most code that makes the mistake is has no problems, which is why it has survived so long. * window-xemacs.el (save-window-excursion/mapping): * window.el (save-window-excursion): Call #'gensym with a string, not a symbol.
author Aidan Kehoe <kehoea@parhasard.net>
date Wed, 21 Aug 2013 19:02:59 +0100
parents c6b1500299a7
children
comparison
equal deleted inserted replaced
5752:70a3f4ff8da8 5753:dbd8305e13cb
353 Return alist mapping old windows to new windows. 353 Return alist mapping old windows to new windows.
354 This alist maps the originally captured windows to the windows that correspond 354 This alist maps the originally captured windows to the windows that correspond
355 to them in the restored configuration. It does not include entries for 355 to them in the restored configuration. It does not include entries for
356 windows that have not changed identity. 356 windows that have not changed identity.
357 Does not restore the value of point in current buffer." 357 Does not restore the value of point in current buffer."
358 (let ((window-config (gensym 'window-config)) 358 (let ((window-config (gensym "window-config"))
359 (mapping (gensym 'mapping))) 359 (mapping (gensym "mapping")))
360 `(let ((,window-config (current-window-configuration)) 360 `(let ((,window-config (current-window-configuration))
361 (,mapping)) 361 (,mapping))
362 (unwind-protect 362 (unwind-protect
363 (progn ,@body) 363 (progn ,@body)
364 (setq ,mapping (set-window-configuration/mapping ,window-config))) 364 (setq ,mapping (set-window-configuration/mapping ,window-config)))