aboutsummaryrefslogtreecommitdiffstats
path: root/doc
diff options
context:
space:
mode:
authorGlenn Morris2018-03-22 07:50:37 -0700
committerGlenn Morris2018-03-22 07:50:37 -0700
commit0afb436eeb9b87dbd13b012e3b13d51fc6745f0d (patch)
tree683cf853c6bc6065a5f5a3d9ae81feda1882da95 /doc
parent081c39beb0340f5d6084dc90796ba726a52c928e (diff)
parent8ac621bb5594786c66cc724864e6037c8c650774 (diff)
downloademacs-0afb436eeb9b87dbd13b012e3b13d51fc6745f0d.tar.gz
emacs-0afb436eeb9b87dbd13b012e3b13d51fc6745f0d.zip
Merge from origin/emacs-26
8ac621b (origin/emacs-26) Document DEFUN attributes 16d0cc7 * etc/NEWS: Add an entry for auth-source-pass. cc1702f Fix the MSDOS build daa9e85 Improve warning and error messages 7612dd1 Adjust eieio persistence tests for expected failure f0cf4dc Let eieio-persistent-read read what object-write has written 40ad1ff Handle possible classtype values in eieio-persistent-read 4ec935d Add new tests for eieio persistence 47917d8 * lisp/gnus/gnus-cloud.el (gnus-cloud-synced-files): Fix doc ... e32f352 * lisp/ibuf-ext.el (ibuffer-never-search-content-mode): Fix t... 5268f30 * doc/lispref/windows.texi (Selecting Windows): Fix a typo. 143b485 * doc/lispref/internals.texi (Writing Emacs Primitives): Fix ... 4ab4551 Firm up documentation of generalized variables a5bf099 Improve documentation of Auto-Revert mode ed05eaa Improvements in dired.texi Conflicts: etc/NEWS
Diffstat (limited to 'doc')
-rw-r--r--doc/emacs/dired.texi48
-rw-r--r--doc/emacs/files.texi3
-rw-r--r--doc/lispref/internals.texi41
-rw-r--r--doc/lispref/variables.texi34
-rw-r--r--doc/lispref/windows.texi2
5 files changed, 93 insertions, 35 deletions
diff --git a/doc/emacs/dired.texi b/doc/emacs/dired.texi
index cbf4194d397..fbb3030c2a4 100644
--- a/doc/emacs/dired.texi
+++ b/doc/emacs/dired.texi
@@ -12,7 +12,8 @@
12 Dired makes an Emacs buffer containing a listing of a directory, and 12 Dired makes an Emacs buffer containing a listing of a directory, and
13optionally some of its subdirectories as well. You can use the normal 13optionally some of its subdirectories as well. You can use the normal
14Emacs commands to move around in this buffer, and special Dired 14Emacs commands to move around in this buffer, and special Dired
15commands to operate on the listed files. 15commands to operate on the listed files. Dired works with both local
16and remote directories.
16 17
17 The Dired buffer is normally read-only, and inserting text in it is 18 The Dired buffer is normally read-only, and inserting text in it is
18not allowed (however, the Wdired mode allows that, @pxref{Wdired}). 19not allowed (however, the Wdired mode allows that, @pxref{Wdired}).
@@ -109,8 +110,9 @@ default) means to perform the check; any other non-@code{nil} value
109means to use the @samp{--dired} option; and @code{nil} means not to 110means to use the @samp{--dired} option; and @code{nil} means not to
110use the @samp{--dired} option. 111use the @samp{--dired} option.
111 112
112 On MS-Windows and MS-DOS systems, Emacs emulates @command{ls}. 113 On MS-Windows and MS-DOS systems, and also on some remote systems,
113@xref{ls in Lisp}, for options and peculiarities of this emulation. 114Emacs emulates @command{ls}. @xref{ls in Lisp}, for options and
115peculiarities of this emulation.
114 116
115@findex dired-other-window 117@findex dired-other-window
116@kindex C-x 4 d 118@kindex C-x 4 d
@@ -131,10 +133,13 @@ deletes its window if the window was created just for that buffer.
131 133
132@kindex C-n @r{(Dired)} 134@kindex C-n @r{(Dired)}
133@kindex C-p @r{(Dired)} 135@kindex C-p @r{(Dired)}
136@findex dired-next-line
137@findex dired-previous-line
134 All the usual Emacs cursor motion commands are available in Dired 138 All the usual Emacs cursor motion commands are available in Dired
135buffers. The keys @kbd{C-n} and @kbd{C-p} are redefined to put the 139buffers. The keys @kbd{C-n} and @kbd{C-p} are redefined to run
136cursor at the beginning of the file name on the line, rather than at 140@code{dired-next-line} and @code{dired-previous-line}, respectively,
137the beginning of the line. 141and they put the cursor at the beginning of the file name on the line,
142rather than at the beginning of the line.
138 143
139@kindex SPC @r{(Dired)} 144@kindex SPC @r{(Dired)}
140 For extra convenience, @key{SPC} and @kbd{n} in Dired are equivalent 145 For extra convenience, @key{SPC} and @kbd{n} in Dired are equivalent
@@ -235,10 +240,11 @@ the buffer, and no files actually deleted.
235 You can delete empty directories just like other files, but normally 240 You can delete empty directories just like other files, but normally
236Dired cannot delete directories that are nonempty. If the variable 241Dired cannot delete directories that are nonempty. If the variable
237@code{dired-recursive-deletes} is non-@code{nil}, then Dired can 242@code{dired-recursive-deletes} is non-@code{nil}, then Dired can
238delete nonempty directories including all their contents. That can 243delete nonempty directories including all their contents. That can be
239be somewhat risky. 244somewhat risky. If the value of the variable is @code{always}, Dired
240Even if you have set @code{dired-recursive-deletes} to @code{nil}, 245will delete nonempty directories recursively, which is even more
241you might want sometimes to delete recursively directories 246risky. Even if you have set @code{dired-recursive-deletes} to
247@code{nil}, you might want sometimes to delete recursively directories
242without being asked for confirmation for all of them. This is handy 248without being asked for confirmation for all of them. This is handy
243when you have marked many directories for deletion and you are very 249when you have marked many directories for deletion and you are very
244sure that all of them can safely be deleted. For every nonempty 250sure that all of them can safely be deleted. For every nonempty
@@ -252,6 +258,9 @@ questions.
252directories into the operating system's Trash, instead of deleting 258directories into the operating system's Trash, instead of deleting
253them outright. @xref{Misc File Ops}. 259them outright. @xref{Misc File Ops}.
254 260
261 An alternative way of deleting files is to mark them with @kbd{m}
262and delete with @kbd{D}, see @ref{Operating on Files}.
263
255@node Flagging Many Files 264@node Flagging Many Files
256@section Flagging Many Files at Once 265@section Flagging Many Files at Once
257@cindex flagging many files for deletion (in Dired) 266@cindex flagging many files for deletion (in Dired)
@@ -420,7 +429,9 @@ Mark the current file with @samp{*} (@code{dired-mark}). If the
420region is active, mark all files in the region instead; otherwise, if 429region is active, mark all files in the region instead; otherwise, if
421a numeric argument @var{n} is supplied, mark the next @var{n} files 430a numeric argument @var{n} is supplied, mark the next @var{n} files
422instead, starting with the current file (if @var{n} is negative, mark 431instead, starting with the current file (if @var{n} is negative, mark
423the previous @minus{}@var{n} files). 432the previous @minus{}@var{n} files). If invoked on a subdirectory
433header line (@pxref{Subdirectories in Dired}), this command marks all
434the files in that subdirectory.
424 435
425@item * * 436@item * *
426@kindex * * @r{(Dired)} 437@kindex * * @r{(Dired)}
@@ -578,10 +589,10 @@ command will look in the buffer without revisiting the file, so the results
578might be inconsistent with the file on disk if its contents have changed 589might be inconsistent with the file on disk if its contents have changed
579since it was last visited. If you don't want this, you may wish to 590since it was last visited. If you don't want this, you may wish to
580revert the files you have visited in your buffers, or to turn on 591revert the files you have visited in your buffers, or to turn on
581@code{auto-revert} mode in those buffers, before invoking this 592Auto-Revert mode in those buffers, before invoking this command.
582command. @xref{Reverting}. If you prefer that this command should always 593@xref{Reverting}. If you prefer that this command should always
583revisit the file, without you having to revert the file or enable 594revisit the file, without you having to revert the file or enable
584@code{auto-revert} mode, you might want to set 595Auto-Revert mode, you might want to set
585@code{dired-always-read-filesystem} to non-@code{nil}. 596@code{dired-always-read-filesystem} to non-@code{nil}.
586 597
587@item C-/ 598@item C-/
@@ -766,7 +777,9 @@ suitable guess made using the variables @code{lpr-command} and
766@item Z 777@item Z
767Compress the specified files (@code{dired-do-compress}). If the file 778Compress the specified files (@code{dired-do-compress}). If the file
768appears to be a compressed file already, uncompress it instead. Each 779appears to be a compressed file already, uncompress it instead. Each
769marked file is compressed into its own archive. 780marked file is compressed into its own archive. This uses the
781@command{gzip} program if it is available, otherwise it uses
782@command{compress}.
770 783
771@findex dired-do-compress-to 784@findex dired-do-compress-to
772@kindex c @r{(Dired)} 785@kindex c @r{(Dired)}
@@ -1048,6 +1061,9 @@ minibuffer is the file at the mark (i.e., the ordinary Emacs mark,
1048not a Dired mark; @pxref{Setting Mark}). Otherwise, if the file at 1061not a Dired mark; @pxref{Setting Mark}). Otherwise, if the file at
1049point has a backup file (@pxref{Backup}), that is the default. 1062point has a backup file (@pxref{Backup}), that is the default.
1050 1063
1064 You could also compare files using @code{ediff-files}, see
1065@ref{Major Entry Points,,, ediff, Ediff User's Manual}.
1066
1051@node Subdirectories in Dired 1067@node Subdirectories in Dired
1052@section Subdirectories in Dired 1068@section Subdirectories in Dired
1053@cindex subdirectories in Dired 1069@cindex subdirectories in Dired
@@ -1476,7 +1492,7 @@ space.
1476each marked file. With just @kbd{C-u} as the prefix argument, it uses 1492each marked file. With just @kbd{C-u} as the prefix argument, it uses
1477file names relative to the Dired buffer's default directory. (This 1493file names relative to the Dired buffer's default directory. (This
1478can still contain slashes if in a subdirectory.) As a special case, 1494can still contain slashes if in a subdirectory.) As a special case,
1479if point is on a directory headerline, @kbd{w} gives you the absolute 1495if point is on a directory header line, @kbd{w} gives you the absolute
1480name of that directory. Any prefix argument or marked files are 1496name of that directory. Any prefix argument or marked files are
1481ignored in this case. 1497ignored in this case.
1482 1498
diff --git a/doc/emacs/files.texi b/doc/emacs/files.texi
index 77bdb6ee448..4e9e7ac3f0a 100644
--- a/doc/emacs/files.texi
+++ b/doc/emacs/files.texi
@@ -991,6 +991,9 @@ Auto-Revert Tail mode works also for remote files.
991 When a buffer is auto-reverted, a message is generated. This can be 991 When a buffer is auto-reverted, a message is generated. This can be
992suppressed by setting @code{auto-revert-verbose} to @code{nil}. 992suppressed by setting @code{auto-revert-verbose} to @code{nil}.
993 993
994 In Dired buffers (@pxref{Dired}), Auto-Revert mode refreshes the
995buffer when a file is created or deleted in the buffer's directory.
996
994 @xref{VC Undo}, for commands to revert to earlier versions of files 997 @xref{VC Undo}, for commands to revert to earlier versions of files
995under version control. @xref{VC Mode Line}, for Auto Revert 998under version control. @xref{VC Mode Line}, for Auto Revert
996peculiarities when visiting files under version control. 999peculiarities when visiting files under version control.
diff --git a/doc/lispref/internals.texi b/doc/lispref/internals.texi
index 76be7bf0ac6..7ae5b5c693d 100644
--- a/doc/lispref/internals.texi
+++ b/doc/lispref/internals.texi
@@ -735,7 +735,7 @@ Lisp form. For example:
735 735
736@example 736@example
737@group 737@group
738DEFUN ("foo", Ffoo, Sfoo, 0, UNEVALLED, 738DEFUN ("foo", Ffoo, Sfoo, 0, UNEVALLED, 0
739 "(list (read-char-by-name \"Insert character: \")\ 739 "(list (read-char-by-name \"Insert character: \")\
740 (prefix-numeric-value current-prefix-arg)\ 740 (prefix-numeric-value current-prefix-arg)\
741 t))", 741 t))",
@@ -768,6 +768,43 @@ the actual documentation. The others have placeholders beginning with
768All the usual rules for documentation strings in Lisp code 768All the usual rules for documentation strings in Lisp code
769(@pxref{Documentation Tips}) apply to C code documentation strings 769(@pxref{Documentation Tips}) apply to C code documentation strings
770too. 770too.
771
772The documentation string can be followed by a list of C function
773attributes for the C function that implements the primitive, like
774this:
775
776@example
777@group
778DEFUN ("bar", Fbar, Sbar, 0, UNEVALLED, 0
779 doc: /* @dots{} /*
780 attributes: @var{attr1} @var{attr2} @dots{})
781@end group
782@end example
783
784@noindent
785You can specify more than a single attribute, one after the other.
786Currently, only the following attributes are recognized:
787
788@table @code
789@item noreturn
790Declares the C function as one that never returns. This corresponds
791to the C11 keyword @code{_Noreturn} and to @w{@code{__attribute__
792((__noreturn__))}} attribute of GCC (@pxref{Function Attributes,,,
793gcc, Using the GNU Compiler Collection}).
794
795@item const
796Declares that the function does not examine any values except its
797arguments, and has no effects except the return value. This
798corresponds to @w{@code{__attribute__ ((__const__))}} attribute of
799GCC.
800
801@item noinline
802This corresponds to @w{@code{__attribute__ ((__noinline__))}}
803attribute of GCC, which prevents the function from being considered
804for inlining. This might be needed, e.g., to countermand effects of
805link-time optimizations on stack-based variables.
806@end table
807
771@end table 808@end table
772 809
773 After the call to the @code{DEFUN} macro, you must write the 810 After the call to the @code{DEFUN} macro, you must write the
@@ -850,7 +887,7 @@ defined with @code{DEFVAR_BOOL} are automatically added to the list
850@code{byte-boolean-vars} used by the byte compiler. 887@code{byte-boolean-vars} used by the byte compiler.
851 888
852@cindex defining customization variables in C 889@cindex defining customization variables in C
853 If you want to make a Lisp variables that is defined in C behave 890 If you want to make a Lisp variable that is defined in C behave
854like one declared with @code{defcustom}, add an appropriate entry to 891like one declared with @code{defcustom}, add an appropriate entry to
855@file{cus-start.el}. 892@file{cus-start.el}.
856 893
diff --git a/doc/lispref/variables.texi b/doc/lispref/variables.texi
index aecee6f3056..b80bc88a585 100644
--- a/doc/lispref/variables.texi
+++ b/doc/lispref/variables.texi
@@ -2317,11 +2317,12 @@ Attempting to assign them any other value will result in an error:
2317 2317
2318@cindex generalized variable 2318@cindex generalized variable
2319@cindex place form 2319@cindex place form
2320A @dfn{generalized variable} or @dfn{place form} is one of the many places 2320A @dfn{generalized variable} or @dfn{place form} is one of the many
2321in Lisp memory where values can be stored. The simplest place form is 2321places in Lisp memory where values can be stored using the @code{setf}
2322a regular Lisp variable. But the @sc{car}s and @sc{cdr}s of lists, elements 2322macro (@pxref{Setting Generalized Variables}). The simplest place
2323of arrays, properties of symbols, and many other locations are also 2323form is a regular Lisp variable. But the @sc{car}s and @sc{cdr}s of
2324places where Lisp values are stored. 2324lists, elements of arrays, properties of symbols, and many other
2325locations are also places where Lisp values get stored.
2325 2326
2326Generalized variables are analogous to lvalues in the C 2327Generalized variables are analogous to lvalues in the C
2327language, where @samp{x = a[i]} gets an element from an array 2328language, where @samp{x = a[i]} gets an element from an array
@@ -2342,8 +2343,8 @@ variables. The @code{setf} form is like @code{setq}, except that it
2342accepts arbitrary place forms on the left side rather than just 2343accepts arbitrary place forms on the left side rather than just
2343symbols. For example, @code{(setf (car a) b)} sets the car of 2344symbols. For example, @code{(setf (car a) b)} sets the car of
2344@code{a} to @code{b}, doing the same operation as @code{(setcar a b)}, 2345@code{a} to @code{b}, doing the same operation as @code{(setcar a b)},
2345but without having to remember two separate functions for setting and 2346but without you having to use two separate functions for setting and
2346accessing every type of place. 2347accessing this type of place.
2347 2348
2348@defmac setf [place form]@dots{} 2349@defmac setf [place form]@dots{}
2349This macro evaluates @var{form} and stores it in @var{place}, which 2350This macro evaluates @var{form} and stores it in @var{place}, which
@@ -2353,18 +2354,19 @@ just as with @code{setq}. @code{setf} returns the value of the last
2353@var{form}. 2354@var{form}.
2354@end defmac 2355@end defmac
2355 2356
2356The following Lisp forms will work as generalized variables, and 2357The following Lisp forms are the forms in Emacs that will work as
2357so may appear in the @var{place} argument of @code{setf}: 2358generalized variables, and so may appear in the @var{place} argument
2359of @code{setf}:
2358 2360
2359@itemize 2361@itemize
2360@item 2362@item
2361A symbol naming a variable. In other words, @code{(setf x y)} is 2363A symbol. In other words, @code{(setf x y)} is exactly equivalent to
2362exactly equivalent to @code{(setq x y)}, and @code{setq} itself is 2364@code{(setq x y)}, and @code{setq} itself is strictly speaking
2363strictly speaking redundant given that @code{setf} exists. Many 2365redundant given that @code{setf} exists. Most programmers will
2364programmers continue to prefer @code{setq} for setting simple 2366continue to prefer @code{setq} for setting simple variables, though,
2365variables, though, purely for stylistic or historical reasons. 2367for stylistic and historical reasons. The macro @code{(setf x y)}
2366The macro @code{(setf x y)} actually expands to @code{(setq x y)}, 2368actually expands to @code{(setq x y)}, so there is no performance
2367so there is no performance penalty for using it in compiled code. 2369penalty for using it in compiled code.
2368 2370
2369@item 2371@item
2370A call to any of the following standard Lisp functions: 2372A call to any of the following standard Lisp functions:
diff --git a/doc/lispref/windows.texi b/doc/lispref/windows.texi
index 75651b99fde..8d8877bdfda 100644
--- a/doc/lispref/windows.texi
+++ b/doc/lispref/windows.texi
@@ -1772,7 +1772,7 @@ raise the frame or make sure input focus is directed to that frame.
1772@end defun 1772@end defun
1773 1773
1774@cindex select window hook 1774@cindex select window hook
1775@cindex running a hook when a windows gets selected 1775@cindex running a hook when a window gets selected
1776For historical reasons, Emacs does not run a separate hook whenever a 1776For historical reasons, Emacs does not run a separate hook whenever a
1777window gets selected. Applications and internal routines often 1777window gets selected. Applications and internal routines often
1778temporarily select a window to perform a few actions on it. They do 1778temporarily select a window to perform a few actions on it. They do