Skip to content

Commit 35d5694

Browse files
committed
Mark 'catch' and 'condition-case' bytecodes as obsolete
They have not been generated by the byte-compiler since Emacs 25. * lisp/emacs-lisp/bytecomp.el (byte-catch, byte-condition-case): * src/bytecode.c (BYTE_CODES, exec_byte_code): Mark as obsolete (since Emacs 25; they were still generated in 24.4).
1 parent b47a0d6 commit 35d5694

File tree

2 files changed

+7
-6
lines changed

2 files changed

+7
-6
lines changed

lisp/emacs-lisp/bytecomp.el

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -719,14 +719,15 @@ otherwise pop it")
719719
"to make a binding to record entire window configuration")
720720
(byte-defop 140 0 byte-save-restriction
721721
"to make a binding to record the current buffer clipping restrictions")
722-
(byte-defop 141 -1 byte-catch
722+
(byte-defop 141 -1 byte-catch-OBSOLETE ; Not generated since Emacs 25.
723723
"for catch. Takes, on stack, the tag and an expression for the body")
724724
(byte-defop 142 -1 byte-unwind-protect
725725
"for unwind-protect. Takes, on stack, an expression for the unwind-action")
726726

727727
;; For condition-case. Takes, on stack, the variable to bind,
728728
;; an expression for the body, and a list of clauses.
729-
(byte-defop 143 -2 byte-condition-case)
729+
;; Not generated since Emacs 25.
730+
(byte-defop 143 -2 byte-condition-case-OBSOLETE)
730731

731732
(byte-defop 144 0 byte-temp-output-buffer-setup-OBSOLETE)
732733
(byte-defop 145 -1 byte-temp-output-buffer-show-OBSOLETE)

src/bytecode.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -220,10 +220,10 @@ DEFINE (Bdup, 0211) \
220220
DEFINE (Bsave_excursion, 0212) \
221221
DEFINE (Bsave_window_excursion, 0213) /* Obsolete since Emacs-24.1. */ \
222222
DEFINE (Bsave_restriction, 0214) \
223-
DEFINE (Bcatch, 0215) \
223+
DEFINE (Bcatch, 0215) /* Obsolete since Emacs-25. */ \
224224
\
225225
DEFINE (Bunwind_protect, 0216) \
226-
DEFINE (Bcondition_case, 0217) \
226+
DEFINE (Bcondition_case, 0217) /* Obsolete since Emacs-25. */ \
227227
DEFINE (Btemp_output_buffer_setup, 0220) /* Obsolete since Emacs-24.1. */ \
228228
DEFINE (Btemp_output_buffer_show, 0221) /* Obsolete since Emacs-24.1. */ \
229229
\
@@ -763,7 +763,7 @@ exec_byte_code (Lisp_Object bytestr, Lisp_Object vector, Lisp_Object maxdepth,
763763
save_restriction_save ());
764764
NEXT;
765765

766-
CASE (Bcatch): /* Obsolete since 24.4. */
766+
CASE (Bcatch): /* Obsolete since 25. */
767767
{
768768
Lisp_Object v1 = POP;
769769
TOP = internal_catch (TOP, eval_sub, v1);
@@ -807,7 +807,7 @@ exec_byte_code (Lisp_Object bytestr, Lisp_Object vector, Lisp_Object maxdepth,
807807
NEXT;
808808
}
809809

810-
CASE (Bcondition_case): /* Obsolete since 24.4. */
810+
CASE (Bcondition_case): /* Obsolete since 25. */
811811
{
812812
Lisp_Object handlers = POP, body = POP;
813813
TOP = internal_lisp_condition_case (TOP, body, handlers);

0 commit comments

Comments
 (0)