|
From: | Lars Ingebrigtsen |
Subject: | bug#18522: 24.4.50; mapcar is very slow |
Date: | Mon, 29 Feb 2016 13:21:50 +1100 |
User-agent: | Gnus/5.13 (Gnus v5.13) Emacs/25.1.50 (gnu/linux) |
Peter Münster <pmlists@free.fr> writes: > And then I have to stop it with C-g because it hangs... Probably a circular list somewhere. Try the following: (let ((table (make-hash-table :test 'eq))) (mapatoms (lambda (symbol) (when (boundp symbol) (let ((value (symbol-value symbol))) (while (and (consp value) (not (gethash value table))) (let ((elem (car value))) (when (bufferp elem) (message "%s has a buffer %s" symbol (buffer-name elem)))) (setf (gethash value table) t) (setq value (cdr value)))))) obarray)) -- (domestic pets only, the antidote for overdose, milk.) bloggy blog: http://lars.ingebrigtsen.no
[Prev in Thread] | Current Thread | [Next in Thread] |