summaryrefslogtreecommitdiff
path: root/lisp/help-fns.el
Commit message (Collapse)AuthorAge
* Merge from origin/emacs-29Stefan Monnier2023-03-27
|\ | | | | | | | | | | | | | | | | | | | | | | | | 8f42db010d1 Improve indenting "case" in Python c4d490490dc ; * test/src/fns-tests.el: Fix last change 875e77a66a6 * test/infra/Dockerfile.emba (emacs-native-comp): Add zli... 64a2b0d36fe Fix failure of fns-tests-collate-strings on Cygwin 90fc6b987ad * lisp/savehist.el (savehist-save): Preserve shared struc... 08fbc133756 Adapt Tramp manual accb3871668 Fix system time sampling on MS-Windows 33d436eefa1 Fix treesit_ensure_parsed (bug#62333) d93a439846f * lisp/help-fns.el (find-lisp-object-file-name): Fix bug#... be8147c53f9 Improve "Bugs" in the Emacs manual
| * * lisp/help-fns.el (find-lisp-object-file-name): Fix bug#62376 part2Stefan Monnier2023-03-23
| | | | | | | | Nowadays `loaddefs.el` are byte-compiled, so adjust pattern accordingly
* | (describe-function): Load file for `...' referencesStefan Monnier2023-03-21
| | | | | | | | | | | | | | To fix bug#62300, we do the same for `...' as we already did for \[...] * help-fns.el (describe-function-1): Look for `...' references in addition to key substitution markup.
* | Remove stray quotesMattias Engdegård2023-02-21
| | | | | | | | | | | | | | * lisp/emacs-lisp/bytecomp.el (byte-compile-form): * lisp/help-fns.el (help-fns--interactive-only): Fix obvious mistake. Since `interactive-only` is not supposed to be anything other than a symbol at these points it was not a very consequential bug.
* | Follow aliases for `interactive-only` declarationsMattias Engdegård2023-02-21
| | | | | | | | | | | | | | | | | | | | Make `interactive-only` declarations apply to aliases of the same function as well since this quality isn't in the name but in what the function does. * lisp/emacs-lisp/bytecomp.el (byte-compile-form): * lisp/help-fns.el (help-fns--interactive-only): Follow aliases when retrieving the `interactive-only` property.
* | Detect and prevent function alias loops in `fset` and `defalias`Mattias Engdegård2023-02-21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Make `fset` and `defalias` signal an error on attempts to create circular alias chains. This is more effective, efficient and convenient than permitting alias loops to be created and trying to detect them at run time each time a function is called, which is what we have been doing until now, badly. * lisp/help-fns.el (help-fns--analyze-function): Don't pass obsolete argument. * lisp/subr.el (function-alias-p): * src/data.c (indirect_function, Findirect_function): Simplify. Now error-free, second argument obsolete. (Ffset): Detect loops. * test/lisp/help-fns-tests.el (help-fns--analyze-function-recursive): * test/lisp/subr-tests.el (test-alias-p): Adapt tests. * test/src/data-tests.el (data-tests-fset, data-tests-defalias): New. * doc/lispref/eval.texi (Function Indirection): * doc/lispref/functions.texi (Defining Functions, Function Cells): Update manual. * etc/NEWS: Announce.
* | Merge from origin/emacs-29Eli Zaretskii2023-01-01
|\| | | | | | | | | | | | | | | | | | | | | cae528457c ; Add 2023 to copyright years. b394359261 Improve documentation of 'isearch-open-overlay-temporary' ab3210e709 Document 'use-package' in the 2 main manuals # Conflicts: # etc/refcards/ru-refcard.tex # lib/explicit_bzero.c # m4/explicit_bzero.m4
| * ; Add 2023 to copyright years.Eli Zaretskii2023-01-01
| |
* | ; fix misplaced bracketing of `and` inside `when`Mattias Engdegård2022-12-30
|/
* cl-generic: Fix `advertised-calling-convention` declarationsStefan Monnier2022-10-16
| | | | | | | | | | | | | | | * lisp/emacs-lisp/cl-generic.el (cl-generic-define-method): Preserve the `advertised-calling-convention`, if any (bug#58563). * lisp/subr.el (declare): Warn when we hit this. * lisp/emacs-lisp/byte-run.el (get-advertised-calling-convention): New fun. * lisp/progmodes/elisp-mode.el (elisp-get-fnsym-args-string): * lisp/help-fns.el (help-fns--signature): * lisp/emacs-lisp/bytecomp.el (byte-compile-fdefinition): Use it. * test/lisp/emacs-lisp/cl-generic-tests.el (cl-generic-tests--acc): New fun. (cl-generic-tests--advertised-calling-convention-bug58563): New test.
* Fix typo in last help-fns--insert-menu-bindings changeLars Ingebrigtsen2022-10-03
| | | | | * lisp/help-fns.el (help-fns--insert-menu-bindings): Fix typo in last change.
* Improve help-fns--insert-menu-bindings formattingLars Ingebrigtsen2022-10-03
| | | | | | * lisp/help-fns.el (help-fns--insert-menu-bindings): Make this work better for menus that turn out to not be reachable after all -- i.e., don't insert " and " before the heading in certain cases.
* Fix *Help* output for native-comp functions from IELMLars Ingebrigtsen2022-09-16
| | | | | | | * lisp/help-fns.el (find-lisp-object-file-name): Don't claim that native-comp functions that are defined outside of files (for instance, created by calling `native-compile' in IELM) are in C source (bug#57819).
* Make help-fns--generalized-variable more resilientLars Ingebrigtsen2022-09-14
| | | | | * lisp/help-fns.el (help-fns--generalized-variable): Don't bug out when a key binding isn't a symbol.
* New function substitute-quotesStefan Kangas2022-09-10
| | | | | | | | | | | | | | | | | | | * lisp/help.el (substitute-quotes): New function. (Bug#51040) * doc/lispref/help.texi (Keys in Documentation): Document substitute-quotes. * test/lisp/help-tests.el (help-tests-substitute-quotes): New test. * lisp/cedet/srecode/srt-mode.el (srecode-macro-help): * lisp/cus-theme.el (describe-theme-1): * lisp/emacs-lisp/cl-extra.el (cl--describe-class): * lisp/emacs-lisp/eieio-opt.el (eieio-help-constructor): * lisp/emacs-lisp/package.el (describe-package-1): * lisp/help-fns.el (help-fns--parent-mode, help-fns--var-risky) (help-fns--var-file-local, help-fns--var-bufferlocal) (describe-face): * lisp/help.el (substitute-command-keys): * lisp/progmodes/octave.el (octave-help): Use the new function instead of 'substitute-command-keys'.
* ; * lisp/help-fns.el (help-fns--key-bindings): Fix previous change.Gregory Heytings2022-09-06
|
* Simplify describe-function.Gregory Heytings2022-09-05
| | | | | | | * lisp/help-fns.el (describe-function-1): Do not pass 'describe-function-orig-buffer' as argument to... (help-fns--key-bindings): but use it directly there instead. This simplifies 1d1158397b.
* Fix some help-fns test failuresLars Ingebrigtsen2022-09-04
| | | | | * lisp/help-fns.el (help-fns--key-bindings): Fix test failures from recent change.
* Look up keybindings in correct buffer in describe-function.Gregory Heytings2022-09-04
| | | | | | | | * lisp/help-fns.el (help-fns--key-bindings): New parameter. Use it when looking up keybindings. (describe-function-1): Add the buffer in which the command was invoked as argument to 'help-fns--key-bindings'. Fixes bug#57568.
* * lisp/help-fns.el (find-lisp-object-file-name): Revert last changeStefan Monnier2022-09-03
|
* * lisp/help-fns.el: Minor fixesStefan Monnier2022-09-02
| | | | | | | | (describe-mode--minor-modes): Don't burp on minor modes that lack a docstring. (describe-mode--minor-modes): Simplify eta-redex. (find-lisp-object-file-name): Use `autoload-file`. (help-fns--describe-function-or-command-prompt): Allow the user to insist on choosing a function even if it appears not to exist.
* Don't mention obsolete generalized variables in *Help*Lars Ingebrigtsen2022-08-23
| | | | | * lisp/help-fns.el (help-fns--generalized-variable): Don't mention obsolete ones.
* Make *Help* display info about generalized variablesLars Ingebrigtsen2022-08-22
| | | | | * lisp/help-fns.el (help-fns--generalized-variable): New function to document generalized variables.
* (compiled-function-p): New function (bug#56648)Stefan Monnier2022-08-14
| | | | | | | | | | | | | | | | | | | | | | | | * lisp/subr.el (compiled-function-p): New function. * test/lisp/international/ucs-normalize-tests.el (ucs-normalize-part1): * lisp/gnus/gnus.el (gnus): * lisp/mh-e/mh-e.el (mh-version): * lisp/emacs-lisp/macroexp.el (emacs-startup-hook): * lisp/emacs-lisp/cl-macs.el (compiled-function): * lisp/emacs-lisp/bytecomp.el (byte-compile-fdefinition) (byte-compile, display-call-tree): * lisp/emacs-lisp/byte-opt.el (<toplevel-end>): * lisp/emacs-lisp/advice.el (ad-compiled-p): * lisp/cedet/semantic/bovine.el (semantic-bovinate-stream): * lisp/loadup.el (macroexpand-all): * admin/unidata/unidata-gen.el (unidata--ensure-compiled): Use it. * lisp/emacs-lisp/pcase.el (pcase-mutually-exclusive-predicates): Add entries for it. (pcase--split-pred): Use it. * lisp/help-fns.el (help-fns-function-description-header): Use `functionp`. (help-fns--var-safe-local): Use `compiled-function-p`.
* ; Fix typosStefan Kangas2022-08-08
|
* Merge from origin/emacs-28Stefan Kangas2022-07-24
|\ | | | | | | | | | | | | | | | | | | b4067394dc Set `default-directory' of Tramp archive connection buffer 2529e82002 ; * doc/lispref/functions.texi (Declare Form): Fix typo. 54c4ceb009 Update the documentation of 'declare' forms 7263631dca Fix bookmark support for Help functions in native-compilat... # Conflicts: # lisp/help.el
| * Fix bookmark support for Help functions in native-compilation buildsEli Zaretskii2022-07-23
| | | | | | | | | | | | | | | | | | | | * lisp/help.el (describe-key--helper, describe-function--helper): New helper functions. (describe-key): Call 'describe-key--helper' instead of a lambda-function. * lisp/help-fns.el (describe-function): Call 'describe-function--helper' instead of a lambda-function. (Bug#56643)
* | Merge from origin/emacs-28Stefan Kangas2022-07-23
|\| | | | | | | | | | | | | | | | | | | | | ae1ace1cf4 Adjust help-fns.el tests for recent change 04bdcf4aaa * src/terminal.c (Fframe_terminal): Use active voice 7fa491a9e9 Improve 'terminal-live-p' docstring some more b9ac8c29ae Improve terminal-live-p docstring 0b4c81a152 * lisp/net/tramp-gvfs.el (tramp-gvfs-dbus-event-vector): F... 8f8373170f * lisp/progmodes/cperl-mode.el: Don't mention obsolete arc... 25bc330a6d Make 'describe-function' say "byte-compiled" when appropriate 2b31e667be ;Improve documentation of locale-specific string comparison
| * Make 'describe-function' say "byte-compiled" when appropriateEli Zaretskii2022-07-21
| | | | | | | | | | * lisp/help-fns.el (help-fns-function-description-header): Say "byte-compiled" when describing byte-compiled functions.
* | Don't list obsolete in "other commands" help sectionStefan Kangas2022-07-21
| | | | | | | | | | * lisp/help-fns.el (help-fns--list-local-commands): Don't list obsolete commands.
* | (help-fns--first-release): Try and avoid false positivesStefan Monnier2022-07-18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We used to use a very "optimistic" regexp which worked well for longish symbol names but suffered from too many false positives on short names. Use a more restrictive regexp, which should make the recent "weed out" change unnecessary. This in turn requires the use of '...' more consistently in etc/NEWS* files. * lisp/help-fns.el (help-fns--first-release-regexp): New function. (help-fns--first-release): Use it. Fix minor issue with the Emacs version regexp. (help-fns--mention-first-release): Undo last change. * etc/NEWS*: Replace `...' with '...'. Indent code examples by at least 2 spaces. Add previously missing '...' quotes around many of the variables and functions described.
* | Fix xref links in `C-h o'Lars Ingebrigtsen2022-07-16
| | | | | | | | | | | | | | | | | | | | | | * lisp/help-fns.el (describe-symbol): Make xref links happen in all sections (bug#49587). * lisp/help-fns.el (describe-symbol): Add back/forward links. * lisp/help-mode.el (help-make-xrefs): Factor out links from here... (help-xref--navigation-buttons): To here.
* | Weed out some false positives in help-fns--mention-first-releaseLars Ingebrigtsen2022-07-16
| | | | | | | | | | * lisp/help-fns.el (help-fns--mention-first-release): Weed out things that give too many false positives (bug#49062).
* | Remove some ineffectual calls to purecopyStefan Kangas2022-07-10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * lisp/dired.el (dired-chown-program, dired-trivial-filenames): * lisp/emacs-lisp/shortdoc.el (shortdoc--display-function): * lisp/help-fns.el (help-fns--mention-shortdoc-groups): * lisp/mail/mail-extr.el (mail-extr-full-name-prefixes) (mail-extr-all-letters-but-separators, mail-extr-all-letters) (mail-extr-first-letters, mail-extr-last-letters) (mail-extr-bad-dot-pattern, mail-extr-full-name-suffix-pattern) (mail-extr-alternative-address-pattern) (mail-extr-trailing-comment-start-pattern) (mail-extr-name-pattern, mail-extr-telephone-extension-pattern) (mail-extr-ham-call-sign-pattern, mail-extr-normal-name-pattern) (mail-extr-two-name-pattern) (mail-extr-listserv-list-name-pattern) (mail-extr-stupid-vms-date-stamp-pattern) (mail-extr-hz-embedded-gb-encoded-chinese-pattern) (mail-extr-x400-encoded-address-pattern) (mail-extr-x400-encoded-address-field-pattern-format) (mail-extr-x400-encoded-address-surname-pattern) (mail-extr-x400-encoded-address-given-name-pattern) (mail-extr-x400-encoded-address-full-name-pattern): Remove ineffectual calls to purecopy.
* | ; Fix doc strings in help-fns.elEli Zaretskii2022-07-04
| | | | | | | | | | * lisp/help-fns.el (help-fns-edit-mode-done) (help-fns-edit-mode-cancel): Doc fixes.
* | New command help-fns-edit-mode-cancelStefan Kangas2022-07-04
| | | | | | | | | | | | * lisp/help-fns.el (help-fns-edit-mode-cancel): New command. (help-fns--edit-value-mode-map): Bind it to 'C-c C-k'. (help-fns-edit-variable): Advertise it in help text.
* | Put the obsoletion earlier in the *Help* bufferLars Ingebrigtsen2022-06-28
| | | | | | | | | | | | | | | | * lisp/help-fns.el (help-fns--obsolete): Remove indentation and fill. (help-fns--var-obsolete): Ditto. (describe-function-1): Output the obsoletion info first since it's vital information. (describe-variable): Ditto (bug#56251).
* | Font-lock variable values in *Help*Lars Ingebrigtsen2022-06-26
| | | | | | | | | | * lisp/help-fns.el (describe-variable): Font-lock the variable value (bug#47363).
* | Tweak quoting in help-fns--compiler-macroLars Ingebrigtsen2022-06-20
| | | | | | | | | | * lisp/help-fns.el (help-fns--compiler-macro): Fix quotes in help text.
* | Fix some declare-after-interactive functionsLars Ingebrigtsen2022-06-17
| | | | | | | | | | | | | | | | | | | | * lisp/progmodes/opascal.el (opascal-new-comment-line): * lisp/image-mode.el (image-transform-fit-to-height): * lisp/help-fns.el (help-fns-edit-variable): * lisp/gnus/gnus-salt.el (gnus-pick-start-reading): * lisp/eshell/esh-util.el (eshell-for): * lisp/ldefs-boot.el (view-return-to-alist-update): Fix warnings about declare after interactive.
* | Improve help-enable-variable-value-editing helpStefan Kangas2022-06-17
| | | | | | | | | | | | * lisp/help-fns.el (help-enable-variable-value-editing): Expand docstring to better explain what effect it has. (help-fns-edit-variable): Use command substitution.
* | Allow editing all symbols in help-fns--editable-variableLars Ingebrigtsen2022-06-17
| | | | | | | | | | * lisp/help-fns.el (help-fns--editable-variable): Allow editing all symbols (bug#56038).
* | Re-re-fix previous describe-function changeLars Ingebrigtsen2022-06-05
| | | | | | | | | | * lisp/help-fns.el (describe-function): Put back binding removed by mistake in previous change.
* | Fix key binding buffer issue in describe-function betterLars Ingebrigtsen2022-06-05
| | | | | | | | | | | | | | * lisp/help-fns.el (describe-function): Revert previous change here. (describe-function-1): Just use describe-function-orig-buffer instead of the key-buffer binding -- this will also make the rendering results correct when hitting `g' and `l'.
* | Make `C-h f' look up key bindings in the current buffer againLars Ingebrigtsen2022-06-05
| | | | | | | | | | | | * lisp/help-fns.el (describe-function): Pass in the correct buffer to look up key bindings in. (describe-function-1): Use it.
* | Handle invalid NEWS files during describe-functionPo Lu2022-05-24
| | | | | | | | | | * src/help-fns.el (help-fns--first-release): Don't error if searching for a heading fails.
* | Audit symbol quoting in Lisp doc stringsLars Ingebrigtsen2022-05-24
| | | | | | | | | | | | | | | | | | | | | | | | * lisp/vc/vc-svn.el (vc-svn-dir-status-files): * lisp/so-long.el (so-long-mode-maintain-preserved-variables): * lisp/help-fns.el (help-fns--most-relevant-active-keymap): * lisp/gnus/nnselect.el (nnselect-get-artlist): (nnselect-store-artlist): * lisp/forms.el (forms-enumerate): * lisp/ffap.el (ffap-string-at-point): * lisp/emacs-lisp/byte-run.el (define-obsolete-variable-alias): Audit symbol quoting in Lisp doc strings.
* | describe-keymap: Suggest symbol at pointVisuwesh2022-05-15
| | | | | | | | | | | | * lisp/help-fns.el (describe-keymap): Suggest symbol at point if it is a keymap. (Bug#55393) * etc/NEWS: Announce change in behavior of 'describe-keymap'.
* | Put help-fns--compiler-macro last in the *Help* bufferLars Ingebrigtsen2022-05-14
| | | | | | | | | | | | * lisp/help-fns.el (help-fns-describe-function-functions): Make help-fns--compiler-macro the last entry (because it's not the most interesting information).
* | Improve the *Help* output for compiler macros and the likeLars Ingebrigtsen2022-05-14
| | | | | | | | | | | | | | * doc/lispref/functions.texi (Advice and Byte Code): New node. * lisp/help-fns.el (help-fns--compiler-macro): Also output data on other byte compilation things, and link to the manual (bug#23264).