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

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

bug#59793: 29.0.60; subr.elc is not compiled correctly


From: Eli Zaretskii
Subject: bug#59793: 29.0.60; subr.elc is not compiled correctly
Date: Sat, 03 Dec 2022 17:37:31 +0200
User-agent: K-9 Mail for Android

On December 3, 2022 5:10:52 PM GMT+02:00, Akib Azmain Turja <akib@disroot.org> 
wrote:
> 
> 1. Save the following in a file.
> 
> --8<---------------cut here---------------start------------->8---
> (require 'cl-lib)
> (defun bug59593-yank (&optional arg)
>   (interactive "*P")
>   (cl-letf* ((inhibit-read-only t)
>              (insert-for-yank (symbol-function #'insert-for-yank))
>              ((symbol-function #'insert-for-yank)
>               (lambda (&rest args)
>                 (cl-letf (((symbol-function #'insert)
>                            (lambda (&rest args)
>                              (message
>                               "%S"
>                               (mapconcat (lambda (arg)
>                                            (if (stringp arg)
>                                                arg
>                                              (string arg)))
>                                          args "")))))
>                   (apply insert-for-yank args)))))
>     (yank arg)))
> --8<---------------cut here---------------end--------------->8---
> 
> 2. emacs -nw -Q -l FILE-FROM-STEP-1 -l PATH/TO/YOUR/SUBR.EL.GZ
> 3. Kill something.
> 4. M-x bug59593-yank.  Now you should see the yank text in echo area.
> 5. emacs -nw -Q -l FILE-FROM-STEP-1 -l PATH/TO/ATTACHED/SUBR.ELC
> 6. Kill something.
> 7. M-x bug59593-yank.  The yank text got unexpectedly inserted.

Am I missing something, or do you redefine a function and then expect it to 
work like you never redefined it?

And what do you mean by ATTACHED/SUBR.ELC?  I don't see any attachments to your 
message.

So I'm still confused...





reply via email to

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