diff options
| author | Stefan Kangas | 2021-01-31 18:45:47 +0100 |
|---|---|---|
| committer | Stefan Kangas | 2021-01-31 20:08:25 +0100 |
| commit | 458faaf4c39936a5e7d187684cbf0fe0b161bb0a (patch) | |
| tree | 9ee0806b2c0393cf2cb297ec6d7f494fd836150b | |
| parent | 834ba2b6197369bb4cd8faa40c1f131594d30c75 (diff) | |
| download | emacs-458faaf4c39936a5e7d187684cbf0fe0b161bb0a.tar.gz emacs-458faaf4c39936a5e7d187684cbf0fe0b161bb0a.zip | |
Prefer defvar-local in textmodes/*.el
This skips libraries that might want compatibility with Emacs 24.2.
* lisp/textmodes/artist.el (artist-curr-go)
(artist-line-char-set, artist-line-char, artist-fill-char-set)
(artist-fill-char, artist-erase-char, artist-default-fill-char)
(artist-draw-region-min-y, artist-draw-region-max-y)
(artist-borderless-shapes):
* lisp/textmodes/css-mode.el (css--at-ids, css--bang-ids)
(css--nested-selectors-allowed):
* lisp/textmodes/enriched.el (enriched-old-bindings):
* lisp/textmodes/flyspell.el (flyspell-generic-check-word-predicate)
(flyspell-consider-dash-as-word-delimiter-flag)
(flyspell-dash-dictionary, flyspell-dash-local-dictionary)
(flyspell-word-cache-start, flyspell-word-cache-end)
(flyspell-word-cache-word, flyspell-word-cache-result)
(flyspell-changes, flyspell-auto-correct-pos)
(flyspell-auto-correct-region, flyspell-auto-correct-ring)
(flyspell-auto-correct-word):
* lisp/textmodes/ispell.el (ispell-local-dictionary-overridden)
(ispell-local-pdict, ispell-buffer-session-localwords):
* lisp/textmodes/refill.el (refill-ignorable-overlay)
(refill-doit):
* lisp/textmodes/sgml-mode.el (html--buffer-classes-cache)
(html--buffer-ids-cache):
* lisp/textmodes/table.el (table-mode-indicator):
* lisp/textmodes/tex-mode.el (tex-send-command-modified-tick):
* lisp/textmodes/two-column.el (2C-autoscroll-start, 2C-mode):
Prefer defvar-local.
| -rw-r--r-- | lisp/textmodes/artist.el | 30 | ||||
| -rw-r--r-- | lisp/textmodes/css-mode.el | 9 | ||||
| -rw-r--r-- | lisp/textmodes/enriched.el | 3 | ||||
| -rw-r--r-- | lisp/textmodes/flyspell.el | 39 | ||||
| -rw-r--r-- | lisp/textmodes/ispell.el | 10 | ||||
| -rw-r--r-- | lisp/textmodes/refill.el | 6 | ||||
| -rw-r--r-- | lisp/textmodes/sgml-mode.el | 6 | ||||
| -rw-r--r-- | lisp/textmodes/table.el | 3 | ||||
| -rw-r--r-- | lisp/textmodes/tex-mode.el | 3 | ||||
| -rw-r--r-- | lisp/textmodes/two-column.el | 6 |
10 files changed, 38 insertions, 77 deletions
diff --git a/lisp/textmodes/artist.el b/lisp/textmodes/artist.el index 13b7118d2f2..e66adb43e75 100644 --- a/lisp/textmodes/artist.el +++ b/lisp/textmodes/artist.el | |||
| @@ -411,50 +411,40 @@ be in `artist-spray-chars', or spraying will behave strangely.") | |||
| 411 | (defvar artist-mode-name " Artist" | 411 | (defvar artist-mode-name " Artist" |
| 412 | "Name of Artist mode beginning with a space (appears in the mode-line).") | 412 | "Name of Artist mode beginning with a space (appears in the mode-line).") |
| 413 | 413 | ||
| 414 | (defvar artist-curr-go 'pen-line | 414 | (defvar-local artist-curr-go 'pen-line |
| 415 | "Current selected graphics operation.") | 415 | "Current selected graphics operation.") |
| 416 | (make-variable-buffer-local 'artist-curr-go) | ||
| 417 | 416 | ||
| 418 | (defvar artist-line-char-set nil | 417 | (defvar-local artist-line-char-set nil |
| 419 | "Boolean to tell whether user has set some char to use when drawing lines.") | 418 | "Boolean to tell whether user has set some char to use when drawing lines.") |
| 420 | (make-variable-buffer-local 'artist-line-char-set) | ||
| 421 | 419 | ||
| 422 | (defvar artist-line-char nil | 420 | (defvar-local artist-line-char nil |
| 423 | "Char to use when drawing lines.") | 421 | "Char to use when drawing lines.") |
| 424 | (make-variable-buffer-local 'artist-line-char) | ||
| 425 | 422 | ||
| 426 | (defvar artist-fill-char-set nil | 423 | (defvar-local artist-fill-char-set nil |
| 427 | "Boolean to tell whether user has set some char to use when filling.") | 424 | "Boolean to tell whether user has set some char to use when filling.") |
| 428 | (make-variable-buffer-local 'artist-fill-char-set) | ||
| 429 | 425 | ||
| 430 | (defvar artist-fill-char nil | 426 | (defvar-local artist-fill-char nil |
| 431 | "Char to use when filling.") | 427 | "Char to use when filling.") |
| 432 | (make-variable-buffer-local 'artist-fill-char) | ||
| 433 | 428 | ||
| 434 | (defvar artist-erase-char ?\s | 429 | (defvar-local artist-erase-char ?\s |
| 435 | "Char to use when erasing.") | 430 | "Char to use when erasing.") |
| 436 | (make-variable-buffer-local 'artist-erase-char) | ||
| 437 | 431 | ||
| 438 | (defvar artist-default-fill-char ?. | 432 | (defvar-local artist-default-fill-char ?. |
| 439 | "Char to use when a fill-char is required but none is set.") | 433 | "Char to use when a fill-char is required but none is set.") |
| 440 | (make-variable-buffer-local 'artist-default-fill-char) | ||
| 441 | 434 | ||
| 442 | ; This variable is not buffer local | 435 | ; This variable is not buffer local |
| 443 | (defvar artist-copy-buffer nil | 436 | (defvar artist-copy-buffer nil |
| 444 | "Copy buffer.") | 437 | "Copy buffer.") |
| 445 | 438 | ||
| 446 | (defvar artist-draw-region-min-y 0 | 439 | (defvar-local artist-draw-region-min-y 0 |
| 447 | "Line-number for top-most visited line for draw operation.") | 440 | "Line-number for top-most visited line for draw operation.") |
| 448 | (make-variable-buffer-local 'artist-draw-region-min-y) | ||
| 449 | 441 | ||
| 450 | (defvar artist-draw-region-max-y 0 | 442 | (defvar-local artist-draw-region-max-y 0 |
| 451 | "Line-number for bottom-most visited line for draw operation.") | 443 | "Line-number for bottom-most visited line for draw operation.") |
| 452 | (make-variable-buffer-local 'artist-draw-region-max-y) | ||
| 453 | 444 | ||
| 454 | (defvar artist-borderless-shapes nil | 445 | (defvar-local artist-borderless-shapes nil |
| 455 | "When non-nil, draw shapes without border. | 446 | "When non-nil, draw shapes without border. |
| 456 | The fill char is used instead, if it is set.") | 447 | The fill char is used instead, if it is set.") |
| 457 | (make-variable-buffer-local 'artist-borderless-shapes) | ||
| 458 | 448 | ||
| 459 | (defvar artist-prev-next-op-alist nil | 449 | (defvar artist-prev-next-op-alist nil |
| 460 | "Assoc list for looking up next and/or previous draw operation. | 450 | "Assoc list for looking up next and/or previous draw operation. |
diff --git a/lisp/textmodes/css-mode.el b/lisp/textmodes/css-mode.el index 9186e520086..622853da456 100644 --- a/lisp/textmodes/css-mode.el +++ b/lisp/textmodes/css-mode.el | |||
| @@ -71,9 +71,8 @@ | |||
| 71 | "while") | 71 | "while") |
| 72 | "Additional identifiers that appear in the form @foo in SCSS.") | 72 | "Additional identifiers that appear in the form @foo in SCSS.") |
| 73 | 73 | ||
| 74 | (defvar css--at-ids css-at-ids | 74 | (defvar-local css--at-ids css-at-ids |
| 75 | "List of at-rules for the current mode.") | 75 | "List of at-rules for the current mode.") |
| 76 | (make-variable-buffer-local 'css--at-ids) | ||
| 77 | 76 | ||
| 78 | (defconst css-bang-ids | 77 | (defconst css-bang-ids |
| 79 | '("important") | 78 | '("important") |
| @@ -83,9 +82,8 @@ | |||
| 83 | '("default" "global" "optional") | 82 | '("default" "global" "optional") |
| 84 | "Additional identifiers that appear in the form !foo in SCSS.") | 83 | "Additional identifiers that appear in the form !foo in SCSS.") |
| 85 | 84 | ||
| 86 | (defvar css--bang-ids css-bang-ids | 85 | (defvar-local css--bang-ids css-bang-ids |
| 87 | "List of bang-rules for the current mode.") | 86 | "List of bang-rules for the current mode.") |
| 88 | (make-variable-buffer-local 'css--bang-ids) | ||
| 89 | 87 | ||
| 90 | (defconst css-descriptor-ids | 88 | (defconst css-descriptor-ids |
| 91 | '("ascent" "baseline" "bbox" "cap-height" "centerline" "definition-src" | 89 | '("ascent" "baseline" "bbox" "cap-height" "centerline" "definition-src" |
| @@ -1374,9 +1372,8 @@ the string PROPERTY." | |||
| 1374 | "List of HTML tags. | 1372 | "List of HTML tags. |
| 1375 | Used to provide completion of HTML tags in selectors.") | 1373 | Used to provide completion of HTML tags in selectors.") |
| 1376 | 1374 | ||
| 1377 | (defvar css--nested-selectors-allowed nil | 1375 | (defvar-local css--nested-selectors-allowed nil |
| 1378 | "Non-nil if nested selectors are allowed in the current mode.") | 1376 | "Non-nil if nested selectors are allowed in the current mode.") |
| 1379 | (make-variable-buffer-local 'css--nested-selectors-allowed) | ||
| 1380 | 1377 | ||
| 1381 | (defvar css-class-list-function #'ignore | 1378 | (defvar css-class-list-function #'ignore |
| 1382 | "Called to provide completions of class names. | 1379 | "Called to provide completions of class names. |
diff --git a/lisp/textmodes/enriched.el b/lisp/textmodes/enriched.el index 1aac96413e4..bac209cdef6 100644 --- a/lisp/textmodes/enriched.el +++ b/lisp/textmodes/enriched.el | |||
| @@ -165,10 +165,9 @@ execute malicious Lisp code, if that code came from an external source." | |||
| 165 | :version "26.1" | 165 | :version "26.1" |
| 166 | :group 'enriched) | 166 | :group 'enriched) |
| 167 | 167 | ||
| 168 | (defvar enriched-old-bindings nil | 168 | (defvar-local enriched-old-bindings nil |
| 169 | "Store old variable values that we change when entering mode. | 169 | "Store old variable values that we change when entering mode. |
| 170 | The value is a list of \(VAR VALUE VAR VALUE...).") | 170 | The value is a list of \(VAR VALUE VAR VALUE...).") |
| 171 | (make-variable-buffer-local 'enriched-old-bindings) | ||
| 172 | 171 | ||
| 173 | ;; The next variable is buffer local if and only if Enriched mode is | 172 | ;; The next variable is buffer local if and only if Enriched mode is |
| 174 | ;; enabled. The buffer local value records whether | 173 | ;; enabled. The buffer local value records whether |
diff --git a/lisp/textmodes/flyspell.el b/lisp/textmodes/flyspell.el index d8503168846..83dba7177ab 100644 --- a/lisp/textmodes/flyspell.el +++ b/lisp/textmodes/flyspell.el | |||
| @@ -304,12 +304,11 @@ If this variable is nil, all regions are treated as small." | |||
| 304 | (define-obsolete-variable-alias 'flyspell-generic-check-word-p | 304 | (define-obsolete-variable-alias 'flyspell-generic-check-word-p |
| 305 | 'flyspell-generic-check-word-predicate "25.1") | 305 | 'flyspell-generic-check-word-predicate "25.1") |
| 306 | 306 | ||
| 307 | (defvar flyspell-generic-check-word-predicate nil | 307 | (defvar-local flyspell-generic-check-word-predicate nil |
| 308 | "Function providing per-mode customization over which words are flyspelled. | 308 | "Function providing per-mode customization over which words are flyspelled. |
| 309 | Returns t to continue checking, nil otherwise. | 309 | Returns t to continue checking, nil otherwise. |
| 310 | Flyspell mode sets this variable to whatever is the `flyspell-mode-predicate' | 310 | Flyspell mode sets this variable to whatever is the `flyspell-mode-predicate' |
| 311 | property of the major mode name.") | 311 | property of the major mode name.") |
| 312 | (make-variable-buffer-local 'flyspell-generic-check-word-predicate) | ||
| 313 | 312 | ||
| 314 | ;;*--- mail mode -------------------------------------------------------*/ | 313 | ;;*--- mail mode -------------------------------------------------------*/ |
| 315 | (put 'mail-mode 'flyspell-mode-predicate 'mail-mode-flyspell-verify) | 314 | (put 'mail-mode 'flyspell-mode-predicate 'mail-mode-flyspell-verify) |
| @@ -466,13 +465,10 @@ If this is set, also unbind `mouse-2'." | |||
| 466 | :version "28.1") | 465 | :version "28.1") |
| 467 | 466 | ||
| 468 | ;; dash character machinery | 467 | ;; dash character machinery |
| 469 | (defvar flyspell-consider-dash-as-word-delimiter-flag nil | 468 | (defvar-local flyspell-consider-dash-as-word-delimiter-flag nil |
| 470 | "Non-nil means that the `-' char is considered as a word delimiter.") | 469 | "Non-nil means that the `-' char is considered as a word delimiter.") |
| 471 | (make-variable-buffer-local 'flyspell-consider-dash-as-word-delimiter-flag) | 470 | (defvar-local flyspell-dash-dictionary nil) |
| 472 | (defvar flyspell-dash-dictionary nil) | 471 | (defvar-local flyspell-dash-local-dictionary nil) |
| 473 | (make-variable-buffer-local 'flyspell-dash-dictionary) | ||
| 474 | (defvar flyspell-dash-local-dictionary nil) | ||
| 475 | (make-variable-buffer-local 'flyspell-dash-local-dictionary) | ||
| 476 | 472 | ||
| 477 | ;;*---------------------------------------------------------------------*/ | 473 | ;;*---------------------------------------------------------------------*/ |
| 478 | ;;* Highlighting */ | 474 | ;;* Highlighting */ |
| @@ -714,14 +710,10 @@ has been used, the current word is not checked." | |||
| 714 | ;;*---------------------------------------------------------------------*/ | 710 | ;;*---------------------------------------------------------------------*/ |
| 715 | ;;* flyspell-word-cache ... */ | 711 | ;;* flyspell-word-cache ... */ |
| 716 | ;;*---------------------------------------------------------------------*/ | 712 | ;;*---------------------------------------------------------------------*/ |
| 717 | (defvar flyspell-word-cache-start nil) | 713 | (defvar-local flyspell-word-cache-start nil) |
| 718 | (defvar flyspell-word-cache-end nil) | 714 | (defvar-local flyspell-word-cache-end nil) |
| 719 | (defvar flyspell-word-cache-word nil) | 715 | (defvar-local flyspell-word-cache-word nil) |
| 720 | (defvar flyspell-word-cache-result '_) | 716 | (defvar-local flyspell-word-cache-result '_) |
| 721 | (make-variable-buffer-local 'flyspell-word-cache-start) | ||
| 722 | (make-variable-buffer-local 'flyspell-word-cache-end) | ||
| 723 | (make-variable-buffer-local 'flyspell-word-cache-word) | ||
| 724 | (make-variable-buffer-local 'flyspell-word-cache-result) | ||
| 725 | 717 | ||
| 726 | ;;*---------------------------------------------------------------------*/ | 718 | ;;*---------------------------------------------------------------------*/ |
| 727 | ;;* The flyspell pre-hook, store the current position. In the */ | 719 | ;;* The flyspell pre-hook, store the current position. In the */ |
| @@ -827,8 +819,7 @@ before the current command." | |||
| 827 | ;;* the post command hook, we will check, if the word at this */ | 819 | ;;* the post command hook, we will check, if the word at this */ |
| 828 | ;;* position has to be spell checked. */ | 820 | ;;* position has to be spell checked. */ |
| 829 | ;;*---------------------------------------------------------------------*/ | 821 | ;;*---------------------------------------------------------------------*/ |
| 830 | (defvar flyspell-changes nil) | 822 | (defvar-local flyspell-changes nil) |
| 831 | (make-variable-buffer-local 'flyspell-changes) | ||
| 832 | 823 | ||
| 833 | ;;*---------------------------------------------------------------------*/ | 824 | ;;*---------------------------------------------------------------------*/ |
| 834 | ;;* flyspell-after-change-function ... */ | 825 | ;;* flyspell-after-change-function ... */ |
| @@ -1894,14 +1885,10 @@ as returned by `ispell-parse-output'." | |||
| 1894 | ;;*---------------------------------------------------------------------*/ | 1885 | ;;*---------------------------------------------------------------------*/ |
| 1895 | ;;* flyspell-auto-correct-cache ... */ | 1886 | ;;* flyspell-auto-correct-cache ... */ |
| 1896 | ;;*---------------------------------------------------------------------*/ | 1887 | ;;*---------------------------------------------------------------------*/ |
| 1897 | (defvar flyspell-auto-correct-pos nil) | 1888 | (defvar-local flyspell-auto-correct-pos nil) |
| 1898 | (defvar flyspell-auto-correct-region nil) | 1889 | (defvar-local flyspell-auto-correct-region nil) |
| 1899 | (defvar flyspell-auto-correct-ring nil) | 1890 | (defvar-local flyspell-auto-correct-ring nil) |
| 1900 | (defvar flyspell-auto-correct-word nil) | 1891 | (defvar-local flyspell-auto-correct-word nil) |
| 1901 | (make-variable-buffer-local 'flyspell-auto-correct-pos) | ||
| 1902 | (make-variable-buffer-local 'flyspell-auto-correct-region) | ||
| 1903 | (make-variable-buffer-local 'flyspell-auto-correct-ring) | ||
| 1904 | (make-variable-buffer-local 'flyspell-auto-correct-word) | ||
| 1905 | 1892 | ||
| 1906 | ;;*---------------------------------------------------------------------*/ | 1893 | ;;*---------------------------------------------------------------------*/ |
| 1907 | ;;* flyspell-check-previous-highlighted-word ... */ | 1894 | ;;* flyspell-check-previous-highlighted-word ... */ |
diff --git a/lisp/textmodes/ispell.el b/lisp/textmodes/ispell.el index 8d49a7c54c8..ea46270508e 100644 --- a/lisp/textmodes/ispell.el +++ b/lisp/textmodes/ispell.el | |||
| @@ -351,9 +351,8 @@ If nil, the default personal dictionary for your spelling checker is used." | |||
| 351 | :type 'boolean | 351 | :type 'boolean |
| 352 | :group 'ispell) | 352 | :group 'ispell) |
| 353 | 353 | ||
| 354 | (defvar ispell-local-dictionary-overridden nil | 354 | (defvar-local ispell-local-dictionary-overridden nil |
| 355 | "Non-nil means the user has explicitly set this buffer's Ispell dictionary.") | 355 | "Non-nil means the user has explicitly set this buffer's Ispell dictionary.") |
| 356 | (make-variable-buffer-local 'ispell-local-dictionary-overridden) | ||
| 357 | 356 | ||
| 358 | (defcustom ispell-local-dictionary nil | 357 | (defcustom ispell-local-dictionary nil |
| 359 | "If non-nil, the dictionary to be used for Ispell commands in this buffer. | 358 | "If non-nil, the dictionary to be used for Ispell commands in this buffer. |
| @@ -1748,7 +1747,7 @@ Note - substrings of other matches must come last | |||
| 1748 | (e.g. \"<[tT][tT]/\" and \"<[^ \\t\\n>]\").") | 1747 | (e.g. \"<[tT][tT]/\" and \"<[^ \\t\\n>]\").") |
| 1749 | (put 'ispell-html-skip-alists 'risky-local-variable t) | 1748 | (put 'ispell-html-skip-alists 'risky-local-variable t) |
| 1750 | 1749 | ||
| 1751 | (defvar ispell-local-pdict ispell-personal-dictionary | 1750 | (defvar-local ispell-local-pdict ispell-personal-dictionary |
| 1752 | "A buffer local variable containing the current personal dictionary. | 1751 | "A buffer local variable containing the current personal dictionary. |
| 1753 | If non-nil, the value must be a string, which is a file name. | 1752 | If non-nil, the value must be a string, which is a file name. |
| 1754 | 1753 | ||
| @@ -1758,18 +1757,15 @@ to calling \\[ispell-change-dictionary]. This variable is automatically | |||
| 1758 | set when defined in the file with either `ispell-pdict-keyword' or the | 1757 | set when defined in the file with either `ispell-pdict-keyword' or the |
| 1759 | local variable syntax.") | 1758 | local variable syntax.") |
| 1760 | 1759 | ||
| 1761 | (make-variable-buffer-local 'ispell-local-pdict) | ||
| 1762 | ;;;###autoload(put 'ispell-local-pdict 'safe-local-variable 'stringp) | 1760 | ;;;###autoload(put 'ispell-local-pdict 'safe-local-variable 'stringp) |
| 1763 | 1761 | ||
| 1764 | (defvar ispell-buffer-local-name nil | 1762 | (defvar ispell-buffer-local-name nil |
| 1765 | "Contains the buffer name if local word definitions were used. | 1763 | "Contains the buffer name if local word definitions were used. |
| 1766 | Ispell is then restarted because the local words could conflict.") | 1764 | Ispell is then restarted because the local words could conflict.") |
| 1767 | 1765 | ||
| 1768 | (defvar ispell-buffer-session-localwords nil | 1766 | (defvar-local ispell-buffer-session-localwords nil |
| 1769 | "List of words accepted for session in this buffer.") | 1767 | "List of words accepted for session in this buffer.") |
| 1770 | 1768 | ||
| 1771 | (make-variable-buffer-local 'ispell-buffer-session-localwords) | ||
| 1772 | |||
| 1773 | (defvar ispell-parser 'use-mode-name | 1769 | (defvar ispell-parser 'use-mode-name |
| 1774 | "Indicates whether ispell should parse the current buffer as TeX Code. | 1770 | "Indicates whether ispell should parse the current buffer as TeX Code. |
| 1775 | Special value `use-mode-name' tries to guess using the name of `major-mode'. | 1771 | Special value `use-mode-name' tries to guess using the name of `major-mode'. |
diff --git a/lisp/textmodes/refill.el b/lisp/textmodes/refill.el index 6edd9aeb7ef..8f4f3c5a231 100644 --- a/lisp/textmodes/refill.el +++ b/lisp/textmodes/refill.el | |||
| @@ -88,10 +88,9 @@ | |||
| 88 | ;;; "Refilling paragraphs on changes." | 88 | ;;; "Refilling paragraphs on changes." |
| 89 | ;;; :group 'fill) | 89 | ;;; :group 'fill) |
| 90 | 90 | ||
| 91 | (defvar refill-ignorable-overlay nil | 91 | (defvar-local refill-ignorable-overlay nil |
| 92 | "Portion of the most recently filled paragraph not needing filling. | 92 | "Portion of the most recently filled paragraph not needing filling. |
| 93 | This is used to optimize refilling.") | 93 | This is used to optimize refilling.") |
| 94 | (make-variable-buffer-local 'refill-ignorable-overlay) | ||
| 95 | 94 | ||
| 96 | (defun refill-adjust-ignorable-overlay (overlay afterp beg end &optional len) | 95 | (defun refill-adjust-ignorable-overlay (overlay afterp beg end &optional len) |
| 97 | "Adjust OVERLAY to not include the about-to-be-modified region." | 96 | "Adjust OVERLAY to not include the about-to-be-modified region." |
| @@ -149,7 +148,7 @@ This is used to optimize refilling.") | |||
| 149 | "Like `fill-paragraph' but don't delete whitespace at paragraph end." | 148 | "Like `fill-paragraph' but don't delete whitespace at paragraph end." |
| 150 | (refill-fill-paragraph-at (point) arg)) | 149 | (refill-fill-paragraph-at (point) arg)) |
| 151 | 150 | ||
| 152 | (defvar refill-doit nil | 151 | (defvar-local refill-doit nil |
| 153 | "Non-nil tells `refill-post-command-function' to do its processing. | 152 | "Non-nil tells `refill-post-command-function' to do its processing. |
| 154 | Set by `refill-after-change-function' in `after-change-functions' and | 153 | Set by `refill-after-change-function' in `after-change-functions' and |
| 155 | unset by `refill-post-command-function' in `post-command-hook', and | 154 | unset by `refill-post-command-function' in `post-command-hook', and |
| @@ -157,7 +156,6 @@ sometimes `refill-pre-command-function' in `pre-command-hook'. This | |||
| 157 | ensures refilling is only done once per command that causes a change, | 156 | ensures refilling is only done once per command that causes a change, |
| 158 | regardless of the number of after-change calls from commands doing | 157 | regardless of the number of after-change calls from commands doing |
| 159 | complex processing.") | 158 | complex processing.") |
| 160 | (make-variable-buffer-local 'refill-doit) | ||
| 161 | 159 | ||
| 162 | (defun refill-after-change-function (beg end len) | 160 | (defun refill-after-change-function (beg end len) |
| 163 | "Function for `after-change-functions' which just sets `refill-doit'." | 161 | "Function for `after-change-functions' which just sets `refill-doit'." |
diff --git a/lisp/textmodes/sgml-mode.el b/lisp/textmodes/sgml-mode.el index c50c544cb54..3e29f055ece 100644 --- a/lisp/textmodes/sgml-mode.el +++ b/lisp/textmodes/sgml-mode.el | |||
| @@ -2290,19 +2290,17 @@ This takes effect when first loading the library.") | |||
| 2290 | nil t) | 2290 | nil t) |
| 2291 | (match-string-no-properties 1)))) | 2291 | (match-string-no-properties 1)))) |
| 2292 | 2292 | ||
| 2293 | (defvar html--buffer-classes-cache nil | 2293 | (defvar-local html--buffer-classes-cache nil |
| 2294 | "Cache for `html-current-buffer-classes'. | 2294 | "Cache for `html-current-buffer-classes'. |
| 2295 | When set, this should be a cons cell where the CAR is the | 2295 | When set, this should be a cons cell where the CAR is the |
| 2296 | buffer's tick counter (as produced by `buffer-modified-tick'), | 2296 | buffer's tick counter (as produced by `buffer-modified-tick'), |
| 2297 | and the CDR is the list of class names found in the buffer.") | 2297 | and the CDR is the list of class names found in the buffer.") |
| 2298 | (make-variable-buffer-local 'html--buffer-classes-cache) | ||
| 2299 | 2298 | ||
| 2300 | (defvar html--buffer-ids-cache nil | 2299 | (defvar-local html--buffer-ids-cache nil |
| 2301 | "Cache for `html-current-buffer-ids'. | 2300 | "Cache for `html-current-buffer-ids'. |
| 2302 | When set, this should be a cons cell where the CAR is the | 2301 | When set, this should be a cons cell where the CAR is the |
| 2303 | buffer's tick counter (as produced by `buffer-modified-tick'), | 2302 | buffer's tick counter (as produced by `buffer-modified-tick'), |
| 2304 | and the CDR is the list of class names found in the buffer.") | 2303 | and the CDR is the list of class names found in the buffer.") |
| 2305 | (make-variable-buffer-local 'html--buffer-ids-cache) | ||
| 2306 | 2304 | ||
| 2307 | (declare-function libxml-parse-html-region "xml.c" | 2305 | (declare-function libxml-parse-html-region "xml.c" |
| 2308 | (start end &optional base-url discard-comments)) | 2306 | (start end &optional base-url discard-comments)) |
diff --git a/lisp/textmodes/table.el b/lisp/textmodes/table.el index 071684d3c4d..06785e458b2 100644 --- a/lisp/textmodes/table.el +++ b/lisp/textmodes/table.el | |||
| @@ -859,11 +859,10 @@ cell to cache and cache to cell.") | |||
| 859 | "Non-nil inhibits auto fill paragraph when `table-with-cache-buffer' exits. | 859 | "Non-nil inhibits auto fill paragraph when `table-with-cache-buffer' exits. |
| 860 | This is always set to nil at the entry to `table-with-cache-buffer' before | 860 | This is always set to nil at the entry to `table-with-cache-buffer' before |
| 861 | executing body forms.") | 861 | executing body forms.") |
| 862 | (defvar table-mode-indicator nil | 862 | (defvar-local table-mode-indicator nil |
| 863 | "For mode line indicator") | 863 | "For mode line indicator") |
| 864 | ;; This is not a real minor-mode but placed in the minor-mode-alist | 864 | ;; This is not a real minor-mode but placed in the minor-mode-alist |
| 865 | ;; so that we can show the indicator on the mode line handy. | 865 | ;; so that we can show the indicator on the mode line handy. |
| 866 | (make-variable-buffer-local 'table-mode-indicator) | ||
| 867 | (unless (assq table-mode-indicator minor-mode-alist) | 866 | (unless (assq table-mode-indicator minor-mode-alist) |
| 868 | (push '(table-mode-indicator (table-fixed-width-mode " Fixed-Table" " Table")) | 867 | (push '(table-mode-indicator (table-fixed-width-mode " Fixed-Table" " Table")) |
| 869 | minor-mode-alist)) | 868 | minor-mode-alist)) |
diff --git a/lisp/textmodes/tex-mode.el b/lisp/textmodes/tex-mode.el index ce665e61656..d5a79ad0ac5 100644 --- a/lisp/textmodes/tex-mode.el +++ b/lisp/textmodes/tex-mode.el | |||
| @@ -2044,8 +2044,7 @@ In the tex shell buffer this command behaves like `comint-send-input'." | |||
| 2044 | (with-current-buffer buffer | 2044 | (with-current-buffer buffer |
| 2045 | (setq default-directory directory)))) | 2045 | (setq default-directory directory)))) |
| 2046 | 2046 | ||
| 2047 | (defvar tex-send-command-modified-tick 0) | 2047 | (defvar-local tex-send-command-modified-tick 0) |
| 2048 | (make-variable-buffer-local 'tex-send-command-modified-tick) | ||
| 2049 | 2048 | ||
| 2050 | (defun tex-shell-proc () | 2049 | (defun tex-shell-proc () |
| 2051 | (or (tex-shell-running) (error "No TeX subprocess"))) | 2050 | (or (tex-shell-running) (error "No TeX subprocess"))) |
diff --git a/lisp/textmodes/two-column.el b/lisp/textmodes/two-column.el index 36aad84c0e6..d072ab16c3c 100644 --- a/lisp/textmodes/two-column.el +++ b/lisp/textmodes/two-column.el | |||
| @@ -218,15 +218,13 @@ minus this value." | |||
| 218 | ;; Markers seem to be the only buffer-id not affected by renaming a buffer. | 218 | ;; Markers seem to be the only buffer-id not affected by renaming a buffer. |
| 219 | ;; This nevertheless loses when a buffer is killed. The variable-name is | 219 | ;; This nevertheless loses when a buffer is killed. The variable-name is |
| 220 | ;; required by `describe-mode'. | 220 | ;; required by `describe-mode'. |
| 221 | (defvar 2C-mode nil | 221 | (defvar-local 2C-mode nil |
| 222 | "Marker to the associated buffer, if non-nil.") | 222 | "Marker to the associated buffer, if non-nil.") |
| 223 | (make-variable-buffer-local '2C-mode) | ||
| 224 | (put '2C-mode 'permanent-local t) | 223 | (put '2C-mode 'permanent-local t) |
| 225 | 224 | ||
| 226 | (setq minor-mode-alist (cons '(2C-mode " 2C") minor-mode-alist)) | 225 | (setq minor-mode-alist (cons '(2C-mode " 2C") minor-mode-alist)) |
| 227 | 226 | ||
| 228 | (defvar 2C-autoscroll-start nil) | 227 | (defvar-local 2C-autoscroll-start nil) |
| 229 | (make-variable-buffer-local '2C-autoscroll-start) | ||
| 230 | 228 | ||
| 231 | ;;;;; base functions ;;;;; | 229 | ;;;;; base functions ;;;;; |
| 232 | 230 | ||