Paul Eggert [Sun, 18 Dec 2022 08:21:30 +0000 (00:21 -0800)]
Remove Gnulib explicit_bzero module
It’s no longer needed, as it is now merely a thin layer around
C23-style memset_explicit and we might as well just call the
C23 standard function; that’s more forward-looking.
* admin/merge-gnulib (GNULIB_MODULES):
Remove explicit_bzero, and add memset_explicit.
* lib/explicit_bzero.c, m4/explicit_bzero.m4:
Remove these files, which were copied from Gnulib.
* lib/gnulib.mk.in, m4/gnulib-comp.m4: Regenerate.
* src/gnutls.c (gnutls_symmetric_aead):
Use memset_explicit instead of explicit_bzero.
Paul Eggert [Sun, 18 Dec 2022 05:40:02 +0000 (21:40 -0800)]
Port better to glibc 2.28+ renameat2
* configure.ac: Check for renameat2.
* src/sysdep.c (renameat_noreplace): Prefer renameat2 (supplied by
glibc 2.28 and later) to doing the syscall by hand.
Wilson Snyder [Sat, 17 Dec 2022 20:00:34 +0000 (15:00 -0500)]
; lisp/progmodes/verilog-mode.el: Collected updates from verilog-mode upstream.
* lisp/progmodes/verilog-mode.el (verilog-beg-block-re-ordered)
(verilog-forward-sexp, verilog-leap-to-head): Support of hideshow
for ifdef/ifndef blocks (#1819).
(verilog-cparenexp-indent-level): Improve multiline indentation
with verilog-indent-lists set to nil. Indent uvm statements and
system tasks and functions according to the argument position in
the parenthesized expression.
(verilog-extended-complete-re): Fix verilog-beg-of-statement on
local methods.
(verilog-beg-of-statement): Fix indentation of properties inside
ifdef (#1817).
(verilog-declaration-varname-matcher, verilog-fontify-variables):
Add option to enable/disable variable fontification.
(verilog-declaration-varname-matcher): Fix bug in highlighting of
vars on func/task arguments.
(verilog-mark-defun): Fix behavior of verilog-mark-defun (#1805).
(verilog-pretty-declarations): Add support to align
declarations/expressions within the region (#1806).
(verilog-align-typedef-regexp, verilog-align-typedef-words): Add
support for alignment of user defined types (#1803).
(verilog-pretty-declarations): Limit alignment of members of a
struct to consecutive valid declarations.
(verilog-typedef-enum-re): Update minor bug in typedef enum regex.
(verilog-indent-declaration): Fix compiler warning on
verilog-indent-declaration.
(verilog-batch-error-wrapper) (verilog-warn-error,
verilog-warn-fatal) (verilog-warn-fatal-internal): Make
`verilog-warn-fatal' safe for local variables (#1799). Reported
by Rich-Cloutier.
(verilog-align-comment-distance, verilog-align-comments)
(verilog-align-decl-expr-comments)
(verilog-align-declaration-comments): Support alignment of
parameter/localparam expressions. Support for expression
alignment in parameter lists. Support declaration/expression
alignment of 'type' parameters. Support alignment of inline
comments after `verilog-pretty-expr'. Alignment of expressions
that do not have blanks before/after operator char Fix on
functions that did not work as expected for this use case. Use
markers in verilog-pretty-expr to avoid bugs while iterating.
(verilog-pretty-expr): Fix bug in alignment of expressions
(#1797).
(verilog-cparenexp-indent-level): Improve indentation of defun
parameters when indent-lists is nil (#1795).
(verilog-align-assign-expr): Add support to align expressions of
continuous assignments (#1793).
(verilog-pretty-expr): Fix bug in boundaries of
verilog-pretty-expr (#1792) and prevent verilog-pretty-expr from
executing on multiline assignments
(verilog-do-indent): Fix indentation of assignments and enums with
indent-lists nil (#1790).
(verilog-do-indent): Fix alignment of structs and enums
(#1789).
(verilog-backward-sexp, verilog-forward-sexp): Add precedence to
paren expressions for sexp funcs navigation (#1788).
(verilog-declaration-varname-matcher): Fix fontifying of variable
names and overriding of keywords (#1787).
(verilog-do-indent): Fix indentation of paren expr if
verilog-indent-lists is nil (#1785).
(verilog-backward-ws&directives): Fix indentation after double
comment (#1784).
(verilog-beg-of-statement-1): Fix indentation of instances and
declarations right after 'begin' (#1782).
(verilog-declaration-comments-distance): Add variable to adjust
aligned comment distance in declarations
(#1779).
(verilog-indent-ignore-multiline-defines): Add indentation ignore
of multiline defines and custom regexps (#1778).
(verilog-align-declaration-comments): Add support to align
comments in declarations (#1775).
(verilog-pretty-declarations): Fix alignment of user types on
ports declarations.
(verilog-do-indent): Fix indentation of virtual, protected and
static class methods when verilog-indent-lists is nil.
(verilog-get-lineup-indent, verilog-pretty-declarations): Fix
alignment of first port declaration (#1167) (#1771).
(verilog-pretty-declarations): Fix alignment of declaration of
interfaces with modports (#636) (#1770).
(verilog-do-indent): Add `verilog-indent-class-inside-pkg' and fix
indentation of classes inside packages (#286) (#1769). Reported
by Gonzalo Larumbe.
(verilog-backward-sexp, verilog-forward-sexp)
(verilog-leap-to-class-head, verilog-leap-to-head): Fix
indentation after interface class (#1047) (#1768). Reported by
Gonzalo Larumbe.
(verilog-do-indent): Fix indentation if verilog-indent-lists is
nil (#1703) (#1767). Reported by Gonzalo Larumbe.
(verilog-do-indent): Fix indentation of coverpoints (#1321)
(#1766).
(verilog-backward-sexp, verilog-forward-sexp)
(verilog-leap-to-head): Fix bug in forward-sexp and backward-sexp
for some constructs (#1765) Reported by Gonzalo Larumbe.
* lisp/cedet/semantic/complete.el (semantic-displayer-show-request):
* lisp/descr-text.el (describe-char-categories):
* lisp/mh-e/mh-identity.el (mh-select-identity):
* lisp/transient.el (transient--delay-post-command)
(transient--post-command):
* lisp/vc/vc-git.el (vc-git-create-tag):
* test/lisp/emacs-lisp/cl-lib-tests.el
(cl-lib-nth-value-test-multiple-values):
* lisp/emulation/viper-cmd.el (viper-preserve-cursor-color):
Use `equal` instead of `eq` and `member` instead of `memq` where
the comparison is with literals without guaranteed identity.
In some cases this change corrects evident bugs, in others it is
mostly cosmetic.
* lisp/emacs-lisp/byte-opt.el (byte-optimize-if):
Remove explicit clauses purposing to simplify
(if X nil t) -> (not X)
(if X t nil) -> (not (not X))
but never did so because of a coding mistake (eq instead of equal),
found by a recently added warning. They weren't actually needed
thanks to the optimiser's fixpoint iteration: we eventually get the
same results through
(if X nil t) -> (if (not X) t nil) -> (if (not X) t) -> (not X)
(if X t nil) -> (if X t) -> (not (not X))
* lisp/emacs-lisp/gv.el (alist-get):
Evaluate TESTFN exactly once (previously up to 3 times).
Reduce the macro-expansion to include a call to either assoc or assq,
not both; this reduces the generated code size in some cases.
Eli Zaretskii [Fri, 16 Dec 2022 16:26:14 +0000 (18:26 +0200)]
New option for selecting symbols by double-clicking
* lisp/mouse.el (mouse-1-double-click-prefer-symbols): New user
option.
(mouse-skip-word): If 'mouse-1-double-click-prefer-symbols' is
non-nil, skip over the entire symbol at point. (Bug#60080)
* lisp/tab-bar.el: Use #' to quote function names.
Try and fit within 80 columns.
(tab-bar--load-buttons): Silence compiler warnings about `icons` functions.
(tab-bar-auto-width): Avoid the use of `substring` as a gv-place
because it requires `cl-lib` which we don't (want to) preload.
[ Maybe a better solution would be to not preload tab-bar.el. ]
Stefan Kangas [Fri, 16 Dec 2022 07:45:06 +0000 (08:45 +0100)]
Merge from origin/emacs-29
033071692c7 ; Fix typos f4a513344d9 Add lambda_expression-rule to java-ts-mode (bug#60091) 546aed35434 eglot: Add support for new language server csharp-ls cb761eb7ac4 Use the new tree-sitter commands 037407ad95a Add "function" feature to python-ts-mode (bug#59977) fee2efe1b03 Add go-ts-mode and go-mod-ts-mode (Bug#60025) e8f7ab67ad1 Add basic support for hideshow in python-ts-mode (bug#60044) cac070b23e4 Add "this" keyword to java-ts-mode (bug#60086) c8d75046a2f When completing relative project file names, use relative... 3b618d0e3ed Avoid segfaults due to invalid selected-window's buffer
Stefan Kangas [Fri, 16 Dec 2022 07:33:47 +0000 (08:33 +0100)]
Fix typo in rcirc function name
* lisp/net/rcirc.el (rcirc-format-strike-through): Rename from
'rcirc-format-strike-trough'. Make old name into obsolete
function alias. Update all uses.
Stefan Kangas [Fri, 16 Dec 2022 06:49:17 +0000 (07:49 +0100)]
Fix typo in rcirc variable name
* lisp/net/rcirc.el (rcirc-track-abbreviate-flag): Rename from
misspelled 'rcirc-track-abbrevate-flag'. Make old name into
obsolete variable alias.
* doc/misc/rcirc.texi (Channels): Update above variable name.
Fix lisp/bs.el change in commit e0a057c16b of 2022-12-07
* lisp/bs.el (bs-default-action-list): Before creating a window
first try `display-buffer-reuse-window', but make sure it never
chooses a window in another frame.
Jim Porter [Mon, 12 Dec 2022 04:19:57 +0000 (20:19 -0800)]
; Rename 'eshell-flatten-args' token to 'eshell-splice-immediately'
This is for symmetry with 'eshell-splice-args' (which performs a
splice later on). Since this is just an internal symbol not exposed
to users, changing it is safe.
* lisp/eshell/esh-arg.el (eshell-parse-arguments, eshell-finish-arg):
Use 'eshell-splice-immediately'.
Jim Porter [Wed, 9 Nov 2022 06:49:23 +0000 (22:49 -0800)]
Add support for the "splice operator" in Eshell
This allows splicing lists in-place in argument lists, which is
particularly important when defining aliases using the '$*' special
variable (bug#59960).
* lisp/eshell/esh-var.el (eshell-parse-variable): Add support for the
splice operator.
(eshell-interpolate-variable): Let 'eshell-parse-variable' handle
adding 'eshell-escape-arg'.
(eshell-complete-variable-reference): Handle the splice operator.
* lisp/eshell/esh-arg.el (eshell-concat-groups)
(eshell-prepare-splice): New functions...
(eshell-resolve-current-argument): ... use them.
(eshell-splice-args): New function.
* lisp/eshell/esh-util.el (eshell-list-to-string): New function...
(eshell-flatten-and-stringify): ... use it.
* lisp/eshell/em-cmpl.el (eshell-complete-parse-arguments): Remove
'eshell-splice-args' sigils in Eshell command forms so that we can
perform completion on splice-expansions.
* lisp/eshell/em-unix.el (eshell-complete-host-reference): Don't try
to complete arguments containing "$@".
* test/lisp/eshell/em-alias-tests.el
(em-alias-test/alias-all-args-var-splice): New test.
* doc/misc/eshell.texi (Dollars Expansion): Explain the splice
operator.
(Aliases): Expand documentation and use '$@*'.
(Built-ins, Bugs and Ideas): Use '$@*' where appropriate.
Yuan Fu [Fri, 16 Dec 2022 01:44:07 +0000 (17:44 -0800)]
Use the new tree-sitter commands
* lisp/progmodes/c-ts-mode.el (c-ts-mode--defun-valid-p)
(c-ts-mode--defun-skipper): New functions.
(c-ts-base-mode): Setup defun navigation.
* lisp/progmodes/sh-script.el (bash-ts-mode): Setup defun navigation.
* lisp/treesit.el (treesit-beginning-of-defun)
(treesit-end-of-defun): Change to new implementation, which is
intended to be used as commands.
(treesit-major-mode-setup): Setup remap for beginning/end-of-defun
commands.
Yuan Fu [Fri, 16 Dec 2022 01:25:06 +0000 (17:25 -0800)]
Add "function" feature to python-ts-mode (bug#59977)
* lisp/progmodes/python.el (python--treesit-settings): Add feature.
(python-ts-mode): Add feature. And fix indentation for the
python-indent-guess-indent-offset code.
* lisp/bs.el: Use modern height preserving method instead of hooks
* lisp/bs.el (bs--track-window-changes, bs--remove-hooks): Remove.
(bs-mode): Do not set window-change tracking hooks.
(bs--set-window-height): Pass PRESERVE-SIZE to `fit-window-to-buffer'.
Eli Zaretskii [Thu, 15 Dec 2022 21:39:58 +0000 (23:39 +0200)]
Avoid segfaults due to invalid selected-window's buffer
* lisp/startup.el (initial-scratch-message): Don't use \\[...]
commands for substitute-command-keys.
* lisp/simple.el (get-scratch-buffer-create): Don't call
substitute-command-keys on initial-scratch-message, to avoid
signaling an error in rare cases. (Bug#60096)
Stefan Kangas [Thu, 15 Dec 2022 20:13:16 +0000 (21:13 +0100)]
Merge from origin/emacs-29
99aa00e6e34 Revert 21b387c39bd with last-minute hasty changes (bug#60... 386d6e74d83 Replace an erroneous eq with an equal in cc-defs.el eb069470631 * lisp/tab-bar.el ([tab-bar]): Use 'make-sparse-keymap' i... 26243f7b65e compile.el: Fix regression with nb of errors in modeline 6e2923d80f8 Make tab-bar-tab-group-format-function backwards-compatib... b211a63455c Make tab-bar-tab-group-format-function also handle curren... 367022f316e Ensure package directories for source packages from check... 3a633bdd6df ; * etc/NEWS: Fix recent changes. 6aa5d16c643 * test/README (SELECTOR): Add eglot-tests.el to remote fi... bb27be36ddf Fix bug#60060 in Tramp d4c2aa4f913 ; * lisp/net/tramp-crypt.el: Fix comment. 8404253d17a * .gitignore: Ignore GDB history files. 12684c3a199 Mention 'tree-sitter' in user manual and NEWS 49d7e0cec6a ; * etc/NEWS: Rearrange entries for tree-sitter supported... 0ad2112a2f0 ; Announce 'toml-ts-mode' in NEWS.
Stefan Kangas [Thu, 15 Dec 2022 20:13:14 +0000 (21:13 +0100)]
Merge from origin/emacs-29
a15cd55044c ; Don't quote nil in comments da39200c4be ; Checkdoc fixes in dired-aux.el fd403a5c5a8 Fix ruby-add-log-current-method after nested class defini... 2ca06aed7b3 Add indent rules to js/typescript/tsx-ts-mode (bug#60074) a54d5f500c1 Improve fontification in csharp-ts-mode (bug#59897) 3db2f560bb7 Revert "Add expression for generic_name in csharp-ts-mode" 1985762fbd7 Introduce support for TOML config-format 622838b957e Fix handling of % when searching in .tex or .dtx files 3b226b60248 Treat C++ classes as defuns in C Tree-sitter mode (bug#60... 480f41c7deb Add < and > to the syntax table in c++-ts-mode (bug#60049) fbf0d3b796a Improve fontifications in Typescript mode f93a5180a61 Update the documentation of overlays (bug#59996) d51b66ed540 ; Improve description of scoping and let-bindings 752f9dde631 ; Fix a typo in window.el 102a3e3b445 Don't send erc-sasl-user as USER command argument f0c90888781 Set erc-network to a "given" ID instead of failing 09c0c6b2ba3 Limit casemapping to appropriate ranges in ERC 44b04c0ac1c Actually accept non-symbols as IDs in erc-open 75f26646d4a ; Be nicer when updating browse-url var in erc-compat 0155fc67be3 Respect a nil erc-session-password when reconnecting 9ac80e8a6e4 Add dedicated auth-source section in ERC manual 2d96a18cd09 ; * lisp/emacs-lisp/shortdoc.el: fix mistakes in previous... 1d3cbba7dfa ; * lisp/progmodes/cmake-ts-mode.el (auto-mode-alist): $ ... 0cc199f1a61 Better shortdoc examples 931d97bf563 Shortdoc: read and evaluate strings after :eval be165f75332 Fix Tramp tests in eglot-tests, prefix tests uniquely 8c30cb90ba9 * lisp/vc/vc-git.el (vc-git-checkin): Use make-nearby-tem... 3efe4df1d20 Delete temp files after icalendar tests
Make tab-bar-tab-group-format-function also handle current group
* lisp/tab-bar.el (tab-bar--format-tab-group): Call
'tab-bar-tab-group-format-default' to format current group tab.
(tab-bar-tab-group-format-default): Update function to also handle
current group tab (bug#60073).
Ensure package directories for source packages from checkouts
* lisp/emacs-lisp/package-vc.el (package-vc-install-from-checkout):
Set the :dir entry, since `package-vc--unpack-1' assumes the field is
set, as is the case when invoking `package-vc--unpack'.
Po Lu [Thu, 15 Dec 2022 12:06:37 +0000 (20:06 +0800)]
Handle selection transfer errors earlier
* src/xselect.c (x_decline_selection_request, struct transfer)
(struct x_selection_request, x_cancel_selection_transfer)
(x_start_selection_transfer, x_continue_selection_transfer):
Give the right serial to x_ignore_errors_for_next_request.
(x_handle_selection_error): New function.
(x_reply_selection_request): Give the right serial to
x_ignore_errors_for_next_request.
* src/xterm.c (x_ignore_errors_for_next_request): New arg
`selection_serial'. All callers changed.
(x_error_handler): Call selection error handler.
* src/xterm.h (struct x_failable_request): New field
`selection_serial'.
Eli Zaretskii [Thu, 15 Dec 2022 08:47:11 +0000 (10:47 +0200)]
Mention 'tree-sitter' in user manual and NEWS
* doc/emacs/programs.texi (Program Modes): Mention tree-sitter and
the modes supported by it.
* etc/NEWS: Mention tree-sitter in the Installation Changes
section.
Dmitry Gutov [Thu, 15 Dec 2022 01:21:14 +0000 (03:21 +0200)]
Fix ruby-add-log-current-method after nested class definition
* lisp/progmodes/ruby-mode.el (ruby--add-log-current-indent):
New function.
(ruby-add-log-current-method): Use it.
Check for "class" and "module" indentation to filter out the
definitions which don't include the given position. Also try to
match "def" only once (for performance), because if the closest
one doesn't include the given position, none will.
* test/lisp/progmodes/ruby-mode-tests.el
(ruby-add-log-current-method-after-inner-class-outside-methods)
(ruby-add-log-current-method-after-inner-class-outside-methods-with-text):
New tests.
Add indent rules to js/typescript/tsx-ts-mode (bug#60074)
* lisp/progmodes/typescript-ts-mode.el
(typescript-ts-mode--indent-rules): Add in binary_expression and
jsx_fragment.
* lisp/progmodes/js.el (js--treesit-indent-rules): Add the same rules.
This commit introduces support for the semi-popular TOML
config-format[1] through a new major-mode: toml-ts-mode.
I've read through the full spec[2], and from what I can see this
major-mode should provide correct syntax-highligting for every sort of
config-declaration which adheres to the specification.
Besides that it also adds support for imenu and basic tree-sitter
based navigation.
Daniel Martín [Tue, 13 Dec 2022 21:28:13 +0000 (22:28 +0100)]
Add < and > to the syntax table in c++-ts-mode (bug#60049)
* lisp/progmodes/c-ts-mode.el (c++-ts-mode--syntax-table): Add a
specific syntax table for C++. Consider "<" and ">" open/close
delimiters (C++ templates).
(c++-ts-mode): Use the new syntax table.
Warn about unmatchable constant args to `eq`, `memq` etc
Add a byte-compiler warning about attempts to compare literal values
with undefined identity relation to other values. For example:
(eq x 2.0)
(memq x '("a" (b) [c]))
Such incomparable values include all literal conses, strings, vectors,
records and (except for eql and memql) floats and bignums.
The warning currently applies to eq, eql, memq, memql, assq, rassq,
remq and delq.
* lisp/emacs-lisp/bytecomp.el (bytecomp--dodgy-eq-arg)
(bytecomp--value-type-description, bytecomp--arg-type-description)
(bytecomp--warn-dodgy-eq-arg, bytecomp--check-eq-args)
(bytecomp--check-memq-args): New.
(eq, eql, memq, memql, assq, rassq, remq, delq):
Set compiler-macro property.
* lisp/emacs-lisp/byte-run.el (with-suppressed-warnings):
Amend doc string.
* test/lisp/emacs-lisp/bytecomp-tests.el
(bytecomp--with-warning-test): Fix text-quoting-style and expand
re-warning so that it doesn't need to be a literal.
(bytecomp-warn-dodgy-args-eq, bytecomp-warn-dodgy-args-memq):
New tests.
Eli Zaretskii [Wed, 14 Dec 2022 18:13:47 +0000 (20:13 +0200)]
Update the documentation of overlays (bug#59996)
* src/buffer.c (Foverlay_recenter, Foverlay_lists): Update the doc
strings.
* lisp/subr.el (copy-overlay): Update comment.
* doc/lispref/internals.texi (Buffer Internals): Remove buffer
fields relevant to the old implementation; add the new interval
tree field.
* doc/lispref/display.texi (Overlays, Managing Overlays): Update
text to be consistent with the new implementation of overlays.
(Managing Overlays): Remove documentation of 'overlay-recenter'.
* etc/NEWS: Mention incompatible aspects of overlay
reimplementation.
Eli Zaretskii [Wed, 14 Dec 2022 15:46:16 +0000 (17:46 +0200)]
; Improve description of scoping and let-bindings
* doc/lispref/variables.texi (Local Variables, Variable Scoping):
Explain the move to lexical-binding and elaborate on 'let*'.
Suggested by Michael Heerdegen <michael_heerdegen@web.de>.
(Bug#60027)
Eli Zaretskii [Wed, 14 Dec 2022 14:53:29 +0000 (16:53 +0200)]
Make proced-tests work on more systems
* test/lisp/proced-tests.el (proced-format-test)
(proced-update-test, proced-revert-test, proced-color-test):
Remove the 'skip-unless' condition, as it is unnecessary.
(proced-refine-test, proced-refine-with-update-test): Use PID, not
Args, as the column to test, as PID is more portable.
F. Jason Park [Tue, 13 Dec 2022 07:58:03 +0000 (23:58 -0800)]
Don't send erc-sasl-user as USER command argument
* lisp/erc/erc-sasl.el (erc-sasl--send-cap-ls): Add internal switch
for sending an opening "CAP LS". The rationale for not enabling this
by default is twofold: one, it more strongly implies that ERC supports
IRCv3 client capability negotiation, which is somewhat disingenuous;
and, two, We'd still be "faking it" by firing and forgetting, and more
balls in the air makes things less predictable.
(erc--register-connection): Possibly send a "CAP LS" before anything
depending on the value of `erc-sasl--send-cap-ls'. Also, don't
attempt to send `erc-session-username' when it holds an SASL username
because the latter may contain protocol-defying characters.
* test/lisp/erc/resources/base/local-modules/fourth.eld: change user
parameter of "USER" command to reflect nick when `erc-sasl-user' is
set to `:user'. (Bug#59976.)
F. Jason Park [Tue, 13 Dec 2022 07:58:03 +0000 (23:58 -0800)]
Set erc-network to a "given" ID instead of failing
* lisp/erc/erc-networks.el (erc-networks--determine): Return the
so-called "given" ID from a non-nil `:id' keyword arg passed to `erc'
or `erc-tls'.
(erc-networks--allow-unknown-network): Add internal variable to
allow IRC session to continue despite the network being unknown.
(erc-networks--set-name): Tell the user about falling back to a given
ID when the network can't be determined. When that's so, end the
session by destroying the connection unless
`erc-networks--allow-unknown-network' is enabled. (Bug#59976.)
(erc-networks--ensure-announced): Include the fallback announced
server name in the error message.
* test/lisp/erc/erc-networks-tests.el (erc-networks--set-name): Add
dummy server process and don't expect an error to be signaled.
* test/lisp/erc/erc-scenarios-misc.el
(erc-scenarios-networks-announced-missing): Don't expect an error to
be signaled.
* test/lisp/erc/resources/networks/announced-missing/foonet.eld:
Remove "mode" match pattern.
F. Jason Park [Mon, 12 Dec 2022 03:41:43 +0000 (19:41 -0800)]
Limit casemapping to appropriate ranges in ERC
* lisp/erc/erc-common.el (erc-downcase): Use case table for
`erc-downcase' so that case conversions are limited to the ASCII
interval.
* lisp/erc/erc.el (erc-casemapping--rfc1459-strict,
erc--casemapping-rfc1459): Make these case tables instead of
translation tables. The functions in case-table.el modify the
standard syntax table, but that doesn't seem to make sense here,
right?
* test/lisp/erc/erc-tests.el (erc-downcase): Add cases showing
mappings outside of the ASCII range. (Bug#59976.)
F. Jason Park [Mon, 12 Dec 2022 03:41:43 +0000 (19:41 -0800)]
Actually accept non-symbols as IDs in erc-open
* lisp/erc/erc.el (erc-generate-new-buffer-name): Despite what it says
in the documentation, only symbols were being accepted as valid `:id'
entry-point arguments. This uses the interned `princ' representation
of the argument instead.
* test/lisp/erc/erc-scenarios-base-netid-samenet.el
(erc-scenarios-common--base-network-id-same-network): Randomly specify
a string for the ID param instead of a non-nil symbol when opening a
new connection.
* test/lisp/erc/resources/erc-scenarios-common.el
(erc-scenarios-common-assert-initial-buf-name): Adjust helper to allow
for non-symbol IDs. (Bug#59976.)
F. Jason Park [Mon, 12 Dec 2022 03:16:07 +0000 (19:16 -0800)]
; Be nicer when updating browse-url var in erc-compat
* lisp/erc/erc-compat.el: Be more cautious about modifying
`browse-url-default-handlers' when loading erc-compat on Emacs 28. A
user may have already added an entry for irc:// URLs before loading
`erc-compat'.
F. Jason Park [Sat, 3 Dec 2022 07:11:24 +0000 (23:11 -0800)]
Respect a nil erc-session-password when reconnecting
* lisp/erc/erc.el (erc-open): Simplify `old-vars' expression.
(erc--compute-server-password): Only compute a server password when
first connecting. For compatibility, this respects third-party code
that expects session passwords in target buffers when initially
non-nil.
* test/lisp/erc/erc-scenarios-services-misc.el
(erc-scenarios-services-auth-source-reconnect): Add new test.
* test/lisp/erc/resources/services/auth-source/recon.eld: Add new test
data file. (Bug#59858.)
F. Jason Park [Thu, 1 Dec 2022 07:10:58 +0000 (23:10 -0800)]
Add dedicated auth-source section in ERC manual
* doc/misc/erc.texi: Move auth-source description from the Password
subheading of the Advanced chapter's Connecting section to the new
Integrations section as a new node, Auth-Source, and give it a bit
more structure. Fix various misuses of xref vs. pxref. Convert URL
subheading to subsection and add anchor. Prefer "backend" as a single
word, based on usage in other manuals. Also replace loud "warning" in
SASL troubleshooting section.
* etc/ERC-NEWS: Re-link auth-source mention.
* lisp/erc/erc-sasl.el (erc-sasl-auth-source-function): Update info
node in doc string.
* lisp/erc/erc-services.el (erc-auth-source-services-function):
Re-link auth-source info node in doc string.
* lisp/erc/erc.el (erc-password, erc-auth-source-server-function,
erc-auth-source-join-function): Re-link auth-source info node in doc
strings.
Laurence Warne [Sat, 3 Dec 2022 21:41:57 +0000 (21:41 +0000)]
Make proced-update preserve refinements
Make proced-update preserve refinements by creating a new buffer local
variable proced-refinements which stores information about the current
refinements and is used by proced-update to further refine
proced-process-alist in the case it is non-nil. The result is that
refinements are not immediately cleared when a proced buffer is
updated with proced-auto-update-flag non-nil. proced-revert
maintains its current behaviour of clearing any active refinements.
* lisp/proced.el (proced-refinements): New buffer local variable
which tracks the current refinements.
(proced-refine): Set 'proced-refinements' variable and defer setting of
'proced-process-alist' to 'proced-update'.
(proced-update): Take into account 'proced-refinements' when setting
'proced-process-alist'.
(proced-revert): Set 'proced-refinements' to nil prior to calling
'proced-update'.
* lisp/emacs-lisp/shortdoc.el
(symbol, comparison): New.
(string, list, number): Remove or change examples that do not have
well-defined results, such as `eq` on strings or floats.
Edit other examples for better illustrating each respective operation.
* lisp/emacs-lisp/shortdoc.el (shortdoc--display-function):
If the parameter of :eval is a string then read, evaluate and print
the result. This was always the intention and is documented behaviour.
Michael Albinus [Wed, 14 Dec 2022 09:52:04 +0000 (10:52 +0100)]
Fix Tramp tests in eglot-tests, prefix tests uniquely
* test/lisp/progmodes/eglot-tests.el (eglot--call-with-fixture):
Use `make-nearby-temp-file'.
(eglot--call-with-tramp-test): Set `tramp-verbose' and
`default-directory'. The latter is needed for `make-nearby-temp-file'.
(eglot-test-tramp-test, eglot-test-tramp-test-2): Tag them as
:expensive-test.
(all): Prefix all tests with `eglot-test-' uniquely.