bug-gnu-emacs
[Top][All Lists]
Advanced

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

bug#11934: 24.1; provide variable for pp.el to control max display width


From: Lars Ingebrigtsen
Subject: bug#11934: 24.1; provide variable for pp.el to control max display width
Date: Fri, 29 Apr 2016 16:24:01 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/25.1.50 (gnu/linux)

Michael Heerdegen <michael_heerdegen@web.de> writes:

> But of course handling this problem is not trivial: we can't distinguish
> "simple lists" from code, and what might look good for the first might
> look weird for a macro call with a special lisp-indent-function value
> (e.g. imagine a `defun' call with a line break inserted just after
> "defun").

Well, pp isn't really designed for handling code.  I pp'd a function at
random...  it may be pretty, but it sure is unusual for code...

So I don't really think that's a consideration here.

(defun menu-bar-buffer-vector
    (alist)
  (let
      ((buffers-vec
        (make-vector
         (length alist)
         nil))
       (i
        (length alist)))
    (dolist
        (pair alist)
      (setq i
            (1- i))
      (aset buffers-vec i
            (cons
             (car pair)
             `(lambda nil
                (interactive)
                (funcall menu-bar-select-buffer-function ,(cdr pair))))))
    buffers-vec))

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no





reply via email to

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