Commit graph

6325 commits

Author SHA1 Message Date
Noam Postavsky
8c0ae0f93a Let byte-compiler recognize that local-variable-p implies boundp
* lisp/emacs-lisp/bytecomp.el (byte-compile-maybe-guarded): Add
arguments to local-variable-p to the bound list.
* lisp/image-mode.el (image-toggle-display-image): Remove no longer
needed boundp check.
2019-09-07 17:00:39 -04:00
Lars Ingebrigtsen
4c3a40a9b7 Make the NSM not pop up an X dialogue on non-mouse actions
* lisp/emacs-lisp/rmc.el (read-multiple-choice): Don't pop up X
dialogues on (url-retrieve "https://expired.badssl.com/" #'ignore)
and the like.
2019-09-04 15:20:00 +02:00
Lars Ingebrigtsen
9df72ecb63 Preserve more markers when reverting .gpg files
* lisp/epa-file.el (epa-file--replace-text): Gingerly replace the
text in the buffer to preserve as many markers as possible
(bug#34720).  This emulates the behaviour of Finsert_file_contents
more accurately.
(epa-file-decode-and-insert): Remove compat code.
(epa-file-insert-file-contents): Use the new function.

* lisp/emacs-lisp/cl-lib.el (cl-incf): Add autoload cookie.
2019-09-04 15:20:00 +02:00
Mattias Engdegård
4051fa3ba9 Clarify what counts as whitespace in `string-blank-p'
* lisp/emacs-lisp/subr-x.el (string-blank-p): Expand doc string.
2019-09-01 14:28:01 +02:00
Thomas Fitzsimmons
e8c46c2b6f package.el: Allow Package-Requires to span multiple lines (Bug#36301)
* lisp/emacs-lisp/package.el (lm-header-multiline): Declare
function.
(package-buffer-info): Parse Package-Requires with
lm-header-multiline instead of lm-header.
(Bug#36301)

Co-authored-by: Noam Postavsky <npostavs@gmail.com>
2019-08-31 21:20:00 -04:00
Lars Ingebrigtsen
ed44217d32 Fix completion in `read-library-name'
* lisp/emacs-lisp/find-func.el (read-library-name): Only list
.el/.el.gz files when completing (bug#36945).
2019-08-27 09:46:28 +02:00
Eli Zaretskii
0fa1850352 ; * lisp/emacs-lisp/cl-lib.el (cl-pushnew): Doc fix. 2019-08-23 11:43:30 +03:00
Lars Ingebrigtsen
e7d3ddf689 Clarify doc string of cl-pushnew
* lisp/emacs-lisp/cl-lib.el (cl-pushnew): Clarify doc string
(bug#37016).
2019-08-23 06:12:44 +02:00
Stefan Kangas
1f441de5fe Fix minor checkdoc errors in package.el
* lisp/emacs-lisp/package.el (package-all-keywords)
(package-menu--generate, package-archive-priority): Doc fixes.
2019-08-22 19:17:51 +02:00
Stefan Kangas
a6d87ea045 Signal user-error on duplicate package refresh
* lisp/emacs-lisp/package.el (package-menu-refresh): Signal a
user-error if there is already a refresh running in the
background.  Doc fix.  (Bug#36707)
2019-08-22 18:57:39 +02:00
Noam Postavsky
7e2090ee80 Respect global-eldoc-mode in minibuffers (Bug#36886)
* lisp/emacs-lisp/easy-mmode.el (define-globalized-minor-mode): Accept
a BODY parameter.
* doc/lispref/modes.texi (Defining Minor Modes): Document new
parameter.
* etc/NEWS: Announce it.

* lisp/simple.el (read--expression): Move eldoc-mode setup to...
* lisp/emacs-lisp/eldoc.el (eldoc--eval-expression-setup): ... here,
new function.
(global-eldoc-mode): Add or remove it to
eval-expression-minibuffer-setup-hook when enabling or disabling
global-eldoc-mode.  This enables eldoc in the minibuffer (solving
Bug#27202), only when global-eldoc-mode is enabled.
2019-08-20 20:20:52 -04:00
Glenn Morris
8f68449c94 Merge from origin/emacs-26
0b810eb Fix a typo in char-width-table
3f00db7 Minor update in admin/notes/unicode
bcd0115 Fix lisp indent infloop on unfinished strings (Bug#37045)
5f992d1 Improve commentary in composite.el
3a04be2 ; Improve commentary in xdisp.c
15de1d1 Fix markup in dired-x.texi
bda7fc7 ; Fix typo in a doc string of speedbar.el
6f57ef9 * src/callproc.c (Fcall_process): Doc fix.

# Conflicts:
#	doc/misc/dired-x.texi
#	lisp/international/characters.el
#	src/callproc.c
2019-08-20 09:01:55 -07:00
Noam Postavsky
bcd0115e4d Fix lisp indent infloop on unfinished strings (Bug#37045)
* lisp/emacs-lisp/lisp-mode.el (lisp-indent-calc-next): Stop trying to
skip over strings if we've hit the end of buffer.
* test/lisp/emacs-lisp/lisp-mode-tests.el
(lisp-indent-unfinished-string): New test.
2019-08-17 09:42:34 -04:00
Alex Branham
496bab789d Make checkdoc check cl-lib function docstrings
* lisp/emacs-lisp/checkdoc.el (checkdoc-this-string-valid-engine):
Remove calls to delete-region to avoid deleting final " (bug#26328).
* lisp/emacs-lisp/checkdoc.el (checkdoc--next-docstring)
(checkdoc-defun-info): Include cl-defun, cl-defgeneric,
cl-defmethod.
(checkdoc-this-string-valid-engine): Add cl-lib supported
keywords.
(checkdoc-defun-info): Ensure function parameters are a
"flat" list (bug#37034).
2019-08-16 14:00:31 -07:00
Alex Branham
91c7c6a602 Avoid deleting closing quotation mark in checkdoc
* lisp/emacs-lisp/checkdoc.el (checkdoc-this-string-valid-engine):
Remove calls to delete-region to avoid deleting final " (bug#26328).
2019-08-16 13:55:34 -07:00
Thomas Fitzsimmons
a9d7ccfa56 Revert "package.el: Allow Package-Requires to span multiple lines (Bug#36301)"
This reverts commit 19c1e4c81c.

This commit broke some package tests, reverting for now.
2019-08-16 12:18:44 -04:00
Thomas Fitzsimmons
19c1e4c81c package.el: Allow Package-Requires to span multiple lines (Bug#36301)
* lisp/emacs-lisp/package.el (lm-header-multiline): Declare
function.
(package-buffer-info): Parse Package-Requires with
lm-header-multiline instead of lm-header.
(Bug#36301)
2019-08-16 00:02:13 -04:00
Lars Ingebrigtsen
b3713265cb Rename variables and functions with "auto-load" in their names
* doc/emacs/building.texi (Lisp Libraries): Adjust documentation.

* lisp/help-fns.el (help--symbol-completion-table): Adjust usage.

* lisp/help-fns.el (help-enable-completion-autoload): Change name
from auto-load and declare an obsolete alias (bug#13418).

* lisp/help.el (help-enable-autoload): Ditto.

* lisp/progmodes/vhdl-mode.el: Ditto.
(vhdl-create-mode-menu, vhdl-mode): Adjust usage.
(vhdl-autoload-project): Rename from auto-load and declare an
obsolete alias.
2019-08-15 16:02:20 -07:00
Lars Ingebrigtsen
1a20553100 Output the maintainer and author(s) in the package description buffer
* lisp/emacs-lisp/package.el (describe-package-1): Output
maintainer and author(s) (bug#17573).
(package--print-email-button): New function.
2019-08-14 16:35:16 -07:00
Philippe Schnoebelen
65e4ebdfb6 Support bool-vectors in cl-extra.el
* lisp/emacs-lisp/cl-extra.el (cl-coerce): Support bool-vector.

Copyright-paperwork-exempt: yes
2019-08-10 11:14:44 +03:00
Stefan Monnier
1d8b5bc8dd Move cl.el to lisp/obsolete
* lisp/emacs-lisp/cl.el: Move from here...
* lisp/obsolete/cl.el: ...to here.

* lisp/subr.el (do-after-load-evaluation): Use "deprecated" in the
message when loading packages from lisp/obsolete.
2019-08-06 04:01:49 -04:00
Paul Eggert
89c63b3522 New function time-convert
This replaces the awkward reuse of encode-time to both convert
calendrical timestamps to Lisp timestamps, and to convert Lisp
timestamps to other forms.  Now, encode-time does just the
former and the new function does just the latter.
The new function builds on a suggestion by Lars Ingebrigtsen in:
https://lists.gnu.org/r/emacs-devel/2019-07/msg00801.html
and refined by Stefan Monnier in:
https://lists.gnu.org/r/emacs-devel/2019-07/msg00803.html
* doc/lispref/os.texi (Time of Day, Time Conversion):
* doc/misc/emacs-mime.texi (time-date):
* etc/NEWS: Update documentation.
* lisp/calendar/cal-dst.el (calendar-next-time-zone-transition):
* lisp/calendar/time-date.el (seconds-to-time, days-to-time):
* lisp/calendar/timeclock.el (timeclock-seconds-to-time):
* lisp/cedet/ede/detect.el (ede-detect-qtest):
* lisp/completion.el (cmpl-hours-since-origin):
* lisp/ecomplete.el (ecomplete-add-item):
* lisp/emacs-lisp/cl-extra.el (cl--random-time):
* lisp/emacs-lisp/timer.el (timer--time-setter)
(timer-next-integral-multiple-of-time):
* lisp/find-lisp.el (find-lisp-format-time):
* lisp/gnus/gnus-diary.el (gnus-user-format-function-d):
* lisp/gnus/gnus-group.el (gnus-group-set-timestamp):
* lisp/gnus/gnus-icalendar.el (gnus-icalendar-show-org-agenda):
* lisp/gnus/nnrss.el (nnrss-normalize-date):
* lisp/gnus/nnspool.el (nnspool-request-newgroups):
* lisp/net/ntlm.el (ntlm-compute-timestamp):
* lisp/net/pop3.el (pop3-uidl-dele):
* lisp/obsolete/vc-arch.el (vc-arch-add-tagline):
* lisp/org/org-clock.el (org-clock-get-clocked-time)
(org-clock-resolve, org-resolve-clocks, org-clock-in)
(org-clock-out, org-clock-sum):
* lisp/org/org-id.el (org-id-uuid, org-id-time-to-b36):
* lisp/org/ox-publish.el (org-publish-cache-ctime-of-src):
* lisp/proced.el (proced-format-time):
* lisp/progmodes/cc-cmds.el (c-progress-init)
(c-progress-update):
* lisp/progmodes/cperl-mode.el (cperl-time-fontification):
* lisp/progmodes/flymake.el (flymake--schedule-timer-maybe):
* lisp/progmodes/vhdl-mode.el (vhdl-update-progress-info)
(vhdl-fix-case-region-1):
* lisp/tar-mode.el (tar-octal-time):
* lisp/time.el (emacs-uptime):
* lisp/url/url-auth.el (url-digest-auth-make-cnonce):
* lisp/url/url-util.el (url-lazy-message):
* lisp/vc/vc-cvs.el (vc-cvs-parse-entry):
* lisp/vc/vc-hg.el (vc-hg-state-fast):
* lisp/xt-mouse.el (xterm-mouse-event):
* test/lisp/emacs-lisp/timer-tests.el:
(timer-next-integral-multiple-of-time-2):
Use time-convert, not encode-time.
* lisp/calendar/icalendar.el (icalendar--decode-isodatetime):
Don’t use now-removed FORM argument for encode-time.
It wasn’t crucial anyway.
* lisp/emacs-lisp/byte-opt.el (side-effect-free-fns): Add time-convert.
* lisp/emacs-lisp/elint.el (elint-unknown-builtin-args):
Update encode-time signature to match current arg set.
* lisp/emacs-lisp/timer.el (timer-next-integral-multiple-of-time):
Use timer-convert with t rather than doing it by hand.
* src/timefns.c (time_hz_ticks, time_form_stamp, lisp_time_form_stamp):
Remove; no longer needed.
(decode_lisp_time): Rturn the form instead of having a *PFORM arg.
All uses changed.
(time_arith): Just return TICKS if HZ is 1.
(Fencode_time): Remove argument FORM.  All callers changed.
Do not attempt to encode time values; just encode
decoded (calendrical) times.
Unless CURRENT_TIME_LIST, just return VALUE since HZ is 1.
(Ftime_convert): New function, which does the time value
conversion that bleeding-edge encode-time formerly did.
Return TIME if it is easy to see that it is already
of the correct form.
(Fcurrent_time): Mention in doc that the form is planned to change.
* test/src/timefns-tests.el (decode-then-encode-time):
Don’t use (encode-time nil).
2019-08-05 18:37:29 -07:00
Michael Heerdegen
bbb41a2071 Clarify macroexp-let* doc string
* lisp/emacs-lisp/macroexp.el (macroexp-let2*): Clarify doc
string (bug#19371).
2019-08-04 14:43:43 +02:00
Kevin Ryde
0e3e012215 easy-menu-define doc string fix
* emacs-lisp/easymenu.el (easy-menu-define): Docstring :label and
:help of the menu itself.
2019-08-03 20:32:24 +02:00
Andreas Politz
95d2250bcf Tweak tq queue processing
* lisp/emacs-lisp/tq.el (tq-process-buffer): Pop the queue before
calling the function because the function may add new entries to
the queue (bug#19016).  Also report errors.
2019-08-03 16:33:06 +02:00
Lars Ingebrigtsen
8edd4bc22a Fix previous macroexp-progn doc string fix
* lisp/emacs-lisp/macroexp.el (macroexp-progn): Fix previous doc
string clarification.
2019-08-03 13:48:31 +02:00
Lars Ingebrigtsen
e56e85d227 macroexp doc fixes
* lisp/emacs-lisp/macroexp.el (macroexp-progn): Doc clarification
(bug#19371).
(macroexp-let*): Doc fix.
2019-08-02 23:11:28 +02:00
Lars Ingebrigtsen
530a4af66c macroexp--cons doc fix
* lisp/emacs-lisp/macroexp.el (macroexp--cons): Doc fix (bug#19371).
2019-08-02 23:03:47 +02:00
Lars Ingebrigtsen
51cf2eb5c9 Document batch-byte-compile directory behavior
* lisp/emacs-lisp/bytecomp.el (batch-byte-compile): Document the
behaviour with directories (bug#20867).
2019-08-01 23:16:37 +02:00
Basil L. Contovounesios
2267110b6f Fix usage of remove-text-properties
* lisp/allout-widgets.el (allout-decorate-item-icon):
* lisp/emacs-lisp/chart.el (chart-goto-xy):
* lisp/forms.el (forms--make-format)
(forms--make-format-elt-using-text-properties):
* lisp/htmlfontify.el (hfy-unmark-trailing-whitespace):
* lisp/net/newst-plainview.el (newsticker-hide-entry)
(newsticker-show-entry):
* lisp/nxml/nxml-mode.el (nxml-cleanup):
* lisp/obsolete/longlines.el (longlines-unshow-hard-newlines)
(longlines-encode-region):
* lisp/org/ob-exp.el (org-babel-exp-process-buffer):
* lisp/org/org-agenda.el (org-agenda-show-new-time):
* lisp/progmodes/cc-defs.el
(c-clear-char-property-with-value-function)
(c-clear-char-property-with-value-on-char-function):
* lisp/progmodes/ebrowse.el (ebrowse--hide):
* lisp/progmodes/gdb-mi.el (gdb-send):
* lisp/progmodes/idlw-shell.el
(idlwave-retrieve-expression-from-level):
* lisp/progmodes/make-mode.el (makefile-fill-paragraph):
* lisp/progmodes/prog-mode.el (prettify-symbols--post-command-hook):
* lisp/progmodes/ruby-mode.el (ruby-syntax-propertize):
* lisp/tmm.el (tmm-remove-inactive-mouse-face):
Always pass an explicit plist to remove-text-properties.

* lisp/dired.el (dired--unhide):
* lisp/facemenu.el (facemenu-add-face):
* lisp/htmlfontify.el (hfy-fontify-buffer):
* lisp/iimage.el (iimage-mode-buffer):
* lisp/image-file.el (image-file-yank-handler):
* lisp/progmodes/prog-mode.el (prettify-symbols--compose-symbol):
* lisp/textmodes/tex-mode.el (latex-env-before-change):
* test/src/undo-tests.el (undo-test0):
Use remove-list-of-text-properties in place of
remove-text-properties where appropriate.
2019-08-01 17:04:53 +03:00
Glenn Morris
1ac0cfa264 Merge from origin/emacs-26
8fbe462 (origin/emacs-26) ; * doc/lispref/positions.texi (List Motion...
1d9efc0 Add index for "\( in strings" (Bug#25195)
304e96f Fix doc-string of 'fit-window-to-buffer' (Bug#36848)
d4c4987 Update view-mode docstring
d6ca1fc ; * lisp/term.el: Add missing / to esc seq commentary.
b3e2073 Fix subproc listening when setting filter to non-t (Bug#36591)
f671950 * etc/NEWS.25: Belatedly announce rcirc-reconnect-delay.
7f42277 Mention term.el's \032 dir tracking in commentary (Bug#19524)
16a529e Remove upload functionality of package-x from the elisp manual
78e6c2a * etc/AUTHORS: Update.
086a56e Clarify Gravatar docs
0592467 * doc/lispref/display.texi (Defining Faces): Say a face can't...

# Conflicts:
#	doc/emacs/programs.texi
#	etc/AUTHORS
#	lisp/term.el
2019-07-30 21:42:34 -07:00
Noam Postavsky
77fb84e6db * lisp/emacs-lisp/let-alist.el: Bump version to 1.0.6 (Bug#23244). 2019-07-30 21:13:36 -04:00
Stephen Leake
0173962570 Merge commit '9b480db673' 2019-07-30 11:03:15 -07:00
Stephen Leake
056cbcb7a9 Improve doc strings for some -search-path variables
* lisp/emacs-lisp/bytecomp.el (emacs-lisp-compilation-search-path):
Improve doc string.

* lisp/progmodes/compile.el (compilation-search-path): Improve doc
string.

* lisp/progmodes/grep.el (grep-search-path): Improve doc string.
2019-07-30 11:02:03 -07:00
Lars Ingebrigtsen
66a74f8415 Use decoded time accessors in timer
* lisp/emacs-lisp/timer.el (run-at-time): Use decoded time
accessors.
2019-07-30 13:08:49 +02:00
Stefan Monnier
75361be63f * lisp/emacs-lisp/cl-macs.el (cl-defstruct): Add slot option :documentation
Use it to improve the docstring of the accessor functions.

* doc/misc/cl.texi: Rename menu entry to "CL-Lib".
(Structures): Add ':documentation' and mention ':type' as well,
which we don't completely ignore any more.
2019-07-29 11:56:11 -04:00
Lars Ingebrigtsen
d7665ae8df Make let-alist work with vectors
* lisp/emacs-lisp/let-alist.el (let-alist--deep-dot-search):
Descend into vectors, too, looking for dotted variables (bug#23244).

Test case:

(let-alist '((a . 1) (b . 2))
  `[,(+ .a) ,(+ .a .b .b)])
2019-07-28 23:28:24 +02:00
Eli Zaretskii
42e4fb8ae9 ; * lisp/emacs-lisp/derived.el (define-derived-mode): Doc fix. 2019-07-28 17:31:17 +03:00
Lars Ingebrigtsen
efc6301068 Make URLs in package descriptions into links
* lisp/emacs-lisp/package.el (describe-package-1): Make the URLs
in package descriptions into links (bug#23480).
2019-07-28 16:01:45 +02:00
Lars Ingebrigtsen
f82ae2fc87 Make cl-values-list signal an error if its argument isn't a list
* lisp/emacs-lisp/cl-lib.el (cl-values-list): Signal an error if
LIST isn't a list (bug#23597).
2019-07-28 14:14:46 +02:00
Lars Ingebrigtsen
3a556c0c60 Fix testcover.el usage of edebug.el symbols
* lisp/emacs-lisp/testcover.el (testcover-before)
(testcover-after, testcover-mark)
(testcover-analyze-coverage-edebug-after): Adjust usage of
`unknown' to `edebug-unknown' in testcover.el in addition to
edebug.el (bug#25471).
2019-07-28 11:39:22 +02:00
Stefan Monnier
77ee23d1ed * lisp/emacs-lisp/autoload.el: Make progress info more informative.
(update-directory-autoloads): Include the name of the target file.
2019-07-27 17:53:46 -04:00
Stefan Monnier
1c8405e33e * lisp/emacs-lisp/bytecomp.el (byte-compile-out-toplevel): Fix bug#34757
This fix was provided by Pip Cet <pipcet@gmail.com>.  It tightens the
code that tries to recognize a bytecode sequence as being a simple
function call (to then decompile it), which occasionally misfired.

I added some minor changes found while investigating this issue.

(byte-compile): Handle corner case where byte-compile-top-level returns
a non-self-evaluating expression.
(byte-compile-out-toplevel): Remove support for `progn` and `t` values
of output-type which aren't used anywhere.
2019-07-27 17:28:10 -04:00
Lars Ingebrigtsen
1d4355261d Doc fix for package-menu-filter
* lisp/emacs-lisp/package.el (package-menu-filter): Document the
use of arc:ARCHIVE and status:STATUS (bug#24883).
2019-07-27 14:38:40 +02:00
Lars Ingebrigtsen
60511bd89d edebug.el comment fix
* lisp/emacs-lisp/edebug.el: Fix comment referring to non-existent
variable (bug#25188).
2019-07-27 13:34:17 +02:00
Lars Ingebrigtsen
02bb676a05 Rename coverage symbols in edebug to avoid collisions
* lisp/emacs-lisp/edebug.el (edebug-clear-coverage): Use
edebug-unknown and edebug-ok-coverage instead of unknown and
ok-coverage to avoid naming collisions with packages that use
those two symbols (bug#25471).
(edebug--update-coverage, edebug-display-freq-count): Ditto.
2019-07-27 12:21:30 +02:00
Lars Ingebrigtsen
2cc5bb67ff define-derived-mode doc string clarification
* lisp/emacs-lisp/derived.el (define-derived-mode): Doc string
clarification about the keywords (bug#26301).
2019-07-27 12:04:58 +02:00
Paul Eggert
40b067522f Fix ‘make check’ failure
Problem introduced in 2019-07-26T07:08:40!larsi@gnus.org.
* lisp/emacs-lisp/ert.el (ert-summarize-tests-batch-and-exit):
Don’t count "0 unexpected" as unexpected.
2019-07-26 09:41:55 -07:00
Lars Ingebrigtsen
3a373bc235 Minor rewording of a couple of sentences in define-derived-mode doc
* lisp/emacs-lisp/derived.el (define-derived-mode): Reword
documentation to be less whimsical (bug#26301).
2019-07-26 13:05:08 +02:00
Lars Ingebrigtsen
7ada677e3f Add an autoload cookie to package-upload-file
* lisp/emacs-lisp/package-x.el (package-upload-file): Add an
autoload cookie (bug#26724).
2019-07-26 11:18:37 +02:00