www.delorie.com/gnu/docs/elisp-manual-21/elisp_120.html   search  
 
Buy the book!


GNU Emacs Lisp Reference Manual

[ < ] [ > ]   [ << ] [ Up ] [ >> ]         [Top] [Contents] [Index] [ ? ]

9.2.7 Special Forms

A special form is a primitive function specially marked so that its arguments are not all evaluated. Most special forms define control structures or perform variable bindings--things which functions cannot do.

Each special form has its own rules for which arguments are evaluated and which are used without evaluation. Whether a particular argument is evaluated may depend on the results of evaluating other arguments.

Here is a list, in alphabetical order, of all of the special forms in Emacs Lisp with a reference to where each is described.

and
see section 10.3 Constructs for Combining Conditions

catch
see section 10.5.1 Explicit Nonlocal Exits: catch and throw

cond
see section 10.2 Conditionals

condition-case
see section 10.5.3.3 Writing Code to Handle Errors

defconst
see section 11.5 Defining Global Variables

defmacro
see section 13.4 Defining Macros

defun
see section 12.4 Defining Functions

defvar
see section 11.5 Defining Global Variables

function
see section 12.7 Anonymous Functions

if
see section 10.2 Conditionals

interactive
see section 21.3 Interactive Call

let
let*
see section 11.3 Local Variables

or
see section 10.3 Constructs for Combining Conditions

prog1
prog2
progn
see section 10.1 Sequencing

quote
see section 9.3 Quoting

save-current-buffer
see section 27.2 The Current Buffer

save-excursion
see section 30.3 Excursions

save-restriction
see section 30.4 Narrowing

save-window-excursion
see section 28.17 Window Configurations

setq
see section 11.8 How to Alter a Variable Value

setq-default
see section 11.10.2 Creating and Deleting Buffer-Local Bindings

track-mouse
see section 29.13 Mouse Tracking

unwind-protect
see section 10.5 Nonlocal Exits

while
see section 10.4 Iteration

with-output-to-temp-buffer
see section 38.8 Temporary Displays

Common Lisp note: Here are some comparisons of special forms in GNU Emacs Lisp and Common Lisp. setq, if, and catch are special forms in both Emacs Lisp and Common Lisp. defun is a special form in Emacs Lisp, but a macro in Common Lisp. save-excursion is a special form in Emacs Lisp, but doesn't exist in Common Lisp. throw is a special form in Common Lisp (because it must be able to throw multiple values), but it is a function in Emacs Lisp (which doesn't have multiple values).


[ < ] [ > ]   [ << ] [ Up ] [ >> ]         [Top] [Contents] [Index] [ ? ]

  webmaster   donations   bookstore     delorie software   privacy  
  Copyright 2003   by The Free Software Foundation     Updated Jun 2003