bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#27340: 26.0.50; byte-compile-delete-errors value changes unexpectedl


From: npostavs
Subject: bug#27340: 26.0.50; byte-compile-delete-errors value changes unexpectedly
Date: Mon, 12 Jun 2017 07:12:24 -0400
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/25.2.50 (gnu/linux)

found 27340 25.2
tags 27340 + confirmed
quit

Katsumi Yamaoka <yamaoka@jpl.org> writes:

> When loading a certain Lisp module that requires eieio, the value
> of `byte-compile-delete-errors' is changed to t (the default nil)
> unexpectedly.
[...]
> Though I don't know why it changes `byte-compile-delete-errors',
> I think it's a bug.

It's because of the 'cl-declaim' around that 'cl-defstruct':

    (progn
      ;; Arrange for field access not to bother checking if the access is indeed
      ;; made to an eieio--class object.
      (cl-declaim (optimize (safety 0)))

    (cl-defstruct (eieio--class
      ...
      )
      ;; Set it back to the default value.
      (cl-declaim (optimize (safety 1))))

The problem is that the default (safety 1) value is not default with
respect to byte-compile-delete-errors:

    (defun cl--do-proclaim (spec hist)
        ...
        (let (...
              (safety (assq (nth 1 (assq 'safety (cdr spec)))
                            '((0 t) (1 t) (2 t) (3 nil)))))
           ...
           (if safety (setq cl--optimize-safety (car safety)
                            byte-compile-delete-errors (nth 1 safety)))))





reply via email to

[Prev in Thread] Current Thread [Next in Thread]