summaryrefslogtreecommitdiff
path: root/doc/lispref/variables.texi
Commit message (Collapse)AuthorAgeFilesLines
...
* Allow ignoring local variable values permanentlyLars Ingebrigtsen2021-07-181-0/+10
| | | | | | | | | | * doc/lispref/variables.texi (File Local Variables): Document it. * lisp/files.el (ignored-local-variable-values): New user option (bug#5003). (hack-local-variables-confirm): Allow ignoring permanently. (hack-local-variables-filter): Ignore the permanently ignored variables.
* Add new convenience function `buffer-local-boundp'Lars Ingebrigtsen2021-05-311-0/+6
| | | | | | | * doc/lispref/variables.texi (Creating Buffer-Local): Document it. * lisp/subr.el (buffer-local-boundp): New function. * src/data.c (Flocal_variable_p): Mention it.
* Always heed the `lexical-binding' local variableLars Ingebrigtsen2021-05-101-0/+8
| | | | | | | | | | | | | * doc/lispref/variables.texi (File Local Variables): Document `permanently-enabled-local-variables'. * lisp/files.el (enable-local-variables): Mention the new variable. (set-auto-mode): Always call `hack-local-variables'. (hack-local-variables): Factor out the variable gathering into its own function, and respect the new variable (bug#47843). (hack-local-variables--find-variables): Factored out from `hack-local-variables'. (permanently-enabled-local-variables): New variable.
* * Add a note related to native compilation and Dynamic BindingAndrea Corallo2021-04-281-0/+3
| | | | | * doc/lispref/variables.texi (Dynamic Binding): Add a note related to native compilation.
* Remove several references to Emacs 22 and earlierStefan Kangas2021-03-101-2/+0
| | | | | | | | | | | | | | | | | | | | | | * admin/charsets/mapfiles/README: * doc/emacs/custom.texi (Saving Customizations): * doc/lispintro/emacs-lisp-intro.texi (Simple Extension): * doc/misc/efaq-w32.texi (Location of init file): * doc/misc/gnus-faq.texi (FAQ 1-3): * doc/misc/gnus.texi (Top, Various, Image Enhancements): * lisp/erc/erc-menu.el (menu): * lisp/progmodes/cfengine.el (cfengine-fill-paragraph): Remove some references to Emacs 22 and earlier. * doc/lispref/buffers.texi: * doc/lispref/eval.texi: * doc/lispref/files.texi: * doc/lispref/keymaps.texi: * doc/lispref/loading.texi: * doc/lispref/minibuf.texi: * doc/lispref/positions.texi: * doc/lispref/variables.texi: Remove comments about "Emacs 19 specific" features.
* Update copyright year to 2021Paul Eggert2021-01-011-1/+1
| | | | Run "TZ=UTC0 admin/update-copyright".
* Tiny fix for lispref/variables.texiGlenn Morris2020-12-141-1/+1
| | | | | | * doc/lispref/variables.texi (Converting to Lexical Binding): @strong{Note...} produces a spurious cross-reference in Info; reword to avoid that.
* Update docs of 'defvar' and 'defface'Eli Zaretskii2020-12-091-4/+6
| | | | | | | * doc/lispref/display.texi (Defining Faces): * doc/lispref/variables.texi (Defining Variables): Update the descriptions of 'defvar' and 'defface' per recent changes in 'eval-last-sexp'. (Bug#45125)
* Better file name in dynvars-check exampleMattias Engdegård2020-10-251-2/+2
| | | | | | * doc/lispref/variables.texi (Converting to Lexical Binding): Don't suggest an aggregate file name that matches the glob used when generating it.
* Tweak the documentation for define-obsolete-variable-aliasLars Ingebrigtsen2020-10-201-0/+8
| | | | | | | | * doc/lispref/variables.texi (Variable Aliases): Actually describe the macro parameters (bug#44088). * lisp/emacs-lisp/byte-run.el (define-obsolete-variable-alias): Ditto (bug#44088).
* Add aid for finding missing dynamic variable declarationsMattias Engdegård2020-10-171-0/+39
| | | | | | | | | | | | | | | | | | | | | | | | | Find lexical use of variables that are dynamically declared in other files by recording 'defvar' declarations in files that can be read in by the compiler in a second compilation. This is particularly useful when converting code to use lexical-binding. The facility is controlled by setting environment variables: EMACS_GENERATE_DYNVARS -- set to non-empty to generate a .dynvars file corresponding to each .elc. EMACS_DYNVARS_FILE -- set to the name of a .dynvars file to use as defvar information during compilation, enabling the new warnings. * lisp/emacs-lisp/bytecomp.el (byte-compile--known-dynamic-vars) (byte-compile--seen-defvars): New variables. (byte-compile-warning-types): Add lexical-dynamic warning. (byte-compile--load-dynvars, byte-compile--warn-lexical-dynamic): New functions. * lisp/emacs-lisp/bytecomp.el (byte-compile-file, byte-compile--declare-var) (byte-compile-lambda, byte-compile-bind): Add dynamic variable loads, dumps and checks. * doc/lispref/variables.texi (Converting to Lexical Binding): Document.
* * doc/lispref/variables.texi (Converting to Lexical Binding): New sectionStefan Monnier2020-10-161-6/+20
| | | | Extract it from `Using Lexical Binding` and extend it a bit.
* Preserve setf semantics in 'substring', 'cons', 'logand' expandersŠtěpán Němec2020-08-251-2/+5
| | | | | | | * doc/lispref/variables.texi (Adding Generalized Variables): Fix example. * lisp/emacs-lisp/cl-lib.el (substring) * lisp/emacs-lisp/gv.el (cons, logand): Return the value being assigned, as specified for 'setf'. (bug#35546)
* Document changes in lexical-bindingEli Zaretskii2020-03-071-2/+8
| | | | | | | | * doc/lispref/variables.texi (Using Lexical Binding): Document that lexical-binding is now turned on by default in more cases. * etc/NEWS: Fix wording of the NEWS entry about the above, and mark it as fully documented.
* ; bug#39779: Fix some typos in documentation.Štěpán Němec2020-02-281-1/+1
|
* * doc/lispref/variables.texi (special-variable-p): Clarify limitsStefan Monnier2020-02-131-0/+4
|
* Always use lexical-binding in lisp-interaction-mode (bug#38835)Mattias Engdegård2020-01-131-0/+3
| | | | | | | | | | * lisp/progmodes/elisp-mode.el (lisp-interaction-mode): Set lexical-binding. * lisp/startup.el (command-line, startup--get-buffer-create-scratch): Don't set lexical-binding here. * doc/lispref/variables.texi: * etc/NEWS: Make it clear that lisp-interaction-mode uses lexical-binding.
* Revert "Raise default max-specpdl-size value"Mattias Engdegård2020-01-011-1/+1
| | | | This reverts commit bb9402e6e9c12938aee31b81e25511eb1f6335d2.
* Raise default max-specpdl-size valueMattias Engdegård2020-01-011-1/+1
| | | | | | | | | Occasionally, loading cl-generic.el from source requires max_specpdl_size > 1600 when bootstrapping, and thus fails. In any case we are very close to the limit. * src/eval.c (init_eval_once): Raise max_specpdl_size to 1800. * doc/lispref/variables.texi (Local Variables): Update docs.
* Update copyright year to 2020Paul Eggert2020-01-011-1/+1
| | | | Run "TZ=UTC0 admin/update-copyright $(git ls-files)".
* Improve documentation of 'add-variable-watcher'Eli Zaretskii2019-11-151-13/+15
| | | | | | | | * doc/lispref/variables.texi (Watching Variables): Clarify the documentation of 'add-variable-watcher' and fix markup. * src/data.c (Fadd_variable_watcher): Clarify the doc string. (Bug#38205)
* Correct .dir-locals-2.el descriptionRobert Pluim2019-10-111-1/+1
| | | | | * doc/lispref/variables.texi (Directory Local Variables): Correct description of .dir-locals-2.el functioning. (Bug#37640)
* Ensure that setq-local take an even number of symbol/value pairsLars Ingebrigtsen2019-10-111-5/+11
| | | | | | | | | * doc/lispref/variables.texi (Creating Buffer-Local): Document the new syntax for setq-local. * lisp/subr.el (setq-local): Ensure that there's an even number of variable/value pairs, and expand the doc string by taking some text from `setq'.
* Add a letrec example to the manuelLars Ingebrigtsen2019-10-091-1/+11
| | | | * doc/lispref/variables.texi (Local Variables): Add a letrec example.
* Tweak letrec documentationLars Ingebrigtsen2019-10-091-1/+1
| | | | | * doc/lispref/variables.texi (Local Variables): Compare letrec to let* instead of let.
* Document `letrec'Lars Ingebrigtsen2019-10-091-0/+9
| | | | | | | * doc/lispref/variables.texi (Local Variables): Document letrec (bug#21048). * lisp/subr.el (letrec): Expand the doc string slightly.
* Bump up max_specpdl_size to 1600Juanma Barranquero2019-10-011-1/+1
| | | | | * src/eval.c (init_eval_once): Set max_specpdl_size to 1600. * doc/lispref/variables.texi (Local Variables): Document it.
* Add some examples in "Adding Generalized Variables"Lars Ingebrigtsen2019-08-151-6/+35
| | | | | * doc/lispref/variables.texi (Adding Generalized Variables): Add examples for `gv-define-expander' and `gv-letplace' (bug#13343).
* Bump up max_specpdl_size to 1500. (Bug#36216)Juanma Barranquero2019-06-161-1/+1
| | | | | * src/eval.c (init_eval_once): Set max_specpdl_size to 1500. * doc/lispref/variables.texi (Local Variables): Document it.
* Merge from origin/emacs-26Glenn Morris2019-06-011-0/+5
|\ | | | | | | | | | | | | | | | | 008b263 (origin/emacs-26, emacs-26) * lisp/gnus/gnus.el: Mark autoloa... daf32f1 Speed up redisplay of HELLO d8a6d82 Improve documentation of 'safe-local-variable' property # Conflicts: # etc/HELLO
| * Improve documentation of 'safe-local-variable' propertyEli Zaretskii2019-06-011-0/+5
| | | | | | | | | | | | * doc/lispref/variables.texi (File Local Variables): Document how to define 'safe-local-variable' properties for built-in variables.
* | Merge from origin/emacs-26Glenn Morris2019-05-221-1/+1
|\| | | | | | | | | | | | | | | | | | | b0da915 (origin/emacs-26, emacs-26) Fix a typo in ELisp manual 400907b Add option to disable help completion autoloading (Bug#28607) 122ba16 Don't segfault on force-window-update of deleted window 015b12e Fix typo in ELisp manual eadf044 Remove repeated function call in picture.el 1228a90 ; Fix mm-destroy-parts docstring typo 6cfd68d Fix Hideshow key binding typo in Emacs manual
| * Fix typo in ELisp manualMauro Aranda2019-05-201-1/+1
| | | | | | | | | | * doc/lispref/variables.texi (Directory Local Variables): Fix typo in dir-locals-set-class-variables description. (Bug#35799)
* | Do not hardcode "/bin/sh" in compile. Bug#24338, Bug#29723Michael Albinus2019-03-091-5/+12
|/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * doc/emacs/custom.texi (Connection Variables): New node. * doc/emacs/emacs.texi (Top): Add entry for Connection Variables. * doc/emacs/misc.texi (Single Shell): Mention default value for remote buffers. * doc/lispref/variables.texi (Connection Local Variables): Describe `with-connection-local-variables' instead of `with-connection-local-profiles'. * doc/misc/tramp.texi (Remote processes): Refer to Emacs manual. Mention default connection-local settings for `shell-file-name' and `shell-command-switch'. * etc/NEWS: Mention connection-local variables changes. * lisp/files-x.el (hack-connection-local-variables): Push connection-local variables to `file-local-variables-alist'. (connection-local-criteria-for-default-directory): New defsubst. (with-connection-local-variables): Rename from `with-connection-local-profiles'. Adapt implementation. * lisp/files.el (hack-local-variables): Call `hack-connection-local-variables'. * lisp/shell.el (shell): Use `with-connection-local-variables'. * lisp/subr.el (start-file-process-shell-command): * lisp/progmodes/compile.el (compilation-start): Use `with-connection-local-variables'. Do not set "/bin/sh" for remote buffers, trust settings of `shell-file-name'. (Bug#24338), (Bug#29723) * lisp/net/ange-ftp.el (ange-ftp-compress, ange-ftp-uncompress): Use `shell-command-switch'. * lisp/net/tramp-adb.el (tramp-adb-connection-local-default-profile): New defvar. Add it to connection-local profiles after loading "shell". * lisp/net/tramp-integration.el (tramp-compat): Require tramp-compat. (tramp-compat-exec-path): Do not declare anymore. (tramp-connection-local-safe-shell-file-names): New defvar. (tramp-connection-local-default-profile): New defconst. Activate it after loading "shell". (shell-file-name, shell-command-switch): Add safe-local-variable property. * lisp/net/tramp-sh.el (tramp-display-escape-sequence-regexp): Add tramp-autoload cookie. * test/lisp/files-x-tests.el (remote-shell-file-name): Add safe-local-variable property to remote-* variables. (tramp-connection-local-default-profile): Declare. (files-x-test-with-connection-local-variables): Rename from `files-x-test-with-connection-local-profiles'. Adapt implementation. * test/lisp/net/tramp-tests.el (tramp-test34-connection-local-variables): New test. (tramp-test34-explicit-shell-file-name): Run it also for tramp-adb. Bind connection-local-{profile,criteria}-alist. Use tramp-adb specific `shell-file-name'. Add safe-local-variable property to `explicit-shell-file-name' and `explicit-sh-args'.
* Update copyright year to 2019Paul Eggert2019-01-011-1/+1
| | | | Run 'TZ=UTC0 admin/update-copyright $(git ls-files)'.
* Improve indexing of 'eval-defun' in ELisp manualEli Zaretskii2018-07-071-0/+1
| | | | | | | | * doc/lispref/display.texi (Defining Faces): * doc/lispref/debugging.texi (Explicit Debug): * doc/lispref/customize.texi (Variable Definitions): * doc/lispref/variables.texi (Defining Variables): Add index entries for 'eval-defun'. (Bug#32066)
* Fix typos and minor wording issues in ELisp manualEli Zaretskii2018-04-131-7/+8
| | | | | | | | | | | | | | * doc/lispref/internals.texi (Writing Emacs Primitives): * doc/lispref/display.texi (Temporary Displays): Fix typos. * doc/lispref/text.texi (Filling, Changing Properties) (Transposition): Clarify and fix typos. * doc/lispref/positions.texi (Screen Lines): Improve wording. * doc/lispref/modes.texi (Minor Mode Conventions) (Font Lock Multiline): Fix typos. * doc/lispref/variables.texi (Dynamic Binding Tips): Fix a cross-reference. Fix a typo. * doc/lispref/sequences.texi (Sequence Functions): Fix typos. (Bug#31143)
* Explain more about (defvar foo) form (Bug#18059)Noam Postavsky2018-03-231-3/+36
| | | | | | | | | * doc/lispref/variables.texi (Defining Variables) (Using Lexical Binding): * doc/lispref/compile.texi (Compiler Errors): Emphasize that omitting VALUE for `defvar' marks the variable special only locally. * doc/lispref/variables.texi (Using Lexical Binding): Add example of using `defvar' without VALUE.
* Firm up documentation of generalized variablesAlan Mackenzie2018-03-211-16/+18
| | | | | | | | | * doc/lispref/variables.texi (Generalized Variables) (Setting Generalized Variables): Define a generalized variable as something setf can write to. Remove the insinuation that hackers have poor memories. State explicitly that the list of GVs given is complete. Remove the suggestion that `setf' has superseded, or is in the process of superseding, `setq'. Make minor corrections to the English.
* Minor improvements in manualsEli Zaretskii2018-03-071-2/+3
| | | | | | | | | | | | * doc/lispref/variables.texi (Local Variables): Make more clear that local bindings of 'let' are in effect only within the body. Suggested by Marcin Borkowski <mbork@mbork.pl>, see http://lists.gnu.org/archive/html/emacs-devel/2018-03/msg00217.html for the details. * doc/emacs/programs.texi (Matching): Fix a typo. Reported by Alex Branham <alex.branham@gmail.com> in emacs-manual-bugs@gnu.org. Improve indexing.
* Minor copyedit in ELisp manualEli Zaretskii2018-01-141-1/+2
| | | | | * doc/lispref/variables.texi (File Local Variables): Improve wording of last change.
* * doc/lispref/variables.texi (File Local Variables): Fix last changeStefan Monnier2018-01-131-3/+4
|
* Improve documentation of safe values of variablesEli Zaretskii2018-01-131-1/+14
| | | | | | | | | * doc/lispref/variables.texi (File Local Variables): Mention the autoload cookie as a means of defining safe values for variables. See http://lists.gnu.org/archive/html/emacs-devel/2018-01/msg00261.html for the details. * doc/lispref/compile.texi (Compiler Errors): Document 'byte-compile-error-on-warn'.
* Update copyright year to 2018Paul Eggert2018-01-011-1/+1
| | | | Run admin/update-copyright.
* ; lispref nil/t markup fixesGlenn Morris2017-12-221-3/+3
|
* Update documentation of '.dir-locals-2.el'Kaushal Modi2017-11-281-1/+6
| | | | | | | | | | | | See https://lists.gnu.org/r/emacs-devel/2017-11/msg00649.html for more details. * lisp/files.el (dir-locals-file-2): Remove unused constant. * lisp/files.el (dir-locals-file): Mention ".dir-locals-2.el" in the doc string. * doc/lispref/variables.texi (Directory Local Variables): Mention ".dir-locals-2.el". * etc/NEWS: Replace `dir-locals-file-2' mention with `dir-locals-file'.
* Improve documentation of "constant" symbolsEli Zaretskii2017-11-261-0/+13
| | | | | | | | | | | | | | | | * src/font.c (syms_of_font) <font-weight-table, font-slant-table> <font-width-table>: * src/data.c (syms_of_data) <most-positive-fixnum> <most-negative-fixnum>: * src/buffer.c (syms_of_buffer) <enable-multibyte-characters>: Mention in the doc strings that these variables are read-only. * doc/lispref/variables.texi (Creating Buffer-Local): Document that making a constant variable buffer-local signals an error. * doc/lispref/variables.texi (Constant Variables): * doc/lispref/errors.texi (Standard Errors): More accurate and up-to-date documentation of which symbols cannot be assigned values.
* Improve discoverability of 'defvar' for suppressing warningsEli Zaretskii2017-11-241-1/+3
| | | | | | | * doc/lispref/compile.texi (Compiler Errors): Add index entries. * doc/lispref/variables.texi (Defining Variables): Mention that defvar with no value is used for suppressing compiler warnings. (Bug#29400)
* ; Fix typo in lisprefMark Oteiza2017-08-201-1/+1
| | | | * doc/lispref/variables.texi (Using Lexical Binding): Append an s.
* ; Minor copyedits in manuals.Eli Zaretskii2017-08-181-3/+3
| | | | | | | * doc/lispref/variables.texi (Lexical Binding): The future is here. * doc/emacs/files.texi (Copying and Naming): Use @w{..} around constructs that could be split between lines, but shouldn't.