[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] /srv/bzr/emacs/trunk r112347: * doc/lispintro/emacs-lisp-i
From: |
Xue Fuqiao |
Subject: |
[Emacs-diffs] /srv/bzr/emacs/trunk r112347: * doc/lispintro/emacs-lisp-intro.texi (defcustom, defun, simplified-beginning-of-buffer, defvar, Building Robots, Review, save-excursion): `defun' and `defcustom' are now macros rather than special forms. (Bug#13853) |
Date: |
Sun, 21 Apr 2013 20:01:04 +0800 |
User-agent: |
Bazaar (2.5.0) |
------------------------------------------------------------
revno: 112347 [merge]
committer: Xue Fuqiao <address@hidden>
branch nick: trunk
timestamp: Sun 2013-04-21 20:01:04 +0800
message:
* doc/lispintro/emacs-lisp-intro.texi (defcustom, defun,
simplified-beginning-of-buffer, defvar, Building Robots, Review,
save-excursion): `defun' and `defcustom' are now macros rather than special
forms. (Bug#13853)
modified:
doc/lispintro/ChangeLog
doc/lispintro/emacs-lisp-intro.texi
=== modified file 'doc/lispintro/ChangeLog'
--- a/doc/lispintro/ChangeLog 2013-04-04 03:46:25 +0000
+++ b/doc/lispintro/ChangeLog 2013-04-21 11:56:28 +0000
@@ -1,3 +1,10 @@
+2013-04-21 Xue Fuqiao <address@hidden>
+
+ * emacs-lisp-intro.texi (defcustom, defun)
+ (simplified-beginning-of-buffer, defvar, Building Robots, Review)
+ (save-excursion): `defun' and `defcustom' are now macros rather
+ than special forms. (Bug#13853)
+
2013-03-16 Glenn Morris <address@hidden>
* emacs-lisp-intro.texi: Add some stuff specific to www.gnu.org.
=== modified file 'doc/lispintro/emacs-lisp-intro.texi'
--- a/doc/lispintro/emacs-lisp-intro.texi 2013-03-16 22:08:22 +0000
+++ b/doc/lispintro/emacs-lisp-intro.texi 2013-04-21 11:56:28 +0000
@@ -37,6 +37,7 @@
@set edition-number 3.10
@set update-date 28 October 2009
address@hidden FIXME can this be updated? -- xfq
@ignore
## Summary of shell commands to create various output formats:
@@ -3094,18 +3095,15 @@
function is written in Emacs Lisp or C.
@node defun
address@hidden The @code{defun} Special Form
address@hidden The @code{defun} Macro
@findex defun
address@hidden Special form of @code{defun}
@cindex @samp{function definition} defined
In Lisp, a symbol such as @code{mark-whole-buffer} has code attached to
it that tells the computer what to do when the function is called.
This code is called the @dfn{function definition} and is created by
evaluating a Lisp expression that starts with the symbol @code{defun}
-(which is an abbreviation for @emph{define function}). Because
address@hidden does not evaluate its arguments in the usual way, it is
-called a @dfn{special form}.
+(which is an abbreviation for @emph{define function}).
In subsequent sections, we will look at function definitions from the
Emacs source code, such as @code{mark-whole-buffer}. In this section,
@@ -4254,7 +4252,7 @@
@findex point
@findex mark
-The @code{save-excursion} function is the fourth and final special form
+The @code{save-excursion} function is the third and final special form
that we will discuss in this chapter.
In Emacs Lisp programs used for editing, the @code{save-excursion}
@@ -4381,9 +4379,9 @@
@node Review
@section Review
-In the last few chapters we have introduced a fair number of functions
-and special forms. Here they are described in brief, along with a few
-similar functions that have not been mentioned yet.
+In the last few chapters we have introduced a macro and a fair number
+of functions and special forms. Here they are described in brief,
+along with a few similar functions that have not been mentioned yet.
@table @code
@item eval-last-sexp
@@ -4393,10 +4391,10 @@
current buffer. This command is normally bound to @kbd{C-x C-e}.
@item defun
-Define function. This special form has up to five parts: the name,
-a template for the arguments that will be passed to the function,
-documentation, an optional interactive declaration, and the body of the
-definition.
+Define function. This macro has up to five parts: the name, a
+template for the arguments that will be passed to the function,
+documentation, an optional interactive declaration, and the body of
+the definition.
@need 1250
For example, in an early version of Emacs, the function definition was
@@ -4803,7 +4801,7 @@
@end smallexample
Like all function definitions, this definition has five parts following
-the special form @code{defun}:
+the macro @code{defun}:
@enumerate
@item
@@ -9293,10 +9291,6 @@
not override the existing value. Second, @code{defvar} has a
documentation string.
-(Another special form, @code{defcustom}, is designed for variables
-that people customize. It has more features than @code{defvar}.
-(@xref{defcustom, , Setting Variables with @code{defcustom}}.)
-
@menu
* See variable current value::
* defvar and asterisk::
@@ -11300,11 +11294,11 @@
A function definition provides the blueprints for a robot. When you
install a function definition, that is, when you evaluate a
address@hidden special form, you install the necessary equipment to
-build robots. It is as if you were in a factory, setting up an
-assembly line. Robots with the same name are built according to the
-same blueprints. So they have, as it were, the same `model number',
-but a different `serial number'.
address@hidden macro, you install the necessary equipment to build
+robots. It is as if you were in a factory, setting up an assembly
+line. Robots with the same name are built according to the same
+blueprints. So they have, as it were, the same `model number', but a
+different `serial number'.
We often say that a recursive function `calls itself'. What we mean
is that the instructions in a recursive function cause the Lisp
@@ -16971,10 +16965,9 @@
file. Indeed, you can write any Lisp expression in your @file{.emacs}
file.)
-The @code{customize} feature depends on the @code{defcustom} special
-form. Although you can use @code{defvar} or @code{setq} for variables
-that users set, the @code{defcustom} special form is designed for the
-job.
+The @code{customize} feature depends on the @code{defcustom} macro.
+Although you can use @code{defvar} or @code{setq} for variables that
+users set, the @code{defcustom} macro is designed for the job.
You can use your knowledge of @code{defvar} for writing the
first three arguments for @code{defcustom}. The first argument to
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Emacs-diffs] /srv/bzr/emacs/trunk r112347: * doc/lispintro/emacs-lisp-intro.texi (defcustom, defun, simplified-beginning-of-buffer, defvar, Building Robots, Review, save-excursion): `defun' and `defcustom' are now macros rather than special forms. (Bug#13853),
Xue Fuqiao <=