diff options
| author | Philipp Stephani | 2017-10-03 16:14:54 +0200 |
|---|---|---|
| committer | Philipp Stephani | 2017-10-08 18:52:37 +0200 |
| commit | 9613690f6e51e2f2aa2bcbbede3e209d08cfaaad (patch) | |
| tree | 27bd9ddc57a7ae5ba7361d246b4bfec8f4aad043 /lisp | |
| parent | f4995e7d36b576d9ed629b45dd3b09ba6d28cce7 (diff) | |
| download | emacs-9613690f6e51e2f2aa2bcbbede3e209d08cfaaad.tar.gz emacs-9613690f6e51e2f2aa2bcbbede3e209d08cfaaad.zip | |
Raise an error when detecting old-style backquotes.
They have been deprecated for a decade now.
* src/lread.c (Fload): Don't use record_unwind_protect to warn about
old-style backquotes any more. They now generate a hard error.
(read1): Signal an error when detecting old-style backquotes. Remove
unused label.
(syms_of_lread): Remove unused internal variable
'lread--old-style-backquotes'.
(load_error_old_style_backquotes): Rename from
'load_warn_oldstyle_backquotes'. Signal an error.
* lisp/emacs-lisp/bytecomp.el (byte-compile-from-buffer): Remove check
from byte compiler. It isn't triggered any more.
* test/src/lread-tests.el (lread-tests--old-style-backquotes): Adapt
unit test.
* test/lisp/emacs-lisp/bytecomp-tests.el
(bytecomp-tests--old-style-backquotes)
(bytecomp-tests-function-put): Adapt unit tests.
* etc/NEWS: Document change.
Diffstat (limited to 'lisp')
| -rw-r--r-- | lisp/emacs-lisp/bytecomp.el | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/lisp/emacs-lisp/bytecomp.el b/lisp/emacs-lisp/bytecomp.el index 590db570c56..45fa188d6c8 100644 --- a/lisp/emacs-lisp/bytecomp.el +++ b/lisp/emacs-lisp/bytecomp.el | |||
| @@ -2048,14 +2048,8 @@ With argument ARG, insert value in current buffer after the form." | |||
| 2048 | (not (eobp))) | 2048 | (not (eobp))) |
| 2049 | (setq byte-compile-read-position (point) | 2049 | (setq byte-compile-read-position (point) |
| 2050 | byte-compile-last-position byte-compile-read-position) | 2050 | byte-compile-last-position byte-compile-read-position) |
| 2051 | (let* ((lread--old-style-backquotes nil) | 2051 | (let* ((lread--unescaped-character-literals nil) |
| 2052 | (lread--unescaped-character-literals nil) | ||
| 2053 | (form (read inbuffer))) | 2052 | (form (read inbuffer))) |
| 2054 | ;; Warn about the use of old-style backquotes. | ||
| 2055 | (when lread--old-style-backquotes | ||
| 2056 | (byte-compile-warn "!! The file uses old-style backquotes !! | ||
| 2057 | This functionality has been obsolete for more than 10 years already | ||
| 2058 | and will be removed soon. See (elisp)Backquote in the manual.")) | ||
| 2059 | (when lread--unescaped-character-literals | 2053 | (when lread--unescaped-character-literals |
| 2060 | (byte-compile-warn | 2054 | (byte-compile-warn |
| 2061 | "unescaped character literals %s detected!" | 2055 | "unescaped character literals %s detected!" |