Merge remote-tracking branch 'savannah/master' into HEAD

This commit is contained in:
Andrea Corallo 2020-12-12 15:31:33 +01:00
commit 0474fda62d
207 changed files with 2781 additions and 1750 deletions

View file

@ -91,7 +91,7 @@ test-filenotify-gio:
- ./autogen.sh autoconf
- ./configure --without-makeinfo --with-file-notification=gfile
- make bootstrap
- make -C test autorevert-tests filenotify-tests
- make -k -C test autorevert-tests filenotify-tests
test-native-bootstrap-speed0:
# Test a full native bootstrap

View file

@ -18,7 +18,6 @@
## along with GNU Emacs. If not, see <https://www.gnu.org/licenses/>.
import argparse
import multiprocessing as mp
import glob
import os
import shutil
import re

View file

@ -2199,12 +2199,22 @@ Display the reference on the current line.
Move to the next reference and display it in the other window
(@code{xref-next-line}).
@item N
@findex xref-next-group
Move to the first reference of the next reference group and display it
in the other window (@code{xref-next-group}).
@item p
@itemx ,
@findex xref-prev-line
Move to the previous reference and display it in the other window
(@code{xref-prev-line}).
@item P
@findex xref-prev-group
Move to the first reference of the previous reference group and
display it in the other window (@code{xref-prev-group}).
@item C-o
@findex xref-show-location-at-point
Display the reference on the current line in the other window

View file

@ -1893,6 +1893,12 @@ with @kbd{C-x #}. But @kbd{C-x #} is the way to tell
window or a frame, @kbd{C-x #} always displays the next server buffer
in that window or in that frame.
@vindex server-client-instructions
When @command{emacsclient} connects, the server will normally output
a message that says how to exit the client frame. If
@code{server-client-instructions} is set to @code{nil}, this message
is inhibited.
@node emacsclient Options
@subsection @code{emacsclient} Options
@cindex @code{emacsclient} options
@ -2255,13 +2261,18 @@ off.
@vindex ps-print-color-p
If your printer doesn't support colors, you should turn off color
processing by setting @code{ps-print-color-p} to @code{nil}. By
default, if the display supports colors, Emacs produces hardcopy output
with color information; on black-and-white printers, colors are emulated
with shades of gray. This might produce illegible output, even if your
screen colors only use shades of gray.
default, if the display supports colors, Emacs produces hardcopy
output with color information; on black-and-white printers, colors are
emulated with shades of gray. This might produce barely-readable or
even illegible output, even if your screen colors only use shades of
gray.
Alternatively, you can set @code{ps-print-color-p} to @code{black-white} to
print colors on black/white printers.
@vindex ps-black-white-faces
Alternatively, you can set @code{ps-print-color-p} to @code{black-white}
to have colors display better on black/white printers. This works by
using information in @code{ps-black-white-faces} to express colors by
customizable list of shades of gray, augmented by bold and italic
face attributes.
@vindex ps-use-face-background
By default, PostScript printing ignores the background colors of the

View file

@ -706,7 +706,11 @@ contents and the file contents are identical before the revert
operation, reverting preserves all the markers. If they are not
identical, reverting does change the buffer; in that case, it preserves
the markers in the unchanged text (if any) at the beginning and end of
the buffer. Preserving any additional markers would be problematical.
the buffer. Preserving any additional markers would be problematic.
When reverting from non-file sources, markers are usually not
preserved, but this is up to the specific @code{revert-buffer-function}
implementation.
@end deffn
@defvar revert-buffer-in-progress-p

View file

@ -2632,10 +2632,12 @@ appearance of @var{face} will again be determined by its default face
spec.
@cindex @code{eval-defun}, and @code{defface} forms
@cindex @code{eval-last-sexp}, and @code{defface} forms
As an exception, if you evaluate a @code{defface} form with
@kbd{C-M-x} in Emacs Lisp mode (@code{eval-defun}), a special feature
of @code{eval-defun} overrides any custom face specs on the face,
causing the face to reflect exactly what the @code{defface} says.
@kbd{C-M-x} (@code{eval-defun}) or with @kbd{C-x C-e}
(@code{eval-last-sexp}) in Emacs Lisp mode, a special feature of these
commands overrides any custom face specs on the face, causing the face
to reflect exactly what the @code{defface} says.
The @var{spec} argument is a @dfn{face spec}, which states how the
face should appear on different kinds of terminals. It should be an
@ -5898,6 +5900,26 @@ string containing the image data as raw bytes. @var{image-type} should be a
@end lisp
@end defun
@defun svg-embed-base-uri-image svg relative-filename &rest args
To @var{svg} add an embedded (raster) image placed at
@var{relative-filename}. @var{relative-filename} is searched inside
@code{file-name-directory} of the @code{:base-uri} svg image property.
This improves the performance of embedding large images.
@lisp
;; Embeding /tmp/subdir/rms.jpg and /tmp/another/rms.jpg
(svg-embed-base-uri-image svg "subdir/rms.jpg"
:width "100px" :height "100px"
:x "50px" :y "75px")
(svg-embed-base-uri-image svg "another/rms.jpg"
:width "100px" :height "100px"
:x "75px" :y "50px")
(svg-image svg :scale 1.0
:base-uri "/tmp/dummy"
:width 175 :height 175)
@end lisp
@end defun
@defun svg-clip-path svg &rest args
Add a clipping path to @var{svg}. If applied to a shape via the
@var{:clip-path} property, parts of that shape which lie outside of
@ -6575,6 +6597,12 @@ except when you explicitly clear it. This mode can be useful for
debugging.
@end defvar
@defun image-cache-size
This function returns the total size of the current image cache, in
bytes. An image of size 200x100 with 24 bits per color will have a
cache size of 60000 bytes, for instance.
@end defun
@node Xwidgets
@section Embedded Native Widgets
@cindex xwidget
@ -6879,6 +6907,16 @@ This inserts a button with the label @var{label} at point, using text
properties.
@end defun
@defun button-buttonize string callback &optional data
Sometimes it's more convenient to make a string into a button without
inserting it into a buffer immediately, for instance when creating
data structures that may then, later, be inserted into a buffer. This
function makes @var{string} into such a string, and @var{callback}
will be called when the user clicks on the button. The optional
@var{data} parameter will be used as the parameter when @var{callback}
is called. If @code{nil}, the button is used as the parameter instead.
@end defun
@node Manipulating Buttons
@subsection Manipulating Buttons
@cindex manipulating buttons

View file

@ -615,6 +615,19 @@ during garbage collection so far in this Emacs session, as a
floating-point number.
@end defvar
@defun memory-report
It can sometimes be useful to see where Emacs is using memory (in
various variables, buffers, and caches). This command will open a new
buffer (called @samp{"*Memory Report*"}) that will give an overview,
in addition to listing the ``largest'' buffers and variables.
All the data here is approximate, because there's really no consistent
way to compute the size of a variable. For instance, two variables
may share parts of a data structure, and this will be counted twice,
but this command may still give a useful high-level overview of which
parts of Emacs is using memory.
@end defun
@node Stack-allocated Objects
@section Stack-allocated Objects

View file

@ -2633,14 +2633,14 @@ calls @var{function} with no arguments, or @samp{--eval=@var{form}}.
Any Lisp program output that would normally go to the echo area,
either using @code{message}, or using @code{prin1}, etc., with
@code{t} as the stream, goes instead to Emacs's standard descriptors
when in batch mode: @code{message} writes to the standard error
descriptor, while @code{prin1} and other print functions write to the
standard output. Similarly, input that would normally come from the
minibuffer is read from the standard input descriptor. Thus, Emacs
behaves much like a noninteractive application program. (The echo
area output that Emacs itself normally generates, such as command
echoing, is suppressed entirely.)
@code{t} as the stream (@pxref{Output Streams}), goes instead to
Emacs's standard descriptors when in batch mode: @code{message} writes
to the standard error descriptor, while @code{prin1} and other print
functions write to the standard output. Similarly, input that would
normally come from the minibuffer is read from the standard input
descriptor. Thus, Emacs behaves much like a noninteractive
application program. (The echo area output that Emacs itself normally
generates, such as command echoing, is suppressed entirely.)
Non-ASCII text written to the standard output or error descriptors is
by default encoded using @code{locale-coding-system} (@pxref{Locales})

View file

@ -123,13 +123,13 @@ came from. In this case, it makes no difference what value
@code{t} used as a stream means that the input is read from the
minibuffer. In fact, the minibuffer is invoked once and the text
given by the user is made into a string that is then used as the
input stream. If Emacs is running in batch mode, standard input is used
instead of the minibuffer. For example,
input stream. If Emacs is running in batch mode (@pxref{Batch Mode}),
standard input is used instead of the minibuffer. For example,
@example
(message "%s" (read t))
@end example
will read a Lisp expression from standard input and print the result
to standard output.
will in batch mode read a Lisp expression from standard input and
print the result to standard output.
@item @code{nil}
@cindex @code{nil} input stream
@ -392,13 +392,15 @@ is responsible for storing the characters wherever you want to put them.
@item @code{t}
@cindex @code{t} output stream
The output characters are displayed in the echo area.
The output characters are displayed in the echo area. If Emacs is
running in batch mode (@pxref{Batch Mode}), the output is written to
the standard output descriptor instead.
@item @code{nil}
@cindex @code{nil} output stream
@code{nil} specified as an output stream means to use the value of
@code{standard-output} instead; that value is the @dfn{default output
stream}, and must not be @code{nil}.
@code{nil} specified as an output stream means to use the value of the
@code{standard-output} variable instead; that value is the
@dfn{default output stream}, and must not be @code{nil}.
@item @var{symbol}
A symbol as output stream is equivalent to the symbol's function

View file

@ -2931,6 +2931,22 @@ used instead. Here is an example:
@end example
@end defvar
@defun object-intervals OBJECT
This function returns a copy of the intervals (i.e., text properties)
in @var{object} as a list of intervals. @var{object} must be a string
or a buffer. Altering the structure of this list does not change the
intervals in the object.
@example
(object-intervals (propertize "foo" 'face 'bold))
@result{} ((0 3 (face bold)))
@end example
Each element in the returned list represents one interval. Each
interval has three parts: The first is the start, the second is the
end, and the third part is the text property itself.
@end defun
@node Changing Properties
@subsection Changing Text Properties
@cindex changing text properties

View file

@ -481,10 +481,12 @@ form occurs in a @code{let} form with lexical binding enabled), then
effect until its binding construct exits. @xref{Variable Scoping}.
@cindex @code{eval-defun}, and @code{defvar} forms
When you evaluate a top-level @code{defvar} form with @kbd{C-M-x} in
Emacs Lisp mode (@code{eval-defun}), a special feature of
@code{eval-defun} arranges to set the variable unconditionally, without
testing whether its value is void.
@cindex @code{eval-last-sexp}, and @code{defvar} forms
When you evaluate a top-level @code{defvar} form with @kbd{C-M-x}
(@code{eval-defun}) or with @kbd{C-x C-e} (@code{eval-last-sexp}) in
Emacs Lisp mode, a special feature of these two commands arranges to
set the variable unconditionally, without testing whether its value is
void.
If the @var{doc-string} argument is supplied, it specifies the
documentation string for the variable (stored in the symbol's

View file

@ -28047,13 +28047,7 @@ defined as the distance that light will travel in a vacuum in
vacuum is exactly 299792458 m/s. Many other units have been
redefined in terms of fundamental physical processes; a second, for
example, is currently defined as 9192631770 periods of a certain
radiation related to the cesium-133 atom. The only SI unit that is not
based on a fundamental physical process (although there are efforts to
change this) is the kilogram, which was originally defined as the mass
of one liter of water, but is now defined as the mass of the
international prototype of the kilogram (IPK), a cylinder of platinum-iridium
kept at the Bureau international des poids et mesures in Sèvres,
France. (There are several copies of the IPK throughout the world.)
radiation related to the cesium-133 atom.
The British imperial units, once defined in terms of physical objects,
were redefined in 1963 in terms of SI units. The US customary units,
which were the same as British units until the British imperial system

View file

@ -1097,10 +1097,9 @@ by @var{x} if specified.
@defmac cl-pushnew x place @t{&key :test :test-not :key}
This macro inserts @var{x} at the front of the list stored in
@var{place}, but only if @var{x} was not @code{eql} to any
existing element of the list. The optional keyword arguments
are interpreted in the same way as for @code{cl-adjoin}.
@xref{Lists as Sets}.
@var{place}, but only if @var{x} isn't present in the list already.
The optional keyword arguments are interpreted in the same way as for
@code{cl-adjoin}. @xref{Lists as Sets}.
@end defmac
@defmac cl-shiftf place@dots{} newvalue
@ -3796,8 +3795,10 @@ This is a destructive version of @code{cl-sublis}.
@section Lists as Sets
@noindent
These functions perform operations on lists that represent sets
of elements.
These functions perform operations on lists that represent sets of
elements. All these functions (unless otherwise specified) default to
using @code{eql} as the test function, but that can be modified by the
@code{:test} parameter.
@defun cl-member item list @t{&key :test :test-not :key}
This function searches @var{list} for an element matching @var{item}.

View file

@ -5028,10 +5028,37 @@ Nothing if the article is a root and lots of spaces if it isn't (it
pushes everything after it off the screen).
@item [
Opening bracket, which is normally @samp{[}, but can also be @samp{<}
for adopted articles (@pxref{Customizing Threading}).
for adopted articles (@pxref{Customizing Threading}). This can be
customized using following settings:
@table @code
@item gnus-sum-opening-bracket
@vindex gnus-sum-opening-bracket
Opening bracket for normal (non-adopted) articles. The default is
@samp{[}.
@item gnus-sum-opening-bracket-adopted
@vindex gnus-sum-opening-bracket-adopted
Opening bracket for adopted articles. The default is @samp{<}.
@end table
@item ]
Closing bracket, which is normally @samp{]}, but can also be @samp{>}
for adopted articles.
for adopted articles. This can be customised using following settings:
@table @code
@item gnus-sum-closing-bracket
@vindex gnus-sum-closing-bracket
Closing bracket for normal (non-adopted) articles. The default is
@samp{]}.
@item gnus-sum-closing-bracket-adopted
@vindex gnus-sum-opening-bracket-adopted
Closing bracket for adopted articles. The default is @samp{>}.
@end table
@item >
One space for each thread level.
@item <

View file

@ -192,8 +192,10 @@ have been replaced with "chat.freenode.net" throughout Emacs.
These functions return the connection local value of the respective
variables. This can be used for remote hosts.
** Emacs now prints a backtrace when signaling an error in batch mode. This
makes debugging Emacs Lisp scripts run in batch mode easier.
** Emacs now prints a backtrace when signaling an error in batch mode.
This makes debugging Emacs Lisp scripts run in batch mode easier. To
get back the old behavior, set the new variable
'backtrace-on-error-noninteractive' to a nil value.
* Editing Changes in Emacs 28.1
@ -273,6 +275,11 @@ preserving markers, properties and overlays. The new variable
number of seconds that 'revert-buffer-with-fine-grain' should spend
trying to be non-destructive.
+++
** New command 'memory-report'.
This command opens a new buffer called "*Memory Report*" and gives a
summary of where Emacs is using memory currently.
** Outline
+++
@ -285,6 +292,18 @@ the buffer cycles the whole buffer between "only top-level headings",
* Changes in Specialized Modes and Packages in Emacs 28.1
** Loading dunnet.el in batch mode doesn't start the game any more
Instead you need to do 'emacs -f dun-batch' to start the game in
batch mode.
** Emacs Server
+++
*** New user option 'server-client-instructions'.
When emacsclient connects, Emacs will (by default) output a message
about how to exit the client frame. If 'server-client-instructions'
is set to nil, this message is inhibited.
** Python mode
*** 'C-c C-r' can now be used on arbitrary regions.
@ -491,6 +510,19 @@ tags to be considered as well.
** Gnus
+++
*** New user options to customise the summary line specs %[ and %].
Four new options introduced in customisation group
'gnus-summary-format'. These are 'gnus-sum-opening-bracket',
'gnus-sum-closing-bracket', 'gnus-sum-opening-bracket-adopted', and
'gnus-sum-closing-bracket-adopted'. Their default values are '[', ']',
'<', '>' respectively. These variables control the appearance of '%['
and '%]' specs in the summary line format. '%[' will normally display
the value of 'gnus-sum-opening-bracket', but can also be
'gnus-sum-opening-bracket-adopted' for the adopted articles. '%]' will
normally display the value of 'gnus-sum-closing-bracket', but can also
be 'gnus-sum-closing-bracket-adopted' for the adopted articles.
+++
*** New user option 'gnus-paging-select-next'.
This controls what happens when using commands like 'SPC' and 'DEL' to
@ -1083,6 +1115,22 @@ If 'shr-width' is non-nil, it overrides this variable.
** Images
---
** Can explicitly specify base_uri for svg images.
':base-uri' image property can be used to explicitly specify base_uri
for embedded images into svg. ':base-uri' is supported for both file
and data svg images.
+++
** 'svg-embed-base-uri-image' added to embed images
'svg-embed-base-uri-image' can be used to embed images located
relatively to 'file-name-directory' of the ':base-uri' svg image property.
This works much faster then 'svg-embed'.
+++
*** New function 'image-cache-size'.
This function returns the size of the current image cache, in bytes.
---
*** Animated images stop automatically under high CPU pressure sooner.
Previously, an animated image would stop animating if any single image
@ -1199,6 +1247,11 @@ So far Grep and ripgrep are supported. ripgrep seems to offer better
performance in certain cases, in particular for case-insensitive
searches.
+++
*** New commands 'xref-prev-group' and 'xref-next-group'.
These commands are bound respectively to 'P' and 'N', and navigate to
the first item of the previous or next group in the "*xref*" buffer.
** json.el
---
@ -1357,8 +1410,41 @@ This face is used for error messages from 'diff'.
*** New command 'diff-refresh-hunk'.
This new command (bound to 'C-c C-l') regenerates the current hunk.
** Buttons
+++
*** New minor mode 'button-mode'.
This minor mode does nothing else than install 'button-buffer-map' as
a minor mode map (which binds the 'TAB' / 'S-TAB' key bindings to navigate
to buttons), and can be used in any view-mode-like buffer that has
buttons in it.
+++
*** New utility function 'button-buttonize'.
This function takes a string and returns a string propertized in a way
that makes it a valid button.
** Miscellaneous
+++
*** New function 'object-intervals'.
This function returns a copy of the list of intervals (i.e., text
properties) in the object in question (which must either be a string
or a buffer).
---
*** 'hexl-mode' scrolling commands now heed 'next-screen-context-lines'.
Previously, 'hexl-scroll-down' and 'hexl-scroll-up' would scroll
up/down an entire window, but they now work more like the standard
scrolling commands.
---
*** Errors in 'kill-emacs-hook' no longer prevent Emacs from shutting down.
If a function in that hook signals an error in an interactive Emacs,
the user will be prompted on whether to continue. If the user doesn't
answer within five seconds, Emacs will continue shutting down anyway.
---
*** iso-transl is now preloaded.
This means that keystrokes like 'Alt-[' are defined by default,
@ -1457,13 +1543,6 @@ both modes are on).
This works like 'report-emacs-bug', but is more geared towards sending
patches to the Emacs issue tracker.
+++
*** New minor mode 'button-mode'.
This minor mode does nothing else than install 'button-buffer-map' as
a minor mode map (which binds the 'TAB' / 'S-TAB' key bindings to navigate
to buttons), and can be used in any view-mode-like buffer that has
buttons in it.
---
*** 'icomplete-show-matches-on-no-input' behavior change.
Previously, choosing a different completion with commands like 'C-.'

View file

@ -85,6 +85,12 @@ git --no-pager grep -inH -p -e "org-element-map"
lisp/org/org.el=20969=(defun org-fill-paragraph (&optional justify)
lisp/org/org.el:21047: (org-element-map
* ripgrep
rg -nH --color always --no-heading -e grep-match-regexp
lisp/progmodes/grep.el:608: (while (re-search-forward grep-match-regexp end 1)
Binary file emacs.info matches (found "\u{0}" byte around offset 2222525)
* unknown greps
grep -nH -e "xyzxyz" ../info/*

View file

@ -1152,7 +1152,7 @@ gov.gr
// gs : https://en.wikipedia.org/wiki/.gs
gs
// gt : http://www.gt/politicas_de_registro.html
// gt : https://www.gt/sitio/registration_policy.php?lang=en
gt
com.gt
edu.gt
@ -4703,6 +4703,7 @@ nl
// Norid geographical second level domains : https://www.norid.no/en/om-domenenavn/regelverk-for-no/vedlegg-b/
// Norid category second level domains : https://www.norid.no/en/om-domenenavn/regelverk-for-no/vedlegg-c/
// Norid category second-level domains managed by parties other than Norid : https://www.norid.no/en/om-domenenavn/regelverk-for-no/vedlegg-d/
// RSS feed: https://teknisk.norid.no/en/feed/
no
// Norid category second level domains : https://www.norid.no/en/om-domenenavn/regelverk-for-no/vedlegg-c/
fhs.no
@ -7110,7 +7111,7 @@ org.zw
// newGTLDs
// List of new gTLDs imported from https://www.icann.org/resources/registries/gtlds/v2/gtlds.json on 2020-10-08T17:45:32Z
// List of new gTLDs imported from https://www.icann.org/resources/registries/gtlds/v2/gtlds.json on 2020-11-30T20:26:10Z
// This list is auto-generated, don't edit it manually.
// aaa : 2015-02-26 American Automobile Association, Inc.
aaa
@ -7328,7 +7329,7 @@ author
// auto : 2014-11-13 XYZ.COM LLC
auto
// autos : 2014-01-09 DERAutos, LLC
// autos : 2014-01-09 XYZ.COM LLC
autos
// avianca : 2015-01-08 Avianca Holdings S.A.
@ -7337,7 +7338,7 @@ avianca
// aws : 2015-06-25 Amazon Registry Services, Inc.
aws
// axa : 2013-12-19 AXA SA
// axa : 2013-12-19 AXA Group Operations SAS
axa
// azure : 2014-12-18 Microsoft Corporation
@ -7478,7 +7479,7 @@ bmw
// bnpparibas : 2014-05-29 BNP Paribas
bnpparibas
// boats : 2014-12-04 DERBoats, LLC
// boats : 2014-12-04 XYZ.COM LLC
boats
// boehringer : 2015-07-09 Boehringer Ingelheim International GmbH
@ -7517,7 +7518,7 @@ bot
// boutique : 2013-11-14 Binky Moon, LLC
boutique
// box : 2015-11-12 .BOX INC.
// box : 2015-11-12 Intercap Registry Inc.
box
// bradesco : 2014-12-18 Banco Bradesco S.A.
@ -8501,7 +8502,7 @@ homedepot
// homegoods : 2015-07-16 The TJX Companies, Inc.
homegoods
// homes : 2014-01-09 DERHomes, LLC
// homes : 2014-01-09 XYZ.COM LLC
homes
// homesense : 2015-07-16 The TJX Companies, Inc.
@ -8651,9 +8652,6 @@ java
// jcb : 2014-11-20 JCB Co., Ltd.
jcb
// jcp : 2015-04-23 JCP Media, Inc.
jcp
// jeep : 2015-07-30 FCA US LLC.
jeep
@ -9077,7 +9075,7 @@ moscow
// moto : 2015-06-04 Motorola Trademark Holdings, LLC
moto
// motorcycles : 2014-01-09 DERMotorcycles, LLC
// motorcycles : 2014-01-09 XYZ.COM LLC
motorcycles
// mov : 2014-01-30 Charleston Road Registry Inc.
@ -9242,7 +9240,7 @@ one
// ong : 2014-03-06 Public Interest Registry
ong
// onl : 2013-09-16 I-Registry Ltd.
// onl : 2013-09-16 iRegistry GmbH
onl
// online : 2015-01-15 DotOnline Inc.
@ -9539,7 +9537,7 @@ reviews
// rexroth : 2015-06-18 Robert Bosch GMBH
rexroth
// rich : 2013-11-21 I-Registry Ltd.
// rich : 2013-11-21 iRegistry GmbH
rich
// richardli : 2015-05-14 Pacific Century Asset Management (HK) Limited
@ -9758,9 +9756,6 @@ show
// showtime : 2015-08-06 CBS Domains Inc.
showtime
// shriram : 2014-01-23 Shriram Capital Ltd.
shriram
// silk : 2015-06-25 Amazon Registry Services, Inc.
silk
@ -10073,7 +10068,7 @@ travelers
// travelersinsurance : 2015-03-26 Travelers TLD, LLC
travelersinsurance
// trust : 2014-10-16 NCC Group Domain Services, Inc.
// trust : 2014-10-16 UNR Corp.
trust
// trv : 2015-03-26 Travelers TLD, LLC
@ -10595,7 +10590,7 @@ vermögensberatung
// xyz : 2013-12-05 XYZ.COM LLC
xyz
// yachts : 2014-01-09 DERYachts, LLC
// yachts : 2014-01-09 XYZ.COM LLC
yachts
// yahoo : 2015-04-02 Yahoo! Domain Services Inc.
@ -10680,12 +10675,6 @@ barsy.ca
// Submitted by Werner Kaltofen <wk@all-inkl.com>
kasserver.com
// Algorithmia, Inc. : algorithmia.com
// Submitted by Eli Perelman <eperelman@algorithmia.io>
*.algorithmia.com
!teams.algorithmia.com
!test.algorithmia.com
// Altervista: https://www.altervista.org
// Submitted by Carlo Cannas <tech_staff@altervista.it>
altervista.org
@ -10868,6 +10857,10 @@ bnr.la
// Submitted by Paul Crowder <paul.crowder@blackbaud.com>
blackbaudcdn.net
// Blatech : http://www.blatech.net
// Submitted by Luke Bratch <luke@bratch.co.uk>
of.je
// Boomla : https://boomla.com
// Submitted by Tibor Halter <thalter@boomla.com>
boomla.net
@ -10981,10 +10974,6 @@ c.la
// Submitted by B. Blechschmidt <hostmaster@certmgr.org>
certmgr.org
// Citrix : https://citrix.com
// Submitted by Alex Stoddard <alex.stoddard@citrix.com>
xenapponazure.com
// Civilized Discourse Construction Kit, Inc. : https://www.discourse.org/
// Submitted by Rishabh Nambiar & Michael Brown <team@discourse.org>
discourse.group
@ -11073,10 +11062,6 @@ cloudns.pro
cloudns.pw
cloudns.us
// Cloudeity Inc : https://cloudeity.com
// Submitted by Stefan Dimitrov <contact@cloudeity.com>
cloudeity.net
// CNPY : https://cnpy.gdn
// Submitted by Angelo Gladding <angelo@lahacker.net>
cnpy.gdn
@ -11537,6 +11522,10 @@ ddnss.org
definima.net
definima.io
// DigitalOcean : https://digitalocean.com/
// Submitted by Braxton Huggins <bhuggins@digitalocean.com>
ondigitalocean.app
// dnstrace.pro : https://dnstrace.pro/
// Submitted by Chris Partridge <chris@partridge.tech>
bci.dnstrace.pro
@ -11802,6 +11791,10 @@ ukco.me
// submitted by Koen Van Isterdael <k.vanisterdael@fermax.be>
mydobiss.com
// FH Muenster : https://www.fh-muenster.de
// Submitted by Robin Naundorf <r.naundorf@fh-muenster.de>
fh-muenster.io
// Filegear Inc. : https://www.filegear.com
// Submitted by Jason Zhu <jason@owtware.com>
filegear.me
@ -11872,6 +11865,7 @@ usercontent.jp
gentapps.com
gentlentapis.com
lab.ms
cdn-edges.net
// GitHub, Inc.
// Submitted by Patrick Toomey <security@github.com>
@ -11931,9 +11925,10 @@ pagespeedmobilizer.com
publishproxy.com
withgoogle.com
withyoutube.com
cloudfunctions.net
*.gateway.dev
cloud.goog
translate.goog
cloudfunctions.net
blogspot.ae
blogspot.al
@ -12056,6 +12051,10 @@ ravendb.me
development.run
ravendb.run
// Hong Kong Productivity Council: https://www.hkpc.org/
// Submitted by SECaaS Team <summchan@hkpc.org>
secaas.hk
// HOSTBIP REGISTRY : https://www.hostbip.com/
// Submitted by Atanunu Igbunuroghene <publicsuffixlist@hostbip.com>
bpl.biz
@ -12165,7 +12164,7 @@ iserv.dev
// Submitted by Yuji Minagawa <domains-admin@iodata.jp>
iobb.net
//Jelastic, Inc. : https://jelastic.com/
// Jelastic, Inc. : https://jelastic.com/
// Submited by Ihor Kolodyuk <ik@jelastic.com>
mel.cloudlets.com.au
cloud.interhostsolutions.be
@ -12180,6 +12179,9 @@ jele.cloud
it1.eur.aruba.jenv-aruba.cloud
it1.jenv-aruba.cloud
it1-eur.jenv-arubabiz.cloud
oxa.cloud
tn.oxa.cloud
uk.oxa.cloud
primetel.cloud
uk.primetel.cloud
ca.reclaim.cloud
@ -12250,6 +12252,7 @@ jelastic.regruhosting.ru
enscaled.sg
jele.site
jelastic.team
orangecloud.tn
j.layershift.co.uk
phx.enscaled.us
mircloud.us
@ -12327,10 +12330,6 @@ co.technology
// Submitted by Greg Holland <greg.holland@lmpm.com>
app.lmpm.com
// Linki Tools UG : https://linki.tools
// Submitted by Paulo Matos <pmatos@linki.tools>
linkitools.space
// linkyard ldt: https://www.linkyard.ch/
// Submitted by Mario Siegenthaler <mario.siegenthaler@linkyard.ch>
linkyard.cloud
@ -12369,7 +12368,6 @@ swidnik.pl
// Lug.org.uk : https://lug.org.uk
// Submitted by Jon Spriggs <admin@lug.org.uk>
uklugs.org
glug.org.uk
lug.org.uk
lugs.org.uk
@ -12446,11 +12444,17 @@ eu.meteorapp.com
co.pl
// Microsoft Corporation : http://microsoft.com
// Submitted by Mostafa Elzeiny <moelzein@microsoft.com>
// Submitted by Mitch Webster <miwebst@microsoft.com>
*.azurecontainer.io
azurewebsites.net
azure-mobile.net
cloudapp.net
azurestaticapps.net
centralus.azurestaticapps.net
eastasia.azurestaticapps.net
eastus2.azurestaticapps.net
westeurope.azurestaticapps.net
westus2.azurestaticapps.net
// minion.systems : http://minion.systems
// Submitted by Robert Böttinger <r@minion.systems>
@ -12492,19 +12496,22 @@ cust.retrosnub.co.uk
ui.nabu.casa
// Names.of.London : https://names.of.london/
// Submitted by James Stevens <registry@names.of.london> or <james@jrcs.net>
// Submitted by James Stevens <registry[at]names.of.london> or <publiclist[at]jrcs.net>
pony.club
of.fashion
on.fashion
of.football
in.london
of.london
from.marketing
with.marketing
for.men
repair.men
and.mom
for.mom
for.one
under.one
for.sale
of.work
that.win
from.work
to.work
// NCTU.ME : https://nctu.me/
@ -12824,6 +12831,12 @@ mypep.link
// Submitted by Kenneth Van Alstyne <kvanalstyne@perspecta.com>
perspecta.cloud
// PE Ulyanov Kirill Sergeevich : https://airy.host
// Submitted by Kirill Ulyanov <k.ulyanov@airy.host>
lk3.ru
ra-ru.ru
zsew.ru
// Planet-Work : https://www.planet-work.com/
// Submitted by Frédéric VANNIÈRE <f.vanniere@planet-work.com>
on-web.fr
@ -12885,6 +12898,10 @@ byen.site
// Submitted by Kor Nielsen <kor@pubtls.org>
pubtls.org
// QOTO, Org.
// Submitted by Jeffrey Phillips Freeman <jeffrey.freeman@qoto.org>
qoto.io
// Qualifio : https://qualifio.com/
// Submitted by Xavier De Cock <xdecock@gmail.com>
qualifioapp.com
@ -12970,7 +12987,6 @@ hzc.io
// Revitalised Limited : http://www.revitalised.co.uk
// Submitted by Jack Price <jack@revitalised.co.uk>
wellbeingzone.eu
ptplus.fit
wellbeingzone.co.uk
// Rochester Institute of Technology : http://www.rit.edu/
@ -13344,7 +13360,7 @@ wafflecell.com
// Submitted by Fajar Sodik <official@wapblog.id>
idnblogger.com
indowapblog.com
bloghp.id
bloger.id
wblog.id
wbq.me
fastblog.net

View file

@ -6063,6 +6063,7 @@ Erlang_functions (FILE *inf)
{
free (last);
last = NULL;
allocated = lastlen = 0;
}
}
else

View file

@ -1225,8 +1225,8 @@ as a heading."
(apropos-print-doc 6 'apropos-face t)
(apropos-print-doc 5 'apropos-widget t)
(apropos-print-doc 4 'apropos-plist nil))
(set (make-local-variable 'truncate-partial-width-windows) t)
(set (make-local-variable 'truncate-lines) t))))
(setq-local truncate-partial-width-windows t)
(setq-local truncate-lines t))))
(prog1 apropos-accumulator
(setq apropos-accumulator ()))) ; permit gc

View file

@ -863,25 +863,25 @@ Entering array mode calls the function `array-mode-hook'."
(make-local-variable 'array-row)
(make-local-variable 'array-column)
(make-local-variable 'array-copy-string)
(set (make-local-variable 'array-respect-tabs) nil)
(set (make-local-variable 'array-max-row)
(read-number "Number of array rows: "))
(set (make-local-variable 'array-max-column)
(read-number "Number of array columns: "))
(set (make-local-variable 'array-columns-per-line)
(read-number "Array columns per line: "))
(set (make-local-variable 'array-field-width)
(read-number "Field width: "))
(set (make-local-variable 'array-rows-numbered)
(y-or-n-p "Rows numbered? "))
(set (make-local-variable 'array-line-length)
(* array-field-width array-columns-per-line))
(set (make-local-variable 'array-lines-per-row)
(+ (floor (1- array-max-column) array-columns-per-line)
(if array-rows-numbered 2 1)))
(setq-local array-respect-tabs nil)
(setq-local array-max-row
(read-number "Number of array rows: "))
(setq-local array-max-column
(read-number "Number of array columns: "))
(setq-local array-columns-per-line
(read-number "Array columns per line: "))
(setq-local array-field-width
(read-number "Field width: "))
(setq-local array-rows-numbered
(y-or-n-p "Rows numbered? "))
(setq-local array-line-length
(* array-field-width array-columns-per-line))
(setq-local array-lines-per-row
(+ (floor (1- array-max-column) array-columns-per-line)
(if array-rows-numbered 2 1)))
(message "")
(force-mode-line-update)
(set (make-local-variable 'truncate-lines) t)
(setq-local truncate-lines t)
(setq overwrite-mode 'overwrite-mode-textual))

View file

@ -661,10 +661,12 @@ Intended as a UPower PropertiesChanged signal handler."
(cond ((stringp battery-upower-device)
(list battery-upower-device))
(battery-upower-device)
((dbus-call-method :system battery-upower-service
battery-upower-path
battery-upower-interface
"EnumerateDevices"))))
((dbus-ignore-errors
(dbus-call-method :system battery-upower-service
battery-upower-path
battery-upower-interface
"EnumerateDevices"
:timeout 1000)))))
(defun battery--upower-state (props state)
"Merge the UPower battery state in PROPS with STATE.

View file

@ -269,8 +269,8 @@ In Buffer Menu mode, the following commands are defined:
\\[revert-buffer] Update the list of buffers.
\\[Buffer-menu-toggle-files-only] Toggle whether the menu displays only file buffers.
\\[Buffer-menu-bury] Bury the buffer listed on this line."
(set (make-local-variable 'buffer-stale-function)
(lambda (&optional _noconfirm) 'fast))
(setq-local buffer-stale-function
(lambda (&optional _noconfirm) 'fast))
(add-hook 'tabulated-list-revert-hook 'list-buffers--refresh nil t))
(defun buffer-menu (&optional arg)

View file

@ -613,6 +613,20 @@ button at point is the button to describe."
(button--describe props)
t)))
(defun button-buttonize (string callback &optional data)
"Make STRING into a button and return it.
When clicked, CALLBACK will be called with the DATA as the
function argument. If DATA isn't present (or is nil), the button
itself will be used instead as the function argument."
(propertize string
'face 'button
'button t
'follow-link t
'category t
'button-data data
'keymap button-map
'action callback))
(provide 'button)
;;; button.el ends here

View file

@ -199,48 +199,16 @@
(message "Omitting leading zeros on integers"))))
(defvar math-power-of-2-cache (list 1 2 4 8 16 32 64 128 256 512 1024))
(defvar math-big-power-of-2-cache nil)
(defun math-power-of-2 (n) ; [I I] [Public]
(if (and (natnump n) (<= n 100))
(or (nth n math-power-of-2-cache)
(let* ((i (length math-power-of-2-cache))
(val (nth (1- i) math-power-of-2-cache)))
(while (<= i n)
(setq val (math-mul val 2)
math-power-of-2-cache (nconc math-power-of-2-cache
(list val))
i (1+ i)))
val))
(let ((found (assq n math-big-power-of-2-cache)))
(if found
(cdr found)
(let ((po2 (math-ipow 2 n)))
(setq math-big-power-of-2-cache
(cons (cons n po2) math-big-power-of-2-cache))
po2)))))
(if (natnump n)
(ash 1 n)
(error "argument must be a natural number")))
(defun math-integer-log2 (n) ; [I I] [Public]
(let ((i 0)
(p math-power-of-2-cache)
val)
(while (and p (Math-natnum-lessp (setq val (car p)) n))
(setq p (cdr p)
i (1+ i)))
(if p
(and (equal val n)
i)
(while (Math-natnum-lessp
(prog1
(setq val (math-mul val 2))
(setq math-power-of-2-cache (nconc math-power-of-2-cache
(list val))))
n)
(setq i (1+ i)))
(and (equal val n)
i))))
(and (natnump n)
(not (zerop n))
(zerop (logand n (1- n)))
(logb n)))
;;; Bitwise operations.
@ -404,7 +372,7 @@
(math-clip (calcFunc-ash a n (- w)) w)
(if (Math-integer-negp a)
(setq a (math-clip a w)))
(let ((two-to-sizem1 (math-power-of-2 (1- w)))
(let ((two-to-sizem1 (and (not (zerop w)) (math-power-of-2 (1- w))))
(sh (calcFunc-lsh a n w)))
(cond ((or (zerop w)
(zerop (logand a two-to-sizem1)))
@ -438,7 +406,7 @@
(if (Math-integer-negp a)
(setq a (math-clip a w)))
(cond ((or (Math-integer-negp n)
(not (Math-natnum-lessp n w)))
(>= n w))
(calcFunc-rot a (math-mod n w) w))
(t
(math-add (calcFunc-lsh a (- n w) w)
@ -455,7 +423,7 @@
(math-reject-arg a 'integerp))
((< (or w (setq w calc-word-size)) 0)
(setq a (math-clip a (- w)))
(if (Math-natnum-lessp a (math-power-of-2 (- -1 w)))
(if (< a (math-power-of-2 (- -1 w)))
a
(math-sub a (math-power-of-2 (- w)))))
((math-zerop w)

View file

@ -815,7 +815,7 @@
(error "Argument must be an integer"))
((Math-integer-negp n)
'(nil))
((Math-natnum-lessp n 8000000)
((< n 8000000)
(let ((i -1) v)
(while (and (> (% n (setq v (aref math-primes-table
(setq i (1+ i)))))
@ -913,7 +913,7 @@
(if (Math-messy-integerp n)
(setq n (math-trunc n)))
(if (Math-natnump n)
(if (Math-natnum-lessp 2 n)
(if (< 2 n)
(let (factors res p (i 0))
(while (and (not (eq n 1))
(< i (length math-primes-table)))
@ -927,7 +927,7 @@
(setq factors (nconc factors (list p))
n (car res)))
(or (eq n 1)
(Math-natnum-lessp p (car res))
(< p (car res))
(setq factors (nconc factors (list n))
n 1))
(setq i (1+ i)))
@ -946,7 +946,7 @@
(if (Math-messy-integerp n)
(setq n (math-trunc n)))
(if (Math-natnump n)
(if (Math-natnum-lessp n 2)
(if (< n 2)
(if (Math-negp n)
(calcFunc-totient (math-abs n))
n)
@ -969,7 +969,7 @@
(if (Math-messy-integerp n)
(setq n (math-trunc n)))
(if (and (Math-natnump n) (not (eq n 0)))
(if (Math-natnum-lessp n 2)
(if (< n 2)
(if (Math-negp n)
(calcFunc-moebius (math-abs n))
1)

View file

@ -2417,17 +2417,6 @@ If X is not an error form, return 1."
(mapcar #'math-normalize (cdr a))))))
;;; Normalize a bignum digit list by trimming high-end zeros. [L l]
(defun math-norm-bignum (a)
(let ((digs a) (last nil))
(while digs
(or (eq (car digs) 0) (setq last digs))
(setq digs (cdr digs)))
(and last
(progn
(setcdr last nil)
a))))
;;; Return 0 for zero, -1 for negative, 1 for positive. [S n] [Public]
(defun calcFunc-sign (a &optional x)
(let ((signs (math-possible-signs a)))
@ -2542,23 +2531,6 @@ If X is not an error form, return 1."
0
2))))
;;; Compare two bignum digit lists, return -1 for A<B, 0 for A=B, 1 for A>B.
(defun math-compare-bignum (a b) ; [S l l]
(let ((res 0))
(while (and a b)
(if (< (car a) (car b))
(setq res -1)
(if (> (car a) (car b))
(setq res 1)))
(setq a (cdr a)
b (cdr b)))
(if a
(progn
(while (eq (car a) 0) (setq a (cdr a)))
(if a 1 res))
(while (eq (car b) 0) (setq b (cdr b)))
(if b -1 res))))
(defun math-compare-lists (a b)
(cond ((null a) (null b))
((null b) nil)
@ -2685,7 +2657,7 @@ If X is not an error form, return 1."
(if (Math-integer-negp a) (setq a (math-neg a)))
(if (Math-integer-negp b) (setq b (math-neg b)))
(let (c)
(if (Math-natnum-lessp a b)
(if (< a b)
(setq c b b a a c))
(while (and (consp a) (not (eq b 0)))
(setq c b

View file

@ -410,7 +410,7 @@
((and (math-num-integerp b)
(if (math-negp b)
(math-reject-arg b 'range)
(Math-natnum-lessp (setq b (math-trunc b)) 20)))
(< (setq b (math-trunc b)) 20)))
(and calc-symbolic-mode (or (math-floatp a) (math-floatp b))
(math-inexact-result))
(math-mul
@ -427,7 +427,7 @@
((and (math-num-integerp a)
(if (math-negp a)
(math-reject-arg a 'range)
(Math-natnum-lessp (setq a (math-trunc a)) 20)))
(< (setq a (math-trunc a)) 20)))
(math-sub (or math-current-beta-value (calcFunc-beta a b))
(calcFunc-betaB (math-sub 1 x) b a)))
(t

View file

@ -351,7 +351,7 @@
(if (>= ver 3)
(insert "set surface\nset nocontour\n"
"set " (if calc-graph-is-splot "" "no") "parametric\n"
"set notime\nset border\nset ztics\nset zeroaxis\n"
"set notimestamp\nset border\nset ztics\nset zeroaxis\n"
"set view 60,30,1,1\nset offsets 0,0,0,0\n"))
(setq samples-pos (point))
(insert "\n\n" str))

View file

@ -29,7 +29,6 @@
(declare-function math-looks-negp "calc-misc" (a))
(declare-function math-posp "calc-misc" (a))
(declare-function math-compare "calc-ext" (a b))
(declare-function math-compare-bignum "calc-ext" (a b))
(defmacro calc-wrapper (&rest body)
@ -174,13 +173,6 @@
(eq (nth 1 a) b)
(= (nth 2 a) 0))))
(defsubst Math-natnum-lessp (a b)
(if (consp a)
(and (consp b)
(= (math-compare-bignum (cdr a) (cdr b)) -1))
(or (consp b)
(< a b))))
(provide 'calc-macs)
;;; calc-macs.el ends here

View file

@ -370,18 +370,6 @@ If this can't be done, return NIL."
(math-isqrt (math-floor a))
(math-floor (math-sqrt a))))
(defun math-zerop-bignum (a)
(and (eq (car a) 0)
(progn
(while (eq (car (setq a (cdr a))) 0))
(null a))))
(defun math-scale-bignum-digit-size (a n) ; [L L S]
(while (> n 0)
(setq a (cons 0 a)
n (1- n)))
a)
;;; Compute the square root of a number.
;;; [T N] if possible, else [F N] if possible, else [C N]. [Public]
(defun math-sqrt (a)
@ -666,7 +654,7 @@ If this can't be done, return NIL."
(let* ((q (math-idivmod a (math-ipow guess (1- math-nri-n))))
(s (math-add (car q) (math-mul (1- math-nri-n) guess)))
(g2 (math-idivmod s math-nri-n)))
(if (Math-natnum-lessp (car g2) guess)
(if (< (car g2) guess)
(math-nth-root-int-iter a (car g2))
(cons (and (equal (car g2) guess)
(eq (cdr q) 0)
@ -1615,7 +1603,7 @@ If this can't be done, return NIL."
(math-natnump b) (not (eq b 0)))
(if (eq b 1)
(math-reject-arg x "*Logarithm base one")
(if (Math-natnum-lessp x b)
(if (< x b)
0
(cdr (math-integer-log x b))))
(math-floor (calcFunc-log x b))))

View file

@ -2100,7 +2100,7 @@ the United States."
(set-buffer calc-trail-buffer)
(unless (derived-mode-p 'calc-trail-mode)
(calc-trail-mode)
(set (make-local-variable 'calc-main-buffer) buf)))))
(setq-local calc-main-buffer buf)))))
(or (and calc-trail-pointer
(eq (marker-buffer calc-trail-pointer) calc-trail-buffer))
(with-current-buffer calc-trail-buffer

View file

@ -1788,7 +1788,7 @@ For a complete description, see the info node `Calendar/Diary'.
(setq buffer-read-only t
buffer-undo-list t
indent-tabs-mode nil)
(set (make-local-variable 'scroll-margin) 0) ; bug#10379
(setq-local scroll-margin 0) ; bug#10379
(calendar-update-mode-line)
(make-local-variable 'calendar-mark-ring)
(make-local-variable 'displayed-month) ; month in middle of window

View file

@ -839,7 +839,7 @@ LIST-ONLY is non-nil, in which case it just returns the list."
(goto-char (point-min))
(unless list-only
(let ((ol (make-overlay (point-min) (point-max) nil t nil)))
(set (make-local-variable 'diary-selective-display) t)
(setq-local diary-selective-display t)
(overlay-put ol 'invisible 'diary)
(overlay-put ol 'evaporate t)))
(dotimes (_ number)
@ -2381,10 +2381,9 @@ return a font-lock pattern matching array of MONTHS and marking SYMBOL."
;;;###autoload
(define-derived-mode diary-mode fundamental-mode "Diary"
"Major mode for editing the diary file."
(set (make-local-variable 'font-lock-defaults)
'(diary-font-lock-keywords t))
(set (make-local-variable 'comment-start) diary-comment-start)
(set (make-local-variable 'comment-end) diary-comment-end)
(setq-local font-lock-defaults '(diary-font-lock-keywords t))
(setq-local comment-start diary-comment-start)
(setq-local comment-end diary-comment-end)
(add-to-invisibility-spec '(diary . nil))
(add-hook 'after-save-hook #'diary-redraw-calendar nil t)
;; In case the file was modified externally, refresh the calendar
@ -2465,13 +2464,13 @@ Fontify the region between BEG and END, quietly unless VERBOSE is non-nil."
(define-derived-mode diary-fancy-display-mode special-mode
"Diary"
"Major mode used while displaying diary entries using Fancy Display."
(set (make-local-variable 'font-lock-defaults)
'(diary-fancy-font-lock-keywords
t nil nil nil
(font-lock-fontify-region-function
. diary-fancy-font-lock-fontify-region-function)))
(set (make-local-variable 'minor-mode-overriding-map-alist)
(list (cons t diary-fancy-overriding-map)))
(setq-local font-lock-defaults
'(diary-fancy-font-lock-keywords
t nil nil nil
(font-lock-fontify-region-function
. diary-fancy-font-lock-fontify-region-function)))
(setq-local minor-mode-overriding-map-alist
(list (cons t diary-fancy-overriding-map)))
(view-mode 1))
;; Following code from Dave Love <fx@gnu.org>.

View file

@ -140,7 +140,7 @@ The buffer is left in Command History mode."
Keybindings:
\\{command-history-mode-map}"
(lisp-mode-variables nil)
(set (make-local-variable 'revert-buffer-function) 'command-history-revert)
(setq-local revert-buffer-function 'command-history-revert)
(set-syntax-table emacs-lisp-mode-syntax-table))
(defcustom command-history-hook nil

View file

@ -1224,7 +1224,7 @@ Moves relative to START, or `comint-input-ring-index'."
(process-mark (get-buffer-process (current-buffer))))
(point-max)))
(defun comint-previous-matching-input (regexp n)
(defun comint-previous-matching-input (regexp n &optional restore)
"Search backwards through input history for match for REGEXP.
\(Previous history elements are earlier commands.)
With prefix argument N, search for Nth previous match.
@ -1235,16 +1235,24 @@ If N is negative, find the next or Nth next match."
;; Has a match been found?
(if (null pos)
(user-error "Not found")
;; If leaving the edit line, save partial input
(if (null comint-input-ring-index) ;not yet on ring
(setq comint-stored-incomplete-input
(funcall comint-get-old-input)))
(setq comint-input-ring-index pos)
(unless isearch-mode
(let ((message-log-max nil)) ; Do not write to *Messages*.
(message "History item: %d" (1+ pos))))
(comint-delete-input)
(insert (ring-ref comint-input-ring pos)))))
(if (and comint-input-ring-index
restore
(or (and (< n 0)
(< comint-input-ring-index pos))
(and (> n 0)
(> comint-input-ring-index pos))))
;; We have a wrap; restore contents.
(comint-restore-input)
;; If leaving the edit line, save partial input
(if (null comint-input-ring-index) ;not yet on ring
(setq comint-stored-incomplete-input
(funcall comint-get-old-input)))
(setq comint-input-ring-index pos)
(unless isearch-mode
(let ((message-log-max nil)) ; Do not write to *Messages*.
(message "History item: %d" (1+ pos))))
(comint-delete-input)
(insert (ring-ref comint-input-ring pos))))))
(defun comint-next-matching-input (regexp n)
"Search forwards through input history for match for REGEXP.
@ -1272,7 +1280,7 @@ If N is negative, search forwards for the -Nth following match."
comint-input-ring-index nil))
(comint-previous-matching-input
(concat "^" (regexp-quote comint-matching-input-from-input-string))
n)
n t)
(when (eq comint-move-point-for-matching-input 'after-input)
(goto-char opoint))))

View file

@ -45,7 +45,7 @@
;; dabbrev-case-replace nil t
;;
;; Set the variables you want special for your mode like this:
;; (set (make-local-variable 'dabbrev-case-replace) nil)
;; (setq-local dabbrev-case-replace nil)
;; Then you don't interfere with other modes.
;;
;; If your mode handles buffers that refers to other buffers
@ -59,10 +59,10 @@
;; Example for GNUS (when we write a reply, we want dabbrev to look in
;; the article for expansion):
;; (set (make-local-variable 'dabbrev-friend-buffer-function)
;; (lambda (buffer)
;; (with-current-buffer buffer
;; (memq major-mode '(news-reply-mode gnus-article-mode)))))
;; (setq-local dabbrev-friend-buffer-function
;; (lambda (buffer)
;; (with-current-buffer buffer
;; (memq major-mode '(news-reply-mode gnus-article-mode)))))
;; Known bugs and limitations.

View file

@ -1222,7 +1222,13 @@ This function is a no-op when Emacs is running in batch mode.
It returns t if a desktop file was loaded, nil otherwise.
\n(fn DIRNAME)"
(interactive "i\nP")
(unless noninteractive
(if (or noninteractive
(and (desktop-owner)
(= (desktop-owner) (emacs-pid))))
(message "Not reloading the desktop%s"
(if noninteractive
""
"; already loaded"))
(setq desktop-dirname
(file-name-as-directory
(expand-file-name

View file

@ -280,7 +280,7 @@ CREATE-HOOK is a hook to run after creating a frame."
;; Enable mouse tracking in emacs
(if dframe-track-mouse-function
(set (make-local-variable 'track-mouse) t)) ;this could be messy.
(setq-local track-mouse t)) ;this could be messy.
;; Override `temp-buffer-show-hook' so that help and such
;; put their stuff into a frame other than our own.
@ -290,10 +290,8 @@ CREATE-HOOK is a hook to run after creating a frame."
;; FIXME: Doesn't this get us into an inf-loop when the
;; `temp-buffer-show-function' runs `temp-buffer-show-hook'
;; (as is normally the case)?
(progn (make-local-variable 'temp-buffer-show-hook)
(setq temp-buffer-show-hook temp-buffer-show-function)))
(make-local-variable 'temp-buffer-show-function)
(setq temp-buffer-show-function 'dframe-temp-buffer-show-function)
(setq-local temp-buffer-show-hook temp-buffer-show-function))
(setq-local temp-buffer-show-function 'dframe-temp-buffer-show-function)
;; If this buffer is killed, we must make sure that we destroy
;; the frame the dedicated window is in.
(add-hook 'kill-buffer-hook (lambda ()

View file

@ -259,7 +259,7 @@ the string of command switches used as the third argument of `diff'."
(list
(minibuffer-with-setup-hook
(lambda ()
(set (make-local-variable 'minibuffer-default-add-function) nil)
(setq-local minibuffer-default-add-function nil)
(setq minibuffer-default defaults))
(read-file-name (format-prompt "Diff %s with" default current)
target-dir default t))
@ -334,7 +334,7 @@ only in the active region if `dired-mark-region' is non-nil."
(defaults (dired-dwim-target-defaults nil target-dir)))
(minibuffer-with-setup-hook
(lambda ()
(set (make-local-variable 'minibuffer-default-add-function) nil)
(setq-local minibuffer-default-add-function nil)
(setq minibuffer-default defaults))
(read-directory-name (format "Compare %s with: "
(dired-current-directory))
@ -2049,7 +2049,7 @@ Optional arg HOW-TO determines how to treat the target.
(target (expand-file-name ; fluid variable inside dired-create-files
(minibuffer-with-setup-hook
(lambda ()
(set (make-local-variable 'minibuffer-default-add-function) nil)
(setq-local minibuffer-default-add-function nil)
(setq minibuffer-default defaults))
(dired-mark-read-file-name
(format "%s %%s %s: "
@ -3013,14 +3013,14 @@ is part of a file name (i.e., has the text property `dired-filename')."
(defun dired-isearch-filenames ()
"Search for a string using Isearch only in file names in the Dired buffer."
(interactive)
(set (make-local-variable 'dired-isearch-filenames) t)
(setq-local dired-isearch-filenames t)
(isearch-forward nil t))
;;;###autoload
(defun dired-isearch-filenames-regexp ()
"Search for a regexp using Isearch only in file names in the Dired buffer."
(interactive)
(set (make-local-variable 'dired-isearch-filenames) t)
(setq-local dired-isearch-filenames t)
(isearch-forward-regexp nil t))

View file

@ -636,7 +636,7 @@ you can relist single subdirs using \\[dired-do-redisplay]."
(dired-mode dirname (or switches dired-listing-switches))
(setq mode-name "Virtual Dired"
revert-buffer-function 'dired-virtual-revert)
(set (make-local-variable 'dired-subdir-alist) nil)
(setq-local dired-subdir-alist nil)
(dired-build-subdir-alist)
(goto-char (point-min))
(dired-initial-position dirname))
@ -1226,7 +1226,7 @@ Otherwise obeys the value of `dired-vm-read-only-folders'."
(and dired-vm-read-only-folders
(not (file-writable-p fil)))))
;; So that pressing `v' inside VM does prompt within current directory:
(set (make-local-variable 'vm-folder-directory) dir)))
(setq-local vm-folder-directory dir)))
(defun dired-rmail ()
"Run RMAIL on this file."

View file

@ -2419,6 +2419,8 @@ If the current buffer can be edited with Wdired, (i.e. the major
mode is `dired-mode'), call `wdired-change-to-wdired-mode'.
Otherwise, toggle `read-only-mode'."
(interactive)
(unless (file-writable-p default-directory)
(user-error "Directory %s isn't writeable" default-directory))
(if (derived-mode-p 'dired-mode)
(wdired-change-to-wdired-mode)
(read-only-mode 'toggle)))
@ -2499,6 +2501,10 @@ directory in another window."
(defun dired-find-file ()
"In Dired, visit the file or directory named on this line."
(interactive)
(dired--find-file #'find-file (dired-get-file-for-visit)))
(defun dired--find-file (find-file-function file)
"Call FIND-FILE-FUNCTION on FILE, but bind some relevant variables."
;; Bind `find-file-run-dired' so that the command works on directories
;; too, independent of the user's setting.
(let ((find-file-run-dired t)
@ -2511,7 +2517,7 @@ directory in another window."
(if dired-auto-revert-buffer
nil
switch-to-buffer-preserve-window-point)))
(find-file (dired-get-file-for-visit))))
(funcall find-file-function file)))
(defun dired-find-alternate-file ()
"In Dired, visit file or directory on current line via `find-alternate-file'.
@ -2547,7 +2553,7 @@ respectively."
(select-window window)
(funcall find-dir-func file)))
(select-window window)
(funcall find-file-func (file-name-sans-versions file t)))))
(dired--find-file find-file-func (file-name-sans-versions file t)))))
(defun dired-mouse-find-file-other-window (event)
"In Dired, visit the file or directory name you click on in another window."
@ -2574,7 +2580,7 @@ Otherwise, display it in another buffer."
(defun dired-find-file-other-window ()
"In Dired, visit this file or directory in another window."
(interactive)
(find-file-other-window (dired-get-file-for-visit)))
(dired--find-file #'find-file-other-window (dired-get-file-for-visit)))
(defun dired-display-file ()
"In Dired, display this file or directory in another window."

View file

@ -2055,7 +2055,7 @@ See the command `doc-view-mode' for more information on this mode."
:init-value nil :keymap doc-view-presentation-mode-map
(if doc-view-presentation-mode
(progn
(set (make-local-variable 'mode-line-format) nil)
(setq-local mode-line-format nil)
(doc-view-fit-page-to-window)
;; (doc-view-convert-all-pages)
)

View file

@ -202,8 +202,7 @@ Electric Buffer Menu mode is a minor mode which is automatically
enabled and disabled by the \\[electric-buffer-list] command.
See the documentation of `electric-buffer-list' for details."
(setq mode-line-buffer-identification "Electric Buffer List")
(set (make-local-variable 'Helper-return-blurb)
"return to buffer editing"))
(setq-local Helper-return-blurb "return to buffer editing"))
(define-obsolete-function-alias 'Electric-buffer-menu-mode
'electric-buffer-menu-mode "24.3")
@ -270,8 +269,8 @@ Return to Electric Buffer Menu when done."
(when (derived-mode-p 'electric-buffer-menu-mode)
;; Make sure we have an overlay to use.
(or electric-buffer-overlay
(set (make-local-variable 'electric-buffer-overlay)
(make-overlay (point) (point))))
(setq-local electric-buffer-overlay
(make-overlay (point) (point))))
(move-overlay electric-buffer-overlay
(line-beginning-position)
(line-end-position))

View file

@ -151,9 +151,9 @@ With a prefix argument, format the macro in a more concise way."
(setq buffer-read-only nil)
(setq major-mode 'edmacro-mode)
(setq mode-name "Edit Macro")
(set (make-local-variable 'edmacro-original-buffer) oldbuf)
(set (make-local-variable 'edmacro-finish-hook) finish-hook)
(set (make-local-variable 'edmacro-store-hook) store-hook)
(setq-local edmacro-original-buffer oldbuf)
(setq-local edmacro-finish-hook finish-hook)
(setq-local edmacro-store-hook store-hook)
(erase-buffer)
(insert ";; Keyboard Macro Editor. Press C-c C-c to finish; "
"press C-x k RET to cancel.\n")

View file

@ -410,8 +410,18 @@ the specializer used will be the one returned by BODY."
;;;###autoload
(defmacro cl-defmethod (name args &rest body)
"Define a new method for generic function NAME.
I.e. it defines the implementation of NAME to use for invocations where the
values of the dispatch arguments match the specified TYPEs.
This it defines an implementation of NAME to use for invocations
of specific types of arguments.
ARGS is a list of dispatch arguments (see `cl-defun'), but where
each variable element is either just a single variable name VAR,
or a list on the form (VAR TYPE).
For instance:
(cl-defmethod foo (bar (format-string string) &optional zot)
(format format-string bar))
The dispatch arguments have to be among the mandatory arguments, and
all methods of NAME have to use the same set of arguments for dispatch.
Each dispatch argument and TYPE are specified in ARGS where the corresponding

View file

@ -467,7 +467,6 @@ This holds the results of the last documentation request."
(defun eldoc--format-doc-buffer (docs)
"Ensure DOCS are displayed in an *eldoc* buffer."
(interactive (list t))
(with-current-buffer (if (buffer-live-p eldoc--doc-buffer)
eldoc--doc-buffer
(setq eldoc--doc-buffer

View file

@ -558,7 +558,8 @@ Return nil if there are no more forms, t otherwise."
(when . elint-check-conditional-form)
(unless . elint-check-conditional-form)
(and . elint-check-conditional-form)
(or . elint-check-conditional-form))
(or . elint-check-conditional-form)
(require . elint-require-form))
"Functions to call when some special form should be linted.")
(defun elint-form (form env &optional nohandler)
@ -953,6 +954,13 @@ Does basic handling of `featurep' tests."
(elint-form form env t))))
env)
(defun elint-require-form (form _env)
"Load `require'd files."
(pcase form
(`(require ',x)
(require x)))
nil)
;;;
;;; Message functions
;;;

View file

@ -274,7 +274,7 @@ DATA is displayed to the user and should state the reason for skipping."
It should only be stopped when ran from inside ert--run-test-internal."
(when (and (not (symbolp debugger)) ; only run on anonymous debugger
(memq error-symbol '(ert-test-failed ert-test-skipped)))
(funcall debugger 'error data)))
(funcall debugger 'error (list error-symbol data))))
(defun ert--special-operator-p (thing)
"Return non-nil if THING is a symbol naming a special operator."

View file

@ -38,7 +38,7 @@
(define-abbrev-table 'lisp-mode-abbrev-table ()
"Abbrev table for Lisp mode.")
(defvar lisp--mode-syntax-table
(defvar lisp-data-mode-syntax-table
(let ((table (make-syntax-table))
(i 0))
(while (< i ?0)
@ -77,11 +77,13 @@
(modify-syntax-entry ?\\ "\\ " table)
(modify-syntax-entry ?\( "() " table)
(modify-syntax-entry ?\) ")( " table)
(modify-syntax-entry ?\[ "(]" table)
(modify-syntax-entry ?\] ")[" table)
table)
"Parent syntax table used in Lisp modes.")
(defvar lisp-mode-syntax-table
(let ((table (make-syntax-table lisp--mode-syntax-table)))
(let ((table (make-syntax-table lisp-data-mode-syntax-table)))
(modify-syntax-entry ?\[ "_ " table)
(modify-syntax-entry ?\] "_ " table)
(modify-syntax-entry ?# "' 14" table)
@ -669,7 +671,7 @@ font-lock keywords will not be case sensitive."
(define-derived-mode lisp-data-mode prog-mode "Lisp-Data"
"Major mode for buffers holding data written in Lisp syntax."
:group 'lisp
(lisp-mode-variables t t nil)
(lisp-mode-variables nil t nil)
(setq-local electric-quote-string t)
(setq imenu-case-fold-search nil))

View file

@ -0,0 +1,301 @@
;;; memory-report.el --- Short function summaries -*- lexical-binding: t -*-
;; Copyright (C) 2020 Free Software Foundation, Inc.
;; Keywords: lisp, help
;; This file is part of GNU Emacs.
;; GNU Emacs is free software: you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
;; the Free Software Foundation, either version 3 of the License, or
;; (at your option) any later version.
;; GNU Emacs is distributed in the hope that it will be useful,
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
;; along with GNU Emacs. If not, see <https://www.gnu.org/licenses/>.
;;; Commentary:
;; Todo (possibly): Font cache, regexp cache, bidi cache, various
;; buffer caches (newline cache, free_region_cache, etc), composition
;; cache, face cache.
;;; Code:
(require 'seq)
(require 'subr-x)
(eval-when-compile (require 'cl-lib))
(defvar memory-report--type-size (make-hash-table))
;;;###autoload
(defun memory-report ()
"Generate a report of how Emacs is using memory.
This report is approximate, and will commonly over-count memory
usage by variables, because shared data structures will usually
by counted more than once."
(interactive)
(pop-to-buffer "*Memory Report*")
(special-mode)
(button-mode 1)
(setq truncate-lines t)
(message "Gathering data...")
(let ((reports (append (memory-report--garbage-collect)
(memory-report--image-cache)
(memory-report--buffers)
(memory-report--largest-variables)))
(inhibit-read-only t)
summaries details)
(message "Gathering data...done")
(erase-buffer)
(insert (propertize "Estimated Emacs Memory Usage\n\n" 'face 'bold))
(dolist (report reports)
(if (listp report)
(push report summaries)
(push report details)))
(dolist (summary (seq-sort (lambda (e1 e2)
(> (cdr e1) (cdr e2)))
summaries))
(insert (format "%s %s\n"
(memory-report--format (cdr summary))
(car summary))))
(insert "\n")
(dolist (detail (nreverse details))
(insert detail "\n")))
(goto-char (point-min)))
(defun memory-report-object-size (object)
"Return the size of OBJECT in bytes."
(unless memory-report--type-size
(memory-report--garbage-collect))
(memory-report--object-size (make-hash-table :test #'eq) object))
(defun memory-report--size (type)
(or (gethash type memory-report--type-size)
(gethash 'object memory-report--type-size)))
(defun memory-report--set-size (elems)
(setf (gethash 'string memory-report--type-size)
(cadr (assq 'strings elems)))
(setf (gethash 'cons memory-report--type-size)
(cadr (assq 'conses elems)))
(setf (gethash 'symbol memory-report--type-size)
(cadr (assq 'symbols elems)))
(setf (gethash 'object memory-report--type-size)
(cadr (assq 'vectors elems)))
(setf (gethash 'float memory-report--type-size)
(cadr (assq 'floats elems)))
(setf (gethash 'buffer memory-report--type-size)
(cadr (assq 'buffers elems))))
(defun memory-report--garbage-collect ()
(let ((elems (garbage-collect)))
(memory-report--set-size elems)
(let ((data (list
(list 'strings
(+ (memory-report--gc-elem elems 'strings)
(memory-report--gc-elem elems 'string-bytes)))
(list 'vectors
(+ (memory-report--gc-elem elems 'vectors)
(memory-report--gc-elem elems 'vector-slots)))
(list 'floats (memory-report--gc-elem elems 'floats))
(list 'conses (memory-report--gc-elem elems 'conses))
(list 'symbols (memory-report--gc-elem elems 'symbols))
(list 'intervals (memory-report--gc-elem elems 'intervals))
(list 'buffer-objects
(memory-report--gc-elem elems 'buffers)))))
(list (cons "Overall Object Memory Usage"
(seq-reduce #'+ (mapcar (lambda (elem)
(* (nth 1 elem) (nth 2 elem)))
elems)
0))
(cons "Reserved (But Unused) Object Memory"
(seq-reduce #'+ (mapcar (lambda (elem)
(if (nth 3 elem)
(* (nth 1 elem) (nth 3 elem))
0))
elems)
0))
(with-temp-buffer
(insert (propertize "Object Storage\n\n" 'face 'bold))
(dolist (object (seq-sort (lambda (e1 e2)
(> (cadr e1) (cadr e2)))
data))
(insert (format "%s %s\n"
(memory-report--format (cadr object))
(capitalize (symbol-name (car object))))))
(buffer-string))))))
(defun memory-report--largest-variables ()
(let ((variables nil))
(mapatoms
(lambda (symbol)
(when (boundp symbol)
(let ((size (memory-report--object-size
(make-hash-table :test #'eq)
(symbol-value symbol))))
(when (> size 1000)
(push (cons symbol size) variables)))))
obarray)
(list
(cons (propertize "Memory Used By Global Variables"
'help-echo "Upper bound; mutually overlapping data from different variables are counted several times")
(seq-reduce #'+ (mapcar #'cdr variables) 0))
(with-temp-buffer
(insert (propertize "Largest Variables\n\n" 'face 'bold))
(cl-loop for i from 1 upto 20
for (symbol . size) in (seq-sort (lambda (e1 e2)
(> (cdr e1) (cdr e2)))
variables)
do (insert (memory-report--format size)
" "
(symbol-name symbol)
"\n"))
(buffer-string)))))
(defun memory-report--object-size (counted value)
(if (gethash value counted)
0
(setf (gethash value counted) t)
(memory-report--object-size-1 counted value)))
(cl-defgeneric memory-report--object-size-1 (_counted _value)
0)
(cl-defmethod memory-report--object-size-1 (_ (value symbol))
;; Don't count global symbols -- makes sizes of lists of symbols too
;; heavey.
(if (intern-soft value obarray)
0
(memory-report--size 'symbol)))
(cl-defmethod memory-report--object-size-1 (_ (_value buffer))
(memory-report--size 'buffer))
(cl-defmethod memory-report--object-size-1 (counted (value string))
(+ (memory-report--size 'string)
(string-bytes value)
(memory-report--interval-size counted (object-intervals value))))
(defun memory-report--interval-size (counted intervals)
;; We get a list back of intervals, but only count the "inner list"
;; (i.e., the actual text properties), and add the size of the
;; intervals themselves.
(+ (* (memory-report--size 'interval) (length intervals))
(seq-reduce #'+ (mapcar
(lambda (interval)
(memory-report--object-size counted (nth 2 interval)))
intervals)
0)))
(cl-defmethod memory-report--object-size-1 (counted (value list))
(let ((total 0)
(size (memory-report--size 'cons)))
(while value
(cl-incf total size)
(setf (gethash value counted) t)
(when (car value)
(cl-incf total (memory-report--object-size counted (car value))))
(if (cdr value)
(if (consp (cdr value))
(setq value (cdr value))
(cl-incf total (memory-report--object-size counted (cdr value)))
(setq value nil))
(setq value nil)))
total))
(cl-defmethod memory-report--object-size-1 (counted (value vector))
(let ((total (+ (memory-report--size 'vector)
(* (memory-report--size 'object) (length value)))))
(cl-loop for elem across value
do (setf (gethash elem counted) t)
(cl-incf total (memory-report--object-size counted elem)))
total))
(cl-defmethod memory-report--object-size-1 (counted (value hash-table))
(let ((total (+ (memory-report--size 'vector)
(* (memory-report--size 'object) (hash-table-size value)))))
(maphash
(lambda (key elem)
(setf (gethash key counted) t)
(setf (gethash elem counted) t)
(cl-incf total (memory-report--object-size counted key))
(cl-incf total (memory-report--object-size counted elem)))
value)
total))
(defun memory-report--format (bytes)
(setq bytes (/ bytes 1024.0))
(let ((units '("kB" "MB" "GB" "TB")))
(while (>= bytes 1024)
(setq bytes (/ bytes 1024.0))
(setq units (cdr units)))
(format "%6.1f%s" bytes (car units))))
(defun memory-report--gc-elem (elems type)
(* (nth 1 (assq type elems))
(nth 2 (assq type elems))))
(defun memory-report--buffers ()
(let ((buffers (mapcar (lambda (buffer)
(cons buffer (memory-report--buffer buffer)))
(buffer-list))))
(list (cons "Total Buffer Memory Usage"
(seq-reduce #'+ (mapcar #'cdr buffers) 0))
(with-temp-buffer
(insert (propertize "Largest Buffers\n\n" 'face 'bold))
(cl-loop for i from 1 upto 20
for (buffer . size) in (seq-sort (lambda (e1 e2)
(> (cdr e1) (cdr e2)))
buffers)
do (insert (memory-report--format size)
" "
(button-buttonize
(buffer-name buffer)
#'memory-report--buffer-details buffer)
"\n"))
(buffer-string)))))
(defun memory-report--buffer-details (buffer)
(with-current-buffer buffer
(apply
#'message
"Buffer text: %s; variables: %s; text properties: %s; overlays: %s"
(mapcar #'string-trim (mapcar #'memory-report--format
(memory-report--buffer-data buffer))))))
(defun memory-report--buffer (buffer)
(seq-reduce #'+ (memory-report--buffer-data buffer) 0))
(defun memory-report--buffer-data (buffer)
(with-current-buffer buffer
(list (save-restriction
(widen)
(+ (position-bytes (point-max))
(- (position-bytes (point-min)))
(gap-size)))
(seq-reduce #'+ (mapcar (lambda (elem)
(if (cdr elem)
(memory-report--object-size
(make-hash-table :test #'eq)
(cdr elem))
0))
(buffer-local-variables buffer))
0)
(memory-report--object-size (make-hash-table :test #'eq)
(object-intervals buffer))
(memory-report--object-size (make-hash-table :test #'eq)
(overlay-lists)))))
(defun memory-report--image-cache ()
(list (cons "Total Image Cache Size" (image-cache-size))))
(provide 'memory-report)
;;; memory-report.el ends here

View file

@ -409,7 +409,8 @@ of the elements of LIST is performed as if by `pcase-let'.
(dolist (case cases)
(unless (or (memq case used-cases)
(memq (car case) pcase--dontwarn-upats))
(message "Redundant pcase pattern: %S" (car case))))
(message "pcase pattern %S shadowed by previous pcase pattern"
(car case))))
(macroexp-let* defs main))))
(defun pcase--macroexpand (pat)

View file

@ -122,7 +122,7 @@ Using `thunk-let' and `thunk-let*' requires `lexical-binding'."
(declare (indent 1) (debug let))
(cl-reduce
(lambda (expr binding) `(thunk-let (,binding) ,expr))
(nreverse bindings)
(reverse bindings)
:initial-value (macroexp-progn body)))
;; (defalias 'lazy-let #'thunk-let)

View file

@ -309,7 +309,8 @@ encryption is used."
If no one is selected, symmetric encryption will be performed. "
recipients)
(if epa-file-encrypt-to
(epg-list-keys context recipients)))))
(epg--filter-revoked-keys
(epg-list-keys context recipients))))))
(error
(epa-display-error context)
(if (setq entry (assoc file epa-file-passphrase-alist))

View file

@ -1382,6 +1382,13 @@ NAME is either a string or a list of strings."
(setq pointer (cdr pointer)))
keys))
(defun epg--filter-revoked-keys (keys)
(seq-remove (lambda (key)
(seq-find (lambda (user)
(eq (epg-user-id-validity user) 'revoked))
(epg-key-user-id-list key)))
keys))
(defun epg--args-from-sig-notations (notations)
(apply #'nconc
(mapcar

View file

@ -446,7 +446,7 @@ local, and sets it to FACE."
(setq specs (car specs)))
(if (null specs)
(buffer-face-mode 0)
(set (make-local-variable 'buffer-face-mode-face) specs)
(setq-local buffer-face-mode-face specs)
(buffer-face-mode t)))
;;;###autoload
@ -470,7 +470,7 @@ buffer local, and set it to SPECS."
(if (or (null specs)
(and buffer-face-mode (equal buffer-face-mode-face specs)))
(buffer-face-mode 0)
(set (make-local-variable 'buffer-face-mode-face) specs)
(setq-local buffer-face-mode-face specs)
(buffer-face-mode t)))
(defun buffer-face-mode-invoke (specs arg &optional interactive)

View file

@ -597,7 +597,7 @@ settings being applied, but still respect file-local ones.")
;; This is an odd variable IMO.
;; You might wonder why it is needed, when we could just do:
;; (set (make-local-variable 'enable-local-variables) nil)
;; (setq-local enable-local-variables nil)
;; These two are not precisely the same.
;; Setting this variable does not cause -*- mode settings to be
;; ignored, whereas setting enable-local-variables does.
@ -2424,9 +2424,7 @@ Do you want to revisit the file normally now? ")))
;; this is a permanent local, the major mode won't eliminate it.
(and backup-enable-predicate
(not (funcall backup-enable-predicate buffer-file-name))
(progn
(make-local-variable 'backup-inhibited)
(setq backup-inhibited t)))
(setq-local backup-inhibited t))
(if rawfile
(progn
(set-buffer-multibyte nil)
@ -3525,7 +3523,7 @@ n -- to ignore the local variables list.")
(let ((print-escape-newlines t))
(prin1 (cdr elt) buf))
(insert "\n"))
(set (make-local-variable 'cursor-type) nil)
(setq-local cursor-type nil)
(set-buffer-modified-p nil)
(goto-char (point-min)))
@ -4497,9 +4495,7 @@ the old visited file has been renamed to the new name FILENAME."
(and buffer-file-name
backup-enable-predicate
(not (funcall backup-enable-predicate buffer-file-name))
(progn
(make-local-variable 'backup-inhibited)
(setq backup-inhibited t)))
(setq-local backup-inhibited t))
(let ((oauto buffer-auto-save-file-name))
(cond ((null filename)
(setq buffer-auto-save-file-name nil))
@ -6128,6 +6124,9 @@ This undoes all changes since the file was visited or saved.
With a prefix argument, offer to revert from latest auto-save file, if
that is more recent than the visited file.
Reverting a buffer will try to preserve markers in the buffer;
see the Info node `(elisp)Reverting' for details.
This command also implements an interface for special buffers
that contain text that doesn't come from a file, but reflects
some other data instead (e.g. Dired buffers, `buffer-list'
@ -6224,7 +6223,7 @@ Non-file buffers need a custom function."
;; Run after-revert-hook as it was before we reverted.
(setq-default revert-buffer-internal-hook global-hook)
(if local-hook
(set (make-local-variable 'revert-buffer-internal-hook)
(setq-local revert-buffer-internal-hook
local-hook)
(kill-local-variable 'revert-buffer-internal-hook))
(run-hooks 'revert-buffer-internal-hook))

View file

@ -1336,8 +1336,7 @@ Use the viewer defined in EV-ENTRY (a valid element of
(progn
(switch-to-buffer (format "Filesets: %s %s" vwr file))
(insert output)
(make-local-variable 'filesets-output-buffer-flag)
(setq filesets-output-buffer-flag t)
(setq-local filesets-output-buffer-flag t)
(set-visited-file-name file t)
(when oh
(run-hooks 'oh))

View file

@ -223,11 +223,10 @@ it finishes, type \\[kill-find]."
(set-keymap-parent map (current-local-map))
(define-key map "\C-c\C-k" 'kill-find)
(use-local-map map))
(make-local-variable 'dired-sort-inhibit)
(setq dired-sort-inhibit t)
(set (make-local-variable 'revert-buffer-function)
`(lambda (ignore-auto noconfirm)
(find-dired ,dir ,find-args)))
(setq-local dired-sort-inhibit t)
(setq-local revert-buffer-function
`(lambda (ignore-auto noconfirm)
(find-dired ,dir ,find-args)))
;; Set subdir-alist so that Tree Dired will work:
(if (fboundp 'dired-simple-subdir-alist)
;; will work even with nested dired format (dired-nstd.el,v 1.15
@ -235,9 +234,9 @@ it finishes, type \\[kill-find]."
(dired-simple-subdir-alist)
;; else we have an ancient tree dired (or classic dired, where
;; this does no harm)
(set (make-local-variable 'dired-subdir-alist)
(list (cons default-directory (point-min-marker)))))
(set (make-local-variable 'dired-subdir-switches) find-ls-subdir-switches)
(setq-local dired-subdir-alist
(list (cons default-directory (point-min-marker)))))
(setq-local dired-subdir-switches find-ls-subdir-switches)
(setq buffer-read-only nil)
;; Subdir headlerline must come first because the first marker in
;; subdir-alist points there.

View file

@ -212,21 +212,17 @@ It is a function which takes two arguments, the directory and its parent."
(use-local-map (append (make-sparse-keymap) (current-local-map)))
(make-local-variable 'find-lisp-file-predicate)
(setq find-lisp-file-predicate file-predicate)
(make-local-variable 'find-lisp-directory-predicate)
(setq find-lisp-directory-predicate directory-predicate)
(make-local-variable 'find-lisp-regexp)
(setq find-lisp-regexp regexp)
(setq-local find-lisp-file-predicate file-predicate)
(setq-local find-lisp-directory-predicate directory-predicate)
(setq-local find-lisp-regexp regexp)
(make-local-variable 'revert-buffer-function)
(setq revert-buffer-function
(lambda (_ignore1 _ignore2)
(find-lisp-insert-directory
default-directory
find-lisp-file-predicate
find-lisp-directory-predicate
'ignore)))
(setq-local revert-buffer-function
(lambda (_ignore1 _ignore2)
(find-lisp-insert-directory
default-directory
find-lisp-file-predicate
find-lisp-directory-predicate
'ignore)))
;; Set subdir-alist so that Tree Dired will work:
(if (fboundp 'dired-simple-subdir-alist)
@ -235,8 +231,8 @@ It is a function which takes two arguments, the directory and its parent."
(dired-simple-subdir-alist)
;; else we have an ancient tree dired (or classic dired, where
;; this does no harm)
(set (make-local-variable 'dired-subdir-alist)
(list (cons default-directory (point-min-marker)))))
(setq-local dired-subdir-alist
(list (cons default-directory (point-min-marker)))))
(find-lisp-insert-directory
dir file-predicate directory-predicate 'ignore)
(goto-char (point-min))

View file

@ -448,7 +448,7 @@ FILE should be in a form suitable for passing to `locate-library'."
:syntax-table finder-mode-syntax-table
(setq buffer-read-only t
buffer-undo-list t)
(set (make-local-variable 'finder-headmark) nil))
(setq-local finder-headmark nil))
(defun finder-summary ()
"Summarize basic Finder commands."

View file

@ -160,8 +160,8 @@ this function onto `change-major-mode-hook'."
(defun font-lock-default-function (mode)
;; Turn on Font Lock mode.
(when mode
(set (make-local-variable 'char-property-alias-alist)
(copy-tree char-property-alias-alist))
(setq-local char-property-alias-alist
(copy-tree char-property-alias-alist))
;; Add `font-lock-face' as an alias for the `face' property.
(let ((elt (assq 'face char-property-alias-alist)))
(if elt
@ -171,8 +171,8 @@ this function onto `change-major-mode-hook'."
;; Turn off Font Lock mode.
(unless mode
;; Remove `font-lock-face' as an alias for the `face' property.
(set (make-local-variable 'char-property-alias-alist)
(copy-tree char-property-alias-alist))
(setq-local char-property-alias-alist
(copy-tree char-property-alias-alist))
(let ((elt (assq 'face char-property-alias-alist)))
(when elt
(setcdr elt (remq 'font-lock-face (cdr elt)))

View file

@ -152,8 +152,8 @@
;;
;; (add-hook 'foo-mode-hook
;; (lambda ()
;; (set (make-local-variable 'font-lock-defaults)
;; '(foo-font-lock-keywords t))))
;; (setq-local font-lock-defaults
;; '(foo-font-lock-keywords t))))
;;;; Adding Font Lock support for modes:
@ -173,8 +173,8 @@
;;
;; and within `bar-mode' there could be:
;;
;; (set (make-local-variable 'font-lock-defaults)
;; '(bar-font-lock-keywords nil t))
;; (setq-local font-lock-defaults
;; '(bar-font-lock-keywords nil t))
;; What is fontification for? You might say, "It's to make my code look nice."
;; I think it should be for adding information in the form of cues. These cues
@ -733,7 +733,7 @@ see the variables `c-font-lock-extra-types', `c++-font-lock-extra-types',
;; font-lock-mode it only enabled the font-core.el part, not the
;; font-lock-mode-internal. Try again.
(font-lock-mode -1)
(set (make-local-variable 'font-lock-defaults) '(nil t))
(setq-local font-lock-defaults '(nil t))
(font-lock-mode 1))
;; Otherwise set or add the keywords now.
;; This is a no-op if it has been done already in this buffer
@ -933,18 +933,15 @@ The value of this variable is used when Font Lock mode is turned on."
;; Prepare for jit-lock
(remove-hook 'after-change-functions
#'font-lock-after-change-function t)
(set (make-local-variable 'font-lock-flush-function)
#'jit-lock-refontify)
(set (make-local-variable 'font-lock-ensure-function)
#'jit-lock-fontify-now)
(setq-local font-lock-flush-function #'jit-lock-refontify)
(setq-local font-lock-ensure-function #'jit-lock-fontify-now)
;; Prevent font-lock-fontify-buffer from fontifying eagerly the whole
;; buffer. This is important for things like CWarn mode which
;; adds/removes a few keywords and does a refontify (which takes ages on
;; large files).
(set (make-local-variable 'font-lock-fontify-buffer-function)
#'jit-lock-refontify)
(setq-local font-lock-fontify-buffer-function #'jit-lock-refontify)
;; Don't fontify eagerly (and don't abort if the buffer is large).
(set (make-local-variable 'font-lock-fontified) t)
(setq-local font-lock-fontified t)
;; Use jit-lock.
(jit-lock-register #'font-lock-fontify-region
(not font-lock-keywords-only))
@ -1558,7 +1555,7 @@ START should be at the beginning of a line."
(unless parse-sexp-lookup-properties
;; We wouldn't go through so much trouble if we didn't intend to use those
;; properties, would we?
(set (make-local-variable 'parse-sexp-lookup-properties) t))
(setq-local parse-sexp-lookup-properties t))
;; If `font-lock-syntactic-keywords' is a symbol, get the real keywords.
(when (symbolp font-lock-syntactic-keywords)
(setq font-lock-syntactic-keywords (font-lock-eval-keywords
@ -1942,8 +1939,8 @@ Sets various variables using `font-lock-defaults' and
(set (make-local-variable (car x)) (cdr x)))
;; Set up `font-lock-keywords' last because its value might depend
;; on other settings.
(set (make-local-variable 'font-lock-keywords)
(font-lock-eval-keywords keywords))
(setq-local font-lock-keywords
(font-lock-eval-keywords keywords))
;; Local fontification?
(while local
(font-lock-add-keywords nil (car (car local)) (cdr (car local)))

View file

@ -237,9 +237,8 @@ For most purposes, consider using `format-encode-region' instead."
;; delete the buffer once the write is done, but do
;; it after running to-fn so it doesn't affect
;; write-region calls in to-fn.
(set (make-local-variable
'write-region-post-annotation-function)
'kill-buffer)))
(setq-local write-region-post-annotation-function
#'kill-buffer)))
nil)
;; Otherwise just call function, it will return annotations.
(funcall to-fn from to orig-buf)))))

View file

@ -454,7 +454,7 @@ manipulated as follows:
(symbol-name major-mode))
(match-string 1 (symbol-name major-mode))))
(mode (intern (format "gnus-agent-%s-mode" buffer))))
(set (make-local-variable 'gnus-agent-mode) t)
(setq-local gnus-agent-mode t)
(set mode nil)
(set (make-local-variable mode) t)
;; Set up the menu.
@ -1056,8 +1056,8 @@ article's mark is toggled."
(defun gnus-agent-get-undownloaded-list ()
"Construct list of articles that have not been downloaded."
(let ((gnus-command-method (gnus-find-method-for-group gnus-newsgroup-name)))
(when (set (make-local-variable 'gnus-newsgroup-agentized)
(gnus-agent-method-p gnus-command-method))
(when (setq-local gnus-newsgroup-agentized
(gnus-agent-method-p gnus-command-method))
(let* ((alist (gnus-agent-load-alist gnus-newsgroup-name))
(headers (sort (mapcar (lambda (h)
(mail-header-number h))
@ -1440,7 +1440,7 @@ downloaded into the agent."
(let ((file (gnus-agent-lib-file "history")))
(when (file-exists-p file)
(nnheader-insert-file-contents file))
(set (make-local-variable 'gnus-agent-file-name) file))))
(setq-local gnus-agent-file-name file))))
(defun gnus-agent-close-history ()
(when (gnus-buffer-live-p gnus-agent-current-history)

View file

@ -3850,8 +3850,7 @@ This format is defined by the `gnus-article-time-format' variable."
(unless gnus-article-emphasis-alist
(let ((name (and gnus-newsgroup-name
(gnus-group-real-name gnus-newsgroup-name))))
(make-local-variable 'gnus-article-emphasis-alist)
(setq gnus-article-emphasis-alist
(setq-local gnus-article-emphasis-alist
(nconc
(let ((alist gnus-group-highlight-words-alist) elem highlight)
(while (setq elem (pop alist))
@ -4495,10 +4494,10 @@ commands:
(when (gnus-visual-p 'article-menu 'menu)
(gnus-article-make-menu-bar)
(when gnus-summary-tool-bar-map
(set (make-local-variable 'tool-bar-map) gnus-summary-tool-bar-map)))
(setq-local tool-bar-map gnus-summary-tool-bar-map)))
(gnus-update-format-specifications nil 'article-mode)
(set (make-local-variable 'page-delimiter) gnus-page-delimiter)
(set (make-local-variable 'gnus-page-broken) nil)
(setq-local page-delimiter gnus-page-delimiter)
(setq-local gnus-page-broken nil)
(make-local-variable 'gnus-article-current-summary)
(make-local-variable 'gnus-article-mime-handles)
(make-local-variable 'gnus-article-decoded-p)
@ -4507,13 +4506,12 @@ commands:
(make-local-variable 'gnus-article-image-alist)
(make-local-variable 'gnus-article-charset)
(make-local-variable 'gnus-article-ignored-charsets)
(set (make-local-variable 'bookmark-make-record-function)
'gnus-summary-bookmark-make-record)
(setq-local bookmark-make-record-function 'gnus-summary-bookmark-make-record)
;; Prevent Emacs from displaying non-break space with
;; `nobreak-space' face.
(set (make-local-variable 'nobreak-char-display) nil)
(setq-local nobreak-char-display nil)
;; Enable `gnus-article-remove-images' to delete images shr.el renders.
(set (make-local-variable 'shr-put-image-function) 'gnus-shr-put-image)
(setq-local shr-put-image-function 'gnus-shr-put-image)
(unless gnus-article-show-cursor
(setq cursor-in-non-selected-windows nil))
(gnus-set-default-directory)
@ -4557,7 +4555,7 @@ commands:
t)))
(let ((summary gnus-summary-buffer))
(with-current-buffer name
(set (make-local-variable 'gnus-article-edit-mode) nil)
(setq-local gnus-article-edit-mode nil)
(gnus-article-stop-animations)
(when gnus-article-mime-handles
(mm-destroy-parts gnus-article-mime-handles)
@ -4568,14 +4566,14 @@ commands:
(setq buffer-read-only t)
(unless (derived-mode-p 'gnus-article-mode)
(gnus-article-mode))
(set (make-local-variable 'gnus-summary-buffer) summary)
(setq-local gnus-summary-buffer summary)
(setq truncate-lines gnus-article-truncate-lines)
(current-buffer)))
(let ((summary gnus-summary-buffer))
(with-current-buffer (gnus-get-buffer-create name)
(gnus-article-mode)
(setq truncate-lines gnus-article-truncate-lines)
(set (make-local-variable 'gnus-summary-buffer) summary)
(setq-local gnus-summary-buffer summary)
(gnus-summary-set-local-parameters gnus-newsgroup-name)
(when article-lapsed-timer
(gnus-stop-date-timer))
@ -5036,7 +5034,7 @@ and `gnus-mime-delete-part', and not provided at run-time normally."
(setq gnus-article-mime-handles nil)
(let ((mbl1 mml-buffer-list))
(setq mml-buffer-list mbl)
(set (make-local-variable 'mml-buffer-list) mbl1))
(setq-local mml-buffer-list mbl1))
(add-hook 'kill-buffer-hook 'mml-destroy-buffers t t)))
`(lambda (no-highlight)
(let ((mail-parse-charset (or gnus-article-charset
@ -6902,8 +6900,8 @@ then we display only bindings that start with that prefix."
(setq draft gnus-draft-mode)))
(with-temp-buffer
(use-local-map keymap)
(set (make-local-variable 'gnus-agent-summary-mode) agent)
(set (make-local-variable 'gnus-draft-mode) draft)
(setq-local gnus-agent-summary-mode agent)
(setq-local gnus-draft-mode draft)
(describe-bindings prefix))
(let ((item `((lambda (prefix)
(with-current-buffer ,(current-buffer)
@ -7247,10 +7245,9 @@ This is an extended text-mode.
\\{gnus-article-edit-mode-map}"
(make-local-variable 'gnus-article-edit-done-function)
(make-local-variable 'gnus-prev-winconf)
(set (make-local-variable 'font-lock-defaults)
'(message-font-lock-keywords t))
(set (make-local-variable 'mail-header-separator) "")
(set (make-local-variable 'gnus-article-edit-mode) t)
(setq-local font-lock-defaults '(message-font-lock-keywords t))
(setq-local mail-header-separator "")
(setq-local gnus-article-edit-mode t)
(mml-mode)
(setq buffer-read-only nil)
(buffer-enable-undo)

View file

@ -49,18 +49,15 @@ if that value is non-nil."
;; Emacs stuff:
(when (and (facep 'custom-button-face)
(facep 'custom-button-pressed-face))
(set (make-local-variable 'widget-button-face)
'custom-button-face)
(set (make-local-variable 'widget-button-pressed-face)
'custom-button-pressed-face)
(set (make-local-variable 'widget-mouse-face)
'custom-button-pressed-face))
(setq-local widget-button-face 'custom-button-face)
(setq-local widget-button-pressed-face 'custom-button-pressed-face)
(setq-local widget-mouse-face 'custom-button-pressed-face))
(when (and (boundp 'custom-raised-buttons)
(symbol-value 'custom-raised-buttons))
(set (make-local-variable 'widget-push-button-prefix) "")
(set (make-local-variable 'widget-push-button-suffix) "")
(set (make-local-variable 'widget-link-prefix) "")
(set (make-local-variable 'widget-link-suffix) "")))
(setq-local widget-push-button-prefix "")
(setq-local widget-push-button-suffix "")
(setq-local widget-link-prefix "")
(setq-local widget-link-suffix "")))
;;; Group Customization:
@ -380,10 +377,8 @@ category."))
(gnus-kill-buffer "*Gnus Customize*")
(switch-to-buffer (gnus-get-buffer-create "*Gnus Customize*"))
(gnus-custom-mode)
(make-local-variable 'gnus-custom-group)
(setq gnus-custom-group group)
(make-local-variable 'gnus-custom-topic)
(setq gnus-custom-topic topic)
(setq-local gnus-custom-group group)
(setq-local gnus-custom-topic topic)
(buffer-disable-undo)
(widget-insert "Customize the ")
(if group
@ -848,8 +843,7 @@ This can be changed using the `\\[gnus-score-change-score-file]' command."
(kill-buffer (gnus-get-buffer-create "*Gnus Customize*"))
(switch-to-buffer (gnus-get-buffer-create "*Gnus Customize*"))
(gnus-custom-mode)
(make-local-variable 'gnus-custom-score-alist)
(setq gnus-custom-score-alist scores)
(setq-local gnus-custom-score-alist scores)
(widget-insert "Customize the ")
(widget-create 'info-link
:help-echo "Push me to learn more."
@ -867,8 +861,7 @@ Check the [ ] for the entries you want to apply to this score file, then
edit the value to suit your taste. Don't forget to mark the checkbox,
if you do all your changes will be lost. ")
(widget-insert "\n\n")
(make-local-variable 'gnus-custom-scores)
(setq gnus-custom-scores
(setq-local gnus-custom-scores
(widget-create 'group
:value scores
`(checklist :inline t
@ -1052,10 +1045,9 @@ articles in the thread.
"\n Note: Empty fields default to the customizable global\
variables.\n\n")
(set (make-local-variable 'gnus-agent-cat-name)
name))
(setq-local gnus-agent-cat-name name))
(set (make-local-variable 'category-fields) nil)
(setq-local category-fields nil)
(gnus-agent-cat-prepare-category-field agent-predicate)
(gnus-agent-cat-prepare-category-field agent-score)

View file

@ -1098,7 +1098,7 @@ When FORCE, rebuild the tool bar."
gnus-group-tool-bar-zap-list
'gnus-group-mode-map)))
(if map
(set (make-local-variable 'tool-bar-map) map))))
(setq-local tool-bar-map map))))
gnus-group-tool-bar-map)
(define-derived-mode gnus-group-mode gnus-mode "Group"
@ -1745,7 +1745,8 @@ already. If INFO-UNCHANGED is non-nil, dribble buffer is not updated."
(prog1
(setq mode-line-buffer-identification
(gnus-mode-line-buffer-identification
(list mode-string)))
(list (propertize mode-string
'face 'mode-line-buffer-id))))
(set-buffer-modified-p modified))))))
(defun gnus-group-group-name ()

View file

@ -464,8 +464,7 @@ only affect the Gcc copy, but not the original message."
(gnus-inews-add-send-actions ,winconf ,buffer ,oarticle ,config
,yanked ,winconf-name)
(setq gnus-message-buffer (current-buffer))
(set (make-local-variable 'gnus-message-group-art)
(cons ,group ,article))
(setq-local gnus-message-group-art (cons ,group ,article))
;; Enable highlighting of different citation levels
(when gnus-message-highlight-citation
(gnus-message-citation-mode 1))
@ -473,7 +472,7 @@ only affect the Gcc copy, but not the original message."
(if (eq major-mode 'message-mode)
(let ((mbl1 mml-buffer-list))
(setq mml-buffer-list mbl) ;; Global value
(set (make-local-variable 'mml-buffer-list) mbl1);; Local value
(setq-local mml-buffer-list mbl1) ;; Local value
(add-hook 'change-major-mode-hook 'mml-destroy-buffers nil t)
(add-hook 'kill-buffer-hook 'mml-destroy-buffers t t))
(mml-destroy-buffers)
@ -724,10 +723,10 @@ network. The corresponding back end must have a `request-post' method."
(gnus-setup-message 'message
(progn
(message-news (gnus-group-real-name gnus-newsgroup-name))
(set (make-local-variable 'gnus-discouraged-post-methods)
(remove
(car (gnus-find-method-for-group gnus-newsgroup-name))
gnus-discouraged-post-methods)))))))))
(setq-local gnus-discouraged-post-methods
(remove
(car (gnus-find-method-for-group gnus-newsgroup-name))
gnus-discouraged-post-methods)))))))))
(defun gnus-summary-post-news (&optional arg)
"Start composing a message. Post to the current group by default.
@ -1926,8 +1925,8 @@ this is a reply."
(message-goto-body)
(insert ,(cdr result)))))
((eq 'signature (car result))
(set (make-local-variable 'message-signature) nil)
(set (make-local-variable 'message-signature-file) nil)
(setq-local message-signature nil)
(setq-local message-signature-file nil)
(if (not (cdr result))
'ignore
`(lambda ()
@ -1953,8 +1952,8 @@ this is a reply."
(when (or name address)
(add-hook 'message-setup-hook
`(lambda ()
(set (make-local-variable 'user-mail-address)
,(or (cdr address) user-mail-address))
(setq-local user-mail-address
,(or (cdr address) user-mail-address))
(let ((user-full-name ,(or (cdr name) (user-full-name)))
(user-mail-address
,(or (cdr address) user-mail-address)))

View file

@ -106,7 +106,7 @@ It accepts the same format specs that `gnus-summary-line-format' does."
(remove-hook 'gnus-message-setup-hook 'gnus-pick-setup-message))
(t
;; Make sure that we don't select any articles upon group entry.
(set (make-local-variable 'gnus-auto-select-first) nil)
(setq-local gnus-auto-select-first nil)
;; Change line format.
(setq gnus-summary-line-format gnus-summary-pick-line-format)
(setq gnus-summary-line-format-spec nil)
@ -114,7 +114,7 @@ It accepts the same format specs that `gnus-summary-line-format' does."
(gnus-update-summary-mark-positions)
;; FIXME: a buffer-local minor mode adding globally to a hook??
(add-hook 'gnus-message-setup-hook 'gnus-pick-setup-message)
(set (make-local-variable 'gnus-summary-goto-unread) 'never)
(setq-local gnus-summary-goto-unread 'never)
;; Set up the menu.
(when (gnus-visual-p 'pick-menu 'menu)
(gnus-pick-make-menu-bar)))))
@ -333,10 +333,8 @@ This must be bound to a button-down mouse event."
((not (derived-mode-p 'gnus-summary-mode)) (setq gnus-binary-mode nil))
(gnus-binary-mode
;; Make sure that we don't select any articles upon group entry.
(make-local-variable 'gnus-auto-select-first)
(setq gnus-auto-select-first nil)
(make-local-variable 'gnus-summary-display-article-function)
(setq gnus-summary-display-article-function 'gnus-binary-display-article)
(setq-local gnus-auto-select-first nil)
(setq-local gnus-summary-display-article-function 'gnus-binary-display-article)
;; Set up the menu.
(when (gnus-visual-p 'binary-menu 'menu)
(gnus-binary-make-menu-bar)))))

View file

@ -1117,8 +1117,7 @@ EXTRA is the possible non-standard header."
(gnus-configure-windows 'edit-score)
(gnus-score-mode)
(setq gnus-score-edit-exit-function 'gnus-score-edit-done)
(make-local-variable 'gnus-prev-winconf)
(setq gnus-prev-winconf winconf))
(setq-local gnus-prev-winconf winconf))
(gnus-message
4 "%s" (substitute-command-keys
"\\<gnus-score-mode-map>\\[gnus-score-edit-exit] to save edits"))))
@ -1145,8 +1144,7 @@ EXTRA is the possible non-standard header."
(gnus-configure-windows 'edit-score)
(gnus-score-mode)
(setq gnus-score-edit-exit-function 'gnus-score-edit-done)
(make-local-variable 'gnus-prev-winconf)
(setq gnus-prev-winconf winconf))
(setq-local gnus-prev-winconf winconf))
(gnus-message
4 "%s" (substitute-command-keys
"\\<gnus-score-mode-map>\\[gnus-score-edit-exit] to save edits")))

View file

@ -105,6 +105,8 @@
(define-error 'gnus-search-parse-error "Gnus search parsing error")
(define-error 'gnus-search-config-error "Gnus search configuration error")
;;; User Customizable Variables:
(defgroup gnus-search nil
@ -1852,8 +1854,10 @@ Assume \"size\" key is equal to \"larger\"."
(grouplist (or groups (gnus-search-get-active server)))
(buffer (slot-value engine 'proc-buffer)))
(unless directory
(error "No directory found in method specification of server %s"
server))
(signal 'gnus-search-config-error
(list (format-message
"No directory found in definition of server %s"
server))))
(apply
'vconcat
(mapcar (lambda (x)
@ -1885,7 +1889,9 @@ Assume \"size\" key is equal to \"larger\"."
group nil t)))
group))))))
(unless group
(error "Cannot locate directory for group"))
(signal 'gnus-search-config-error
(list
"Cannot locate directory for group")))
(save-excursion
(apply
'call-process "find" nil t
@ -1934,12 +1940,19 @@ Assume \"size\" key is equal to \"larger\"."
(limit (alist-get 'limit prepared-query)))
(mapc
(pcase-lambda (`(,server . ,groups))
(let ((search-engine (gnus-search-server-to-engine server)))
(setq results
(vconcat
(gnus-search-run-search
search-engine server prepared-query groups)
results))))
(condition-case err
(let ((search-engine (gnus-search-server-to-engine server)))
(setq results
(vconcat
(gnus-search-run-search
search-engine server prepared-query groups)
results)))
(gnus-search-config-error
(if (< 1 (length (alist-get 'search-group-spec specs)))
(apply #'nnheader-message 4
"Search engine for %s improperly configured: %s"
server (cdr err))
(signal 'gnus-search-config-error err)))))
(alist-get 'search-group-spec specs))
;; Some search engines do their own limiting, but some don't, so
;; do it again here. This is bad because, if the user is
@ -1949,7 +1962,7 @@ Assume \"size\" key is equal to \"larger\"."
;; from a later group entirely.
(if limit
(seq-subseq results 0 (min limit (length results)))
results)))
results)))
(defun gnus-search-prepare-query (query-spec)
"Accept a search query in raw format, and prepare it.
@ -2023,11 +2036,13 @@ remaining string, then adds all that to the top-level spec."
(condition-case nil
(setf (slot-value inst key) value)
((invalid-slot-name invalid-slot-type)
(nnheader-message
5 "Invalid search engine parameter: (%s %s)"
(nnheader-report 'search
"Invalid search engine parameter: (%s %s)"
key value)))))
(push (cons srv inst) gnus-search-engine-instance-alist))
(error "No search engine defined for %s" srv))
(signal 'gnus-search-config-error
(list (format-message
"No search engine configured for %s" srv))))
inst))
(declare-function gnus-registry-get-id-key "gnus-registry" (id key))

View file

@ -262,8 +262,7 @@ The following commands are available:
(setq mode-line-process nil)
(buffer-disable-undo)
(setq truncate-lines t)
(set (make-local-variable 'font-lock-defaults)
'(gnus-server-font-lock-keywords t)))
(setq-local font-lock-defaults '(gnus-server-font-lock-keywords t)))
(defun gnus-server-insert-server-line (name method)

View file

@ -741,8 +741,7 @@ of an NNTP server to use. As opposed to \\[gnus], this command
will not connect to the local server."
(let ((val (or arg (1- gnus-level-default-subscribed))))
(gnus val t child)
(make-local-variable 'gnus-group-use-permanent-levels)
(setq gnus-group-use-permanent-levels val)))
(setq-local gnus-group-use-permanent-levels val)))
(defun gnus-1 (&optional arg dont-connect child)
"Read network news.
@ -875,13 +874,13 @@ If REGEXP is given, lines that match it will be deleted."
(with-current-buffer (setq gnus-dribble-buffer
(gnus-get-buffer-create
(file-name-nondirectory dribble-file)))
(set (make-local-variable 'file-precious-flag) t)
(setq-local file-precious-flag t)
(setq buffer-save-without-query t)
(erase-buffer)
(setq buffer-file-name dribble-file)
;; The buffer may be shrunk a lot when deleting old entries.
;; It caused the auto-saving to stop.
(set (make-local-variable 'auto-save-include-big-deletions) t)
(setq-local auto-save-include-big-deletions t)
(auto-save-mode t)
(buffer-disable-undo)
(bury-buffer (current-buffer))
@ -2763,8 +2762,7 @@ values from `gnus-newsrc-hashtb', and write a new value of
;; Save .newsrc.eld.
(set-buffer (gnus-get-buffer-create " *Gnus-newsrc*"))
(make-local-variable 'version-control)
(setq version-control gnus-backup-startup-file)
(setq-local version-control gnus-backup-startup-file)
(setq buffer-file-name
(concat gnus-current-startup-file ".eld"))
(setq default-directory (file-name-directory buffer-file-name))
@ -2973,8 +2971,7 @@ SPECIFIC-VARIABLES, or those in `gnus-variable-list'."
(when ranges
(insert ",")))))
(insert "\n")))
(make-local-variable 'version-control)
(setq version-control 'never)
(setq-local version-control 'never)
;; It has been reported that sometime the modtime on the .newsrc
;; file seems to be off. We really do want to overwrite it, so
;; we clear the modtime here before saving. It's a bit odd,

View file

@ -1460,8 +1460,8 @@ the normal Gnus MIME machinery."
(?I gnus-tmp-indentation ?s)
(?T (if (= gnus-tmp-level 0) "" (make-string (frame-width) ? )) ?s)
(?R gnus-tmp-replied ?c)
(?\[ gnus-tmp-opening-bracket ?c)
(?\] gnus-tmp-closing-bracket ?c)
(?\[ gnus-tmp-opening-bracket ?s)
(?\] gnus-tmp-closing-bracket ?s)
(?\> (make-string gnus-tmp-level ? ) ?s)
(?\< (make-string (max 0 (- 20 gnus-tmp-level)) ? ) ?s)
(?i gnus-tmp-score ?d)
@ -3038,7 +3038,7 @@ When FORCE, rebuild the tool bar."
;; Need to set `gnus-summary-tool-bar-map' because `gnus-article-mode'
;; uses its value.
(setq gnus-summary-tool-bar-map map))))
(set (make-local-variable 'tool-bar-map) gnus-summary-tool-bar-map))
(setq-local tool-bar-map gnus-summary-tool-bar-map))
(defun gnus-make-score-map (type)
"Make a summary score map of type TYPE."
@ -3174,8 +3174,8 @@ The following commands are available:
(make-local-variable 'gnus-original-article-buffer)
(add-hook 'pre-command-hook #'gnus-set-global-variables nil t)
(mm-enable-multibyte)
(set (make-local-variable 'bookmark-make-record-function)
#'gnus-summary-bookmark-make-record))
(setq-local bookmark-make-record-function
#'gnus-summary-bookmark-make-record))
(defun gnus-summary-make-local-variables ()
"Make all the local summary buffer variables."
@ -3547,7 +3547,7 @@ Returns non-nil if the setup was successful."
(let ((gnus-summary-mode-group group))
(gnus-summary-mode))
(when (gnus-group-quit-config group)
(set (make-local-variable 'gnus-single-article-buffer) nil))
(setq-local gnus-single-article-buffer nil))
(turn-on-gnus-mailing-list-mode)
;; These functions don't currently depend on GROUP, but might in
;; the future.
@ -3748,6 +3748,30 @@ buffer that was in action when the last article was fetched."
(inline
(gnus-summary-extract-address-component gnus-tmp-from))))))
(defcustom gnus-sum-opening-bracket "["
"With %[ spec, used to identify normal (non-adopted) articles."
:version "28.1"
:type 'string
:group 'gnus-summary-format)
(defcustom gnus-sum-closing-bracket "]"
"With %] spec, used to identify normal (non-adopted) articles."
:version "28.1"
:type 'string
:group 'gnus-summary-format)
(defcustom gnus-sum-opening-bracket-adopted "<"
"With %[ spec, used to identify adopted articles."
:version "28.1"
:type 'string
:group 'gnus-summary-format)
(defcustom gnus-sum-closing-bracket-adopted ">"
"With %] spec, used to identify adopted articles."
:version "28.1"
:type 'string
:group 'gnus-summary-format)
(defun gnus-summary-insert-line (header level current undownloaded
unread replied expirable subject-or-nil
&optional dummy score process)
@ -3805,8 +3829,14 @@ buffer that was in action when the last article was fetched."
(1+ (match-beginning 0)) (1- (match-end 0))))
(t gnus-tmp-from)))
(gnus-tmp-subject (mail-header-subject gnus-tmp-header))
(gnus-tmp-opening-bracket (if gnus-tmp-dummy ?\< ?\[))
(gnus-tmp-closing-bracket (if gnus-tmp-dummy ?\> ?\]))
(gnus-tmp-opening-bracket
(if gnus-tmp-dummy
gnus-sum-opening-bracket-adopted
gnus-sum-opening-bracket))
(gnus-tmp-closing-bracket
(if gnus-tmp-dummy
gnus-sum-closing-bracket-adopted
gnus-sum-closing-bracket))
(inhibit-read-only t))
(when (string= gnus-tmp-name "")
(setq gnus-tmp-name gnus-tmp-from))
@ -5439,10 +5469,10 @@ or a straight list of headers."
(if (and (eq gnus-summary-make-false-root 'adopt)
(= gnus-tmp-level 1)
(memq number gnus-tmp-gathered))
(setq gnus-tmp-opening-bracket ?\<
gnus-tmp-closing-bracket ?\>)
(setq gnus-tmp-opening-bracket ?\[
gnus-tmp-closing-bracket ?\]))
(setq gnus-tmp-opening-bracket gnus-sum-opening-bracket-adopted
gnus-tmp-closing-bracket gnus-sum-closing-bracket-adopted)
(setq gnus-tmp-opening-bracket gnus-sum-opening-bracket
gnus-tmp-closing-bracket gnus-sum-closing-bracket))
(if (>= gnus-tmp-level (length gnus-thread-indent-array))
(gnus-make-thread-indent-array
(max (* 2 (length gnus-thread-indent-array))
@ -5670,8 +5700,8 @@ If SELECT-ARTICLES, only select those articles from GROUP."
articles fetched-articles cached)
(unless (gnus-check-server
(set (make-local-variable 'gnus-current-select-method)
(gnus-find-method-for-group group)))
(setq-local gnus-current-select-method
(gnus-find-method-for-group group)))
(error "Couldn't open server"))
(or (and entry (not (eq (car entry) t))) ; Either it's active...
@ -6254,7 +6284,9 @@ If WHERE is `summary', the summary mode line format will be used."
mode-string (- max-len 3) nil nil t)))))
;; Update the mode line.
(setq mode-line-buffer-identification
(gnus-mode-line-buffer-identification (list mode-string)))
(gnus-mode-line-buffer-identification
(list (propertize mode-string
'face 'mode-line-buffer-id))))
(set-buffer-modified-p t))))
(defun gnus-create-xref-hashtb (from-newsgroup headers unreads)
@ -10638,7 +10670,7 @@ groups."
(mime-to-mml current-handles))
(let ((mbl1 mml-buffer-list))
(setq mml-buffer-list mbl)
(set (make-local-variable 'mml-buffer-list) mbl1))
(setq-local mml-buffer-list mbl1))
(add-hook 'kill-buffer-hook #'mml-destroy-buffers t t))))
`(lambda (no-highlight)
(let ((mail-parse-charset ',gnus-newsgroup-charset)
@ -12846,8 +12878,7 @@ UNREAD is a sorted list."
(and gnus-newsgroup-name
(gnus-parameter-charset gnus-newsgroup-name))
gnus-default-charset))
(set (make-local-variable 'gnus-newsgroup-ignored-charsets)
ignored-charsets))))
(setq-local gnus-newsgroup-ignored-charsets ignored-charsets))))
;;;
;;; Mime Commands

View file

@ -1129,18 +1129,17 @@ articles in the topic and its subtopics."
(gnus-topic-make-menu-bar))
(gnus-set-format 'topic t)
(add-hook 'gnus-group-catchup-group-hook 'gnus-topic-update-topic)
(set (make-local-variable 'gnus-group-prepare-function)
'gnus-group-prepare-topics)
(set (make-local-variable 'gnus-group-get-parameter-function)
'gnus-group-topic-parameters)
(set (make-local-variable 'gnus-group-goto-next-group-function)
'gnus-topic-goto-next-group)
(set (make-local-variable 'gnus-group-indentation-function)
'gnus-topic-group-indentation)
(set (make-local-variable 'gnus-group-update-group-function)
'gnus-topic-update-topics-containing-group)
(set (make-local-variable 'gnus-group-sort-alist-function)
'gnus-group-sort-topic)
(setq-local gnus-group-prepare-function
'gnus-group-prepare-topics)
(setq-local gnus-group-get-parameter-function
'gnus-group-topic-parameters)
(setq-local gnus-group-goto-next-group-function
'gnus-topic-goto-next-group)
(setq-local gnus-group-indentation-function
'gnus-topic-group-indentation)
(setq-local gnus-group-update-group-function
'gnus-topic-update-topics-containing-group)
(setq-local gnus-group-sort-alist-function 'gnus-group-sort-topic)
(setq gnus-group-change-level-function 'gnus-topic-change-level)
(setq gnus-goto-missing-group-function 'gnus-topic-goto-missing-group)
(add-hook 'gnus-check-bogus-groups-hook 'gnus-topic-clean-alist

View file

@ -100,8 +100,8 @@
\\{gnus-undo-mode-map}"
:keymap gnus-undo-mode-map
(set (make-local-variable 'gnus-undo-actions) nil)
(set (make-local-variable 'gnus-undo-boundary) t)
(setq-local gnus-undo-actions nil)
(setq-local gnus-undo-boundary t)
(when gnus-undo-mode
;; Set up the menu.
(when (gnus-visual-p 'undo-menu 'menu)

View file

@ -68,7 +68,7 @@ used to display Gnus windows."
:type 'boolean)
(defvar gnus-buffer-configuration
'((group
`((group
(vertical 1.0
(group 1.0 point)))
(summary
@ -142,7 +142,7 @@ used to display Gnus windows."
(pipe
(vertical 1.0
(summary 0.25 point)
(shell-command-buffer-name 1.0)))
(,shell-command-buffer-name 1.0)))
(bug
(vertical 1.0
(if gnus-bug-create-help-buffer '("*Gnus Help Bug*" 0.5))

View file

@ -309,34 +309,29 @@ be set in `.emacs' instead."
:group 'gnus-start
:type 'boolean)
(defvar gnus-mode-line-image-cache t)
(eval-and-compile
(if (fboundp 'find-image)
(defun gnus-mode-line-buffer-identification (line)
(let ((str (car-safe line))
(load-path (append (mm-image-load-path) load-path)))
(if (and (display-graphic-p)
(stringp str)
(string-match "^Gnus:" str))
(progn (add-text-properties
0 5
(list 'display
(if (eq t gnus-mode-line-image-cache)
(setq gnus-mode-line-image-cache
(find-image
'((:type xpm :file "gnus-pointer.xpm"
:ascent center)
(:type xbm :file "gnus-pointer.xbm"
:ascent center))))
gnus-mode-line-image-cache)
'help-echo (format
"This is %s, %s."
gnus-version (gnus-emacs-version)))
str)
(list str))
line)))
(defalias 'gnus-mode-line-buffer-identification 'identity)))
(defun gnus-mode-line-buffer-identification (line)
(let ((str (car-safe line)))
(if (or (not (fboundp 'find-image))
(not (display-graphic-p))
(not (stringp str))
(not (string-match "^Gnus:" str)))
line
(let ((load-path (append (mm-image-load-path) load-path)))
;; Add the Gnus logo.
(add-text-properties
0 5
(list 'display
(find-image
'((:type xpm :file "gnus-pointer.xpm"
:ascent center)
(:type xbm :file "gnus-pointer.xbm"
:ascent center))
t)
'help-echo (format
"This is %s, %s."
gnus-version (gnus-emacs-version)))
str)
(list str)))))
;; We define these group faces here to avoid the display
;; update forced when creating new faces.
@ -3175,8 +3170,7 @@ that that variable is buffer-local to the summary buffers."
"Make mode lines a bit simpler."
(setq mode-line-modified "--")
(when (listp mode-line-format)
(make-local-variable 'mode-line-format)
(setq mode-line-format (copy-sequence mode-line-format))
(setq-local mode-line-format (copy-sequence mode-line-format))
(when (equal (nth 3 mode-line-format) " ")
(setcar (nthcdr 3 mode-line-format) " "))))

View file

@ -1155,7 +1155,7 @@ Note: Many newsgroups frown upon nontraditional reply styles.
You probably want to set this variable only for specific groups,
e.g. using `gnus-posting-styles':
(eval (set (make-local-variable \\='message-cite-reply-position) \\='above))"
(eval (setq-local message-cite-reply-position \\='above))"
:version "24.1"
:type '(choice (const :tag "Reply inline" traditional)
(const :tag "Reply above" above)
@ -1172,7 +1172,7 @@ Presets to impersonate popular mail agents are found in the
message-cite-style-* variables. This variable is intended for
use in `gnus-posting-styles', such as:
((posting-from-work-p) (eval (set (make-local-variable \\='message-cite-style) message-cite-style-outlook)))"
((posting-from-work-p) (eval (setq-local message-cite-style message-cite-style-outlook)))"
:version "24.1"
:group 'message-insertion
:type '(choice (const :tag "Do not override variables" :value nil)
@ -3078,44 +3078,43 @@ See also `message-forbidden-properties'."
Like `text-mode', but with these additional commands:
\\{message-mode-map}"
(set (make-local-variable 'message-reply-buffer) nil)
(set (make-local-variable 'message-inserted-headers) nil)
(set (make-local-variable 'message-send-actions) nil)
(set (make-local-variable 'message-return-action) nil)
(set (make-local-variable 'message-exit-actions) nil)
(set (make-local-variable 'message-kill-actions) nil)
(set (make-local-variable 'message-postpone-actions) nil)
(set (make-local-variable 'message-draft-article) nil)
(setq-local message-reply-buffer nil)
(setq-local message-inserted-headers nil)
(setq-local message-send-actions nil)
(setq-local message-return-action nil)
(setq-local message-exit-actions nil)
(setq-local message-kill-actions nil)
(setq-local message-postpone-actions nil)
(setq-local message-draft-article nil)
(setq buffer-offer-save t)
(set (make-local-variable 'facemenu-add-face-function)
(setq-local facemenu-add-face-function
(lambda (face end)
(let ((face-fun (cdr (assq face message-face-alist))))
(if face-fun
(funcall face-fun (point) end)
(error "Face %s not configured for %s mode" face mode-name)))
""))
(set (make-local-variable 'facemenu-remove-face-function) t)
(set (make-local-variable 'message-reply-headers) nil)
(setq-local facemenu-remove-face-function t)
(setq-local message-reply-headers nil)
(make-local-variable 'message-newsreader)
(make-local-variable 'message-mailer)
(make-local-variable 'message-post-method)
(set (make-local-variable 'message-sent-message-via) nil)
(set (make-local-variable 'message-checksum) nil)
(set (make-local-variable 'message-mime-part) 0)
(setq-local message-sent-message-via nil)
(setq-local message-checksum nil)
(setq-local message-mime-part 0)
(message-setup-fill-variables)
(when message-fill-column
(setq fill-column message-fill-column)
(turn-on-auto-fill))
;; Allow using comment commands to add/remove quoting.
;; (set (make-local-variable 'comment-start) message-yank-prefix)
;; (setq-local comment-start message-yank-prefix)
(when message-yank-prefix
(set (make-local-variable 'comment-start) message-yank-prefix)
(set (make-local-variable 'comment-start-skip)
(concat "^" (regexp-quote message-yank-prefix) "[ \t]*")))
(set (make-local-variable 'font-lock-defaults)
'(message-font-lock-keywords t))
(setq-local comment-start message-yank-prefix)
(setq-local comment-start-skip
(concat "^" (regexp-quote message-yank-prefix) "[ \t]*")))
(setq-local font-lock-defaults '(message-font-lock-keywords t))
(if (boundp 'tool-bar-map)
(set (make-local-variable 'tool-bar-map) (message-make-tool-bar)))
(setq-local tool-bar-map (message-make-tool-bar)))
;; Mmmm... Forbidden properties...
(add-hook 'after-change-functions #'message-strip-forbidden-properties
nil 'local)
@ -3134,45 +3133,41 @@ Like `text-mode', but with these additional commands:
;; Don't enable multibyte on an indirect buffer. Maybe enabling
;; multibyte is not necessary at all. -- zsh
(mm-enable-multibyte))
(set (make-local-variable 'indent-tabs-mode) nil) ;No tabs for indentation.
(setq-local indent-tabs-mode nil) ; No tabs for indentation.
(mml-mode)
;; Syntactic fontification. Helps `show-paren-mode',
;; `electric-pair-mode', and C-M-* navigation by syntactically
;; excluding citations and other artifacts.
;;
(set (make-local-variable 'syntax-propertize-function) 'message--syntax-propertize)
(set (make-local-variable 'parse-sexp-ignore-comments) t)
(setq-local syntax-propertize-function 'message--syntax-propertize)
(setq-local parse-sexp-ignore-comments t)
(setq-local message-encoded-mail-cache nil))
(defun message-setup-fill-variables ()
"Setup message fill variables."
(set (make-local-variable 'fill-paragraph-function)
'message-fill-paragraph)
(make-local-variable 'paragraph-separate)
(make-local-variable 'paragraph-start)
(make-local-variable 'adaptive-fill-regexp)
(setq-local fill-paragraph-function 'message-fill-paragraph)
(make-local-variable 'adaptive-fill-first-line-regexp)
(let ((quote-prefix-regexp
;; User should change message-cite-prefix-regexp if
;; message-yank-prefix is set to an abnormal value.
(concat "\\(" message-cite-prefix-regexp "\\)[ \t]*")))
(setq paragraph-start
(concat
(regexp-quote mail-header-separator) "$\\|"
"[ \t]*$\\|" ; blank lines
"-- $\\|" ; signature delimiter
"---+$\\|" ; delimiters for forwarded messages
page-delimiter "$\\|" ; spoiler warnings
".*wrote:$\\|" ; attribution lines
quote-prefix-regexp "$\\|" ; empty lines in quoted text
; mml tags
"<#!*/?\\(multipart\\|part\\|external\\|mml\\|secure\\)"))
(setq paragraph-separate paragraph-start)
(setq adaptive-fill-regexp
(concat quote-prefix-regexp "\\|" adaptive-fill-regexp))
(setq adaptive-fill-first-line-regexp
(concat quote-prefix-regexp "\\|"
adaptive-fill-first-line-regexp)))
(setq-local paragraph-start
(concat
(regexp-quote mail-header-separator) "$\\|"
"[ \t]*$\\|" ; blank lines
"-- $\\|" ; signature delimiter
"---+$\\|" ; delimiters for forwarded messages
page-delimiter "$\\|" ; spoiler warnings
".*wrote:$\\|" ; attribution lines
quote-prefix-regexp "$\\|" ; empty lines in quoted text
; mml tags
"<#!*/?\\(multipart\\|part\\|external\\|mml\\|secure\\)"))
(setq-local paragraph-separate paragraph-start)
(setq-local adaptive-fill-regexp
(concat quote-prefix-regexp "\\|" adaptive-fill-regexp))
(setq-local adaptive-fill-first-line-regexp
(concat quote-prefix-regexp "\\|"
adaptive-fill-first-line-regexp)))
(setq-local auto-fill-inhibit-regexp nil)
(setq-local normal-auto-fill-function 'message-do-auto-fill))

View file

@ -486,7 +486,7 @@ If MODE is not set, try to find mode automatically."
;; support modes, but now that we use font-lock-ensure, support modes
;; aren't a problem any more. So we could probably get rid of this
;; setting now, but it seems harmless and potentially still useful.
(set (make-local-variable 'font-lock-mode-hook) nil)
(setq-local font-lock-mode-hook nil)
(setq buffer-file-name (mm-handle-filename handle))
(with-demoted-errors
(if mode

View file

@ -1266,8 +1266,8 @@ See Info node `(emacs-mime)Composing'.
:lighter " MML" :keymap mml-mode-map
(when mml-mode
(when (boundp 'dnd-protocol-alist)
(set (make-local-variable 'dnd-protocol-alist)
(append mml-dnd-protocol-alist dnd-protocol-alist)))))
(setq-local dnd-protocol-alist
(append mml-dnd-protocol-alist dnd-protocol-alist)))))
;;;
;;; Helper functions for reading MIME stuff from the minibuffer and

View file

@ -1002,10 +1002,10 @@ all. This may very well take some time.")
(let ((buffer (gnus-get-buffer-create
(format " *nndiary overview %s*" group))))
(with-current-buffer buffer
(set (make-local-variable 'nndiary-nov-buffer-file-name)
(expand-file-name
nndiary-nov-file-name
(nnmail-group-pathname group nndiary-directory)))
(setq-local nndiary-nov-buffer-file-name
(expand-file-name
nndiary-nov-file-name
(nnmail-group-pathname group nndiary-directory)))
(erase-buffer)
(when (file-exists-p nndiary-nov-buffer-file-name)
(nnheader-insert-file-contents nndiary-nov-buffer-file-name)))

View file

@ -1083,7 +1083,7 @@ This command does not work if you use short group names."
(let ((coding-system-for-write
(or nnfolder-file-coding-system-for-write
nnfolder-file-coding-system)))
(set (make-local-variable 'copyright-update) nil)
(setq-local copyright-update nil)
(save-buffer)))
(unless (or gnus-nov-is-evil nnfolder-nov-is-evil)
(nnfolder-save-nov))))
@ -1098,8 +1098,8 @@ This command does not work if you use short group names."
(or (cdr (assoc group nnfolder-nov-buffer-alist))
(let ((buffer (gnus-get-buffer-create (format " *nnfolder overview %s*" group))))
(with-current-buffer buffer
(set (make-local-variable 'nnfolder-nov-buffer-file-name)
(nnfolder-group-nov-pathname group))
(setq-local nnfolder-nov-buffer-file-name
(nnfolder-group-nov-pathname group))
(erase-buffer)
(when (file-exists-p nnfolder-nov-buffer-file-name)
(nnheader-insert-file-contents nnfolder-nov-buffer-file-name)))

View file

@ -568,7 +568,7 @@ the line could be found."
(mm-enable-multibyte)
(kill-all-local-variables)
(setq case-fold-search t) ;Should ignore case.
(set (make-local-variable 'nntp-process-response) nil)
(setq-local nntp-process-response nil)
t))
;;; Various functions the backends use.

View file

@ -376,10 +376,10 @@ during splitting, which may be slow."
(mm-disable-multibyte)
(buffer-disable-undo)
(gnus-add-buffer)
(set (make-local-variable 'after-change-functions) nil) ;FIXME: Why?
(set (make-local-variable 'nnimap-object)
(make-nnimap :server (nnoo-current-server 'nnimap)
:initial-resync 0))
(setq-local after-change-functions nil) ;FIXME: Why?
(setq-local nnimap-object
(make-nnimap :server (nnoo-current-server 'nnimap)
:initial-resync 0))
(push (list buffer (current-buffer)) nnimap-connection-alist)
(push (current-buffer) nnimap-process-buffers)
(current-buffer)))

View file

@ -778,8 +778,8 @@ article number. This function is called narrowed to an article."
group)))
(file-name-coding-system nnmail-pathname-coding-system))
(with-current-buffer buffer
(set (make-local-variable 'nnml-nov-buffer-file-name)
(nnmail-group-pathname group nnml-directory nnml-nov-file-name))
(setq-local nnml-nov-buffer-file-name
(nnmail-group-pathname group nnml-directory nnml-nov-file-name))
(erase-buffer)
(when (and (not incrementalp)
(file-exists-p nnml-nov-buffer-file-name))

View file

@ -1139,8 +1139,7 @@ it is displayed along with the global value."
(when (looking-at "value is") (replace-match ""))
(save-excursion
(insert "\n\nValue:")
(set (make-local-variable 'help-button-cache)
(point-marker)))
(setq-local help-button-cache (point-marker)))
(insert "value is shown ")
(insert-button "below"
'action help-button-cache

View file

@ -319,10 +319,10 @@ The format is (FUNCTION ARGS...).")
Entry to this mode runs the normal hook `help-mode-hook'.
Commands:
\\{help-mode-map}"
(set (make-local-variable 'revert-buffer-function)
'help-mode-revert-buffer)
(set (make-local-variable 'bookmark-make-record-function)
'help-bookmark-make-record))
(setq-local revert-buffer-function
#'help-mode-revert-buffer)
(setq-local bookmark-make-record-function
#'help-bookmark-make-record))
;;;###autoload
(defun help-mode-setup ()

View file

@ -722,7 +722,10 @@ With prefix arg N, puts point N bytes of the way from the true beginning."
"Scroll hexl buffer window upward ARG lines; or near full window if no ARG."
(interactive "P")
(setq arg (if (null arg)
(1- (window-height))
(- (window-height)
1
(if ruler-mode 1 0)
next-screen-context-lines)
(prefix-numeric-value arg)))
(hexl-scroll-up (- arg)))
@ -731,7 +734,10 @@ With prefix arg N, puts point N bytes of the way from the true beginning."
If there's no byte at the target address, move to the first or last line."
(interactive "P")
(setq arg (if (null arg)
(1- (window-height))
(- (window-height)
1
(if ruler-mode 1 0)
next-screen-context-lines)
(prefix-numeric-value arg)))
(let* ((movement (* arg 16))
(address (hexl-current-address))

View file

@ -2464,7 +2464,7 @@ FORMATS is the value to use for `ibuffer-formats'.
(require 'ibuf-ext)
(setq ibuffer-filter-groups filter-groups))
(when formats
(set (make-local-variable 'ibuffer-formats) formats))
(setq-local ibuffer-formats formats))
(ibuffer-update nil)
;; Skip the group name by default.
(ibuffer-forward-line 0 t)
@ -2683,7 +2683,7 @@ You may rearrange filter groups by using the usual pair
`\\[ibuffer-kill-line]' and `\\[ibuffer-yank]'. Yanked groups
will be inserted before the group at point."
;; Include state info next to the mode name.
(set (make-local-variable 'mode-line-process)
(setq-local mode-line-process
'(" by "
(ibuffer-sorting-mode (:eval (symbol-name ibuffer-sorting-mode))
"view time")
@ -2712,28 +2712,27 @@ will be inserted before the group at point."
(setq show-trailing-whitespace nil)
;; disable `show-paren-mode' buffer-locally
(if (bound-and-true-p show-paren-mode)
(set (make-local-variable 'show-paren-mode) nil))
(set (make-local-variable 'revert-buffer-function)
#'ibuffer-update)
(set (make-local-variable 'ibuffer-sorting-mode)
ibuffer-default-sorting-mode)
(set (make-local-variable 'ibuffer-sorting-reversep)
ibuffer-default-sorting-reversep)
(set (make-local-variable 'ibuffer-shrink-to-minimum-size)
ibuffer-default-shrink-to-minimum-size)
(set (make-local-variable 'ibuffer-display-maybe-show-predicates)
ibuffer-default-display-maybe-show-predicates)
(set (make-local-variable 'ibuffer-filtering-qualifiers) nil)
(set (make-local-variable 'ibuffer-filter-groups) nil)
(set (make-local-variable 'ibuffer-filter-group-kill-ring) nil)
(set (make-local-variable 'ibuffer-hidden-filter-groups) nil)
(set (make-local-variable 'ibuffer-compiled-formats) nil)
(set (make-local-variable 'ibuffer-cached-formats) nil)
(set (make-local-variable 'ibuffer-cached-eliding-string) nil)
(set (make-local-variable 'ibuffer-current-format) nil)
(set (make-local-variable 'ibuffer-did-modification) nil)
(set (make-local-variable 'ibuffer-tmp-hide-regexps) nil)
(set (make-local-variable 'ibuffer-tmp-show-regexps) nil)
(setq-local show-paren-mode nil))
(setq-local revert-buffer-function #'ibuffer-update)
(setq-local ibuffer-sorting-mode
ibuffer-default-sorting-mode)
(setq-local ibuffer-sorting-reversep
ibuffer-default-sorting-reversep)
(setq-local ibuffer-shrink-to-minimum-size
ibuffer-default-shrink-to-minimum-size)
(setq-local ibuffer-display-maybe-show-predicates
ibuffer-default-display-maybe-show-predicates)
(setq-local ibuffer-filtering-qualifiers nil)
(setq-local ibuffer-filter-groups nil)
(setq-local ibuffer-filter-group-kill-ring nil)
(setq-local ibuffer-hidden-filter-groups nil)
(setq-local ibuffer-compiled-formats nil)
(setq-local ibuffer-cached-formats nil)
(setq-local ibuffer-cached-eliding-string nil)
(setq-local ibuffer-current-format nil)
(setq-local ibuffer-did-modification nil)
(setq-local ibuffer-tmp-hide-regexps nil)
(setq-local ibuffer-tmp-show-regexps nil)
(define-key ibuffer-mode-map [menu-bar edit] 'undefined)
(define-key ibuffer-mode-map [menu-bar operate] (cons "Operate" ibuffer-mode-operate-map))
(ibuffer-update-format)

View file

@ -75,12 +75,7 @@ everything preceding the ~/ is discarded so the interactive
selection process starts again from the user's $HOME.")
(defcustom icomplete-show-matches-on-no-input nil
"If nil, don't wait for completions before showing the prompt.
Instead, when there's no input, completions may be displayed
asynchronously later, when the completions have been computed.
If non-nil, always compute the completions first.
"When non-nil, show completions when the minibuffer is empty.
This also means that if you traverse the list of completions with
commands like `C-.' and just hit RET without typing any
characters, the match under point will be chosen instead of the
@ -446,7 +441,7 @@ Conditions are:
"Run in minibuffer on activation to establish incremental completion.
Usually run by inclusion in `minibuffer-setup-hook'."
(when (and icomplete-mode (icomplete-simple-completing-p))
(set (make-local-variable 'completion-show-inline-help) nil)
(setq-local completion-show-inline-help nil)
(use-local-map (make-composed-keymap icomplete-minibuffer-map
(current-local-map)))
(add-hook 'pre-command-hook #'icomplete-pre-command-hook nil t)
@ -469,7 +464,7 @@ Usually run by inclusion in `minibuffer-setup-hook'."
(when (and completion-in-region-mode
icomplete-mode (icomplete-simple-completing-p))
(setq icomplete--in-region-buffer (current-buffer))
(set (make-local-variable 'completion-show-inline-help) nil)
(setq-local completion-show-inline-help nil)
(let ((tem (assq 'completion-in-region-mode
minor-mode-overriding-map-alist)))
(unless (memq icomplete-minibuffer-map (cdr tem))

View file

@ -3966,7 +3966,7 @@ If `ido-change-word-sub' cannot be found in WORD, return nil."
(boundp 'ido-completion-buffer-full))
(set-window-start win (point-min))
(with-no-warnings
(set (make-local-variable 'ido-completion-buffer-full) t))
(setq-local ido-completion-buffer-full t))
(setq full-list t
display-it t))
(scroll-other-window))
@ -4810,8 +4810,7 @@ Modified from `icomplete-completions'."
(delete-region ido-eoinput (point-max))))
;; Reestablish the local variable 'cause minibuffer-setup is weird:
(make-local-variable 'ido-eoinput)
(setq ido-eoinput 1))))
(setq-local ido-eoinput 1))))
(defun ido-summary-buffers-to-end ()
;; Move the summaries to the end of the buffer list.

View file

@ -529,8 +529,8 @@ Customized bindings may be defined in `ielm-map', which currently contains:
:syntax-table emacs-lisp-mode-syntax-table
(setq comint-prompt-regexp (concat "^" (regexp-quote ielm-prompt)))
(set (make-local-variable 'paragraph-separate) "\\'")
(set (make-local-variable 'paragraph-start) comint-prompt-regexp)
(setq-local paragraph-separate "\\'")
(setq-local paragraph-start comint-prompt-regexp)
(setq comint-input-sender 'ielm-input-sender)
(setq comint-process-echoes nil)
(dolist (f '(elisp-completion-at-point
@ -541,28 +541,28 @@ Customized bindings may be defined in `ielm-map', which currently contains:
#'elisp-eldoc-var-docstring nil t)
(add-hook 'eldoc-documentation-functions
#'elisp-eldoc-funcall nil t)
(set (make-local-variable 'ielm-prompt-internal) ielm-prompt)
(set (make-local-variable 'comint-prompt-read-only) ielm-prompt-read-only)
(setq-local ielm-prompt-internal ielm-prompt)
(setq-local comint-prompt-read-only ielm-prompt-read-only)
(setq comint-get-old-input 'ielm-get-old-input)
(set (make-local-variable 'comint-completion-addsuffix) '("/" . ""))
(setq-local comint-completion-addsuffix '("/" . ""))
(setq mode-line-process '(":%s on " (:eval (buffer-name ielm-working-buffer))))
;; Useful for `hs-minor-mode'.
(setq-local comment-start ";")
(setq-local comment-use-syntax t)
(setq-local lexical-binding t)
(set (make-local-variable 'indent-line-function) #'ielm-indent-line)
(set (make-local-variable 'ielm-working-buffer) (current-buffer))
(set (make-local-variable 'fill-paragraph-function) #'lisp-fill-paragraph)
(setq-local indent-line-function #'ielm-indent-line)
(setq-local ielm-working-buffer (current-buffer))
(setq-local fill-paragraph-function #'lisp-fill-paragraph)
;; Value holders
(set (make-local-variable '*) nil)
(set (make-local-variable '**) nil)
(set (make-local-variable '***) nil)
(set (make-local-variable 'ielm-match-data) nil)
(setq-local * nil)
(setq-local ** nil)
(setq-local *** nil)
(setq-local ielm-match-data nil)
;; font-lock support
(set (make-local-variable 'font-lock-defaults)
(setq-local font-lock-defaults
'(ielm-font-lock-keywords nil nil ((?: . "w") (?- . "w") (?* . "w"))))
;; A dummy process to keep comint happy. It will never get any input
@ -577,7 +577,7 @@ Customized bindings may be defined in `ielm-map', which currently contains:
;; Lisp output can include raw characters that confuse comint's
;; carriage control code.
(set (make-local-variable 'comint-inhibit-carriage-motion) t)
(setq-local comint-inhibit-carriage-motion t)
;; Add a silly header
(insert ielm-header)

View file

@ -679,8 +679,10 @@ BUFFER nil or omitted means use the current buffer."
(setq path (cdr path)))
(if found filename)))
(defvar find-image--cache (make-hash-table :test #'equal))
;;;###autoload
(defun find-image (specs)
(defun find-image (specs &optional cache)
"Find an image, choosing one of a list of image specifications.
SPECS is a list of image specifications.
@ -695,26 +697,33 @@ is supported, and FILE exists, is used to construct the image
specification to be returned. Return nil if no specification is
satisfied.
If CACHE is non-nil, results are cached and returned on subsequent calls.
The image is looked for in `image-load-path'.
Image files should not be larger than specified by `max-image-size'."
(let (image)
(while (and specs (null image))
(let* ((spec (car specs))
(type (plist-get spec :type))
(data (plist-get spec :data))
(file (plist-get spec :file))
found)
(when (image-type-available-p type)
(cond ((stringp file)
(if (setq found (image-search-load-path file))
(setq image
(cons 'image (plist-put (copy-sequence spec)
:file found)))))
((not (null data))
(setq image (cons 'image spec)))))
(setq specs (cdr specs))))
image))
(or (and cache
(gethash specs find-image--cache))
(let ((orig-specs specs)
image)
(while (and specs (null image))
(let* ((spec (car specs))
(type (plist-get spec :type))
(data (plist-get spec :data))
(file (plist-get spec :file))
found)
(when (image-type-available-p type)
(cond ((stringp file)
(if (setq found (image-search-load-path file))
(setq image
(cons 'image (plist-put (copy-sequence spec)
:file found)))))
((not (null data))
(setq image (cons 'image spec)))))
(setq specs (cdr specs))))
(when cache
(setf (gethash orig-specs find-image--cache) image))
image)))
;;;###autoload

View file

@ -165,7 +165,7 @@ If the orientation isn't present in the data, return nil."
;; Another magical number.
(unless (= (exif--read-number 2 le) #x002a)
(signal 'exif-error "Invalid TIFF header length"))
(let ((offset (exif--read-number 2 le)))
(let ((offset (exif--read-number 4 le)))
;; Jump to where the IFD (directory) starts and parse it.
(when (> (1+ offset) (point-max))
(signal 'exif-error "Invalid IFD (directory) offset"))

View file

@ -2473,7 +2473,7 @@ Table of contents is created from the tree structure of menus."
(setq bound (or (and (equal nodename "Top")
(save-excursion
(re-search-forward
"^[ \t-]*The Detailed Node Listing" nil t)))
"^[ \t-]*The Detailed Node Listing" nil t)))
bound))
(while (< (point) bound)
(cond
@ -4790,10 +4790,10 @@ first line or header line, and for breadcrumb links.")
;; an end of sentence
(skip-syntax-backward " ("))
(setq other-tag
(cond ((save-match-data (looking-back "\\<see"
(cond ((save-match-data (looking-back "\\(^\\| \\)see"
(- (point) 3)))
"")
((save-match-data (looking-back "\\<in"
((save-match-data (looking-back "\\(^\\| \\)in"
(- (point) 2)))
"")
((memq (char-before) '(nil ?\. ?! ??))

View file

@ -759,7 +759,14 @@ with L, LRE, or LRO Unicode bidi character type.")
(funcall map-unicode-property 'uppercase
(lambda (lc uc) (aset up lc uc) (aset up uc uc)))
(funcall map-unicode-property 'lowercase
(lambda (uc lc) (aset down uc lc) (aset down lc lc))))))
(lambda (uc lc) (aset down uc lc) (aset down lc lc)))
;; Override the Unicode uppercase property for ß, since we are
;; using our case tables for determining the case of a
;; character (see uppercasep and lowercasep in buffer.h).
;; The special-uppercase property of ß ensures that it is
;; still upcased to SS per the usual convention.
(aset up ?ẞ))))
;; Clear out the extra slots so that they will be recomputed from the main
;; (downcase) table and upcase table. Since were side-stepping the usual

View file

@ -35,9 +35,8 @@
(interactive)
(let ((overriding-terminal-local-map nil))
(toggle-input-method t))
(setq isearch-input-method-function input-method-function
isearch-input-method-local-p t)
(setq input-method-function nil)
(setq isearch-input-method-function input-method-function)
(setq-local input-method-function nil)
(isearch-update))
;;;###autoload
@ -46,9 +45,8 @@
(interactive)
(let ((overriding-terminal-local-map nil))
(toggle-input-method))
(setq isearch-input-method-function input-method-function
isearch-input-method-local-p t)
(setq input-method-function nil)
(setq isearch-input-method-function input-method-function)
(setq-local input-method-function nil)
(isearch-update))
;;;###autoload
@ -57,9 +55,8 @@
(interactive)
(let ((overriding-terminal-local-map nil))
(activate-transient-input-method))
(setq isearch-input-method-function input-method-function
isearch-input-method-local-p t)
(setq input-method-function nil)
(setq isearch-input-method-function input-method-function)
(setq-local input-method-function nil)
(isearch-update))
(defvar isearch-minibuffer-local-map

View file

@ -424,8 +424,7 @@ While this input method is active, the variable
(add-hook 'minibuffer-exit-hook 'robin-exit-from-minibuffer))
(run-hooks 'input-method-activate-hook
'robin-activate-hook)
(set (make-local-variable 'input-method-function)
'robin-input-method)))
(setq-local input-method-function 'robin-input-method)))
(define-obsolete-variable-alias
'robin-inactivate-hook

View file

@ -965,10 +965,6 @@ Each element is an `isearch--state' struct where the slots are
;; The value of input-method-function when isearch is invoked.
(defvar isearch-input-method-function nil)
;; A flag to tell if input-method-function is locally bound when
;; isearch is invoked.
(defvar isearch-input-method-local-p nil)
(defvar isearch--saved-overriding-local-map nil)
;; Minor-mode-alist changes - kind of redundant with the
@ -1238,7 +1234,6 @@ used to set the value of `isearch-regexp-function'."
search-ring-yank-pointer nil
isearch-opened-overlays nil
isearch-input-method-function input-method-function
isearch-input-method-local-p (local-variable-p 'input-method-function)
regexp-search-ring-yank-pointer nil
isearch-pre-scroll-point nil
@ -1259,9 +1254,7 @@ used to set the value of `isearch-regexp-function'."
;; We must bypass input method while reading key. When a user type
;; printable character, appropriate input method is turned on in
;; minibuffer to read multibyte characters.
(or isearch-input-method-local-p
(make-local-variable 'input-method-function))
(setq input-method-function nil)
(setq-local input-method-function nil)
(looking-at "")
(setq isearch-window-configuration
@ -1418,8 +1411,8 @@ NOPUSH is t and EDIT is t."
(set-window-group-start (selected-window) found-start t))))
(setq isearch-mode nil)
(if isearch-input-method-local-p
(setq input-method-function isearch-input-method-function)
(if isearch-input-method-function
(setq-local input-method-function isearch-input-method-function)
(kill-local-variable 'input-method-function))
(if isearch-tool-bar-old-map

Some files were not shown because too many files have changed in this diff Show more