unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
* Moving to beginning and end of a list
@ 2009-10-22 14:51 Nordlöw
  2009-10-22 16:20 ` Pascal J. Bourguignon
  0 siblings, 1 reply; 2+ messages in thread
From: Nordlöw @ 2009-10-22 14:51 UTC (permalink / raw)
  To: help-gnu-emacs

I have found these two functions very useful especially when do lisp
hacking and designing clever macros:

(defun move-beginning-of-list ()
  "Move to beginning of list, before first element."
  (interactive)
  (while (ignore-errors (backward-sexp) t)))
(global-set-key [(meta shift ?a)] 'move-beginning-of-list)

(defun move-end-of-list ()
  "Move to end of list, after first element."
  (interactive)
  (while (ignore-errors (forward-sexp) t)))
(global-set-key [(meta shift ?e)] 'move-end-of-list)

Does Emacs contain something similar by default.

/Nordlöw


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2009-10-22 16:20 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-10-22 14:51 Moving to beginning and end of a list Nordlöw
2009-10-22 16:20 ` Pascal J. Bourguignon

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).