unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Noam Postavsky <npostavs@gmail.com>
To: Mambo Levis <mambo.levis@gmail.com>
Cc: 31455@debbugs.gnu.org
Subject: bug#31455: 26.1; last-command bug when selecting region with mouse
Date: Wed, 20 Jun 2018 07:50:38 -0400	[thread overview]
Message-ID: <87fu1hsmlt.fsf@gmail.com> (raw)
In-Reply-To: <1937811671.1080781.1526322608281@mail.yahoo.com> (Mambo Levis's message of "Mon, 14 May 2018 18:30:08 +0000 (UTC)")

tags 31455 + notabug
quit

Mambo Levis <mambo.levis@gmail.com> writes:

> I am printing the last-command made in emacs. When I select a region
> with the mouse a non common message is shown (see highlighted text
> below)

> last-command: #[257 \307!\310!\211\301\242=\204\0\306\300\311\240\210\211@\262\302=\203-\0\312!\203-\0\313\301\242\305#\202Z\0\314
> AA\211?\206X\0\211\303W\203H\0\315\302\303Z\316\301\242$\202X\0\211\304Y\205X\0\315\302\304ZT\316\301\242$\262\207 [(mouse-movement
> (#<window 48 on *Bug Help*> 267 (350 . 122) 428906093 nil 267 (43 . 7) nil (6 . 10) (8 . 16))) (267) #<window 48 on *Bug Help*> 0 60 0 t event-end
> posn-point mouse-movement integer-or-marker-p mouse--drag-set-mark-and-point mouse-position mouse-scroll-subr nil auto-hscroll-mode] 9
>
> (fn EVENT) e]

I don't think this is a bug, you're seeing the compiled form of this
lambda in mouse-drag-track:

(defun mouse-drag-track (start-event)
   [...]
       (define-key map [mouse-movement]
         (lambda (event) (interactive "e")
           (let* ((end (event-end event))
                  (end-point (posn-point end)))
              [...]

If you use cl-print functions, you can hide the ugly bytecode stuff,
e.g.:

    (defun print-last-command ()
      (message "last-command: %s" (cl-prin1-to-string last-command)))

Produces

    last-command: #f(compiled-function (event) (interactive "e") #<bytecode 0x4bfd41>)






  reply	other threads:[~2018-06-20 11:50 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <1937811671.1080781.1526322608281.ref@mail.yahoo.com>
2018-05-14 18:30 ` bug#31455: 26.1; last-command bug when selecting region with mouse Mambo Levis
2018-06-20 11:50   ` Noam Postavsky [this message]
2018-06-29 22:58     ` Noam Postavsky

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87fu1hsmlt.fsf@gmail.com \
    --to=npostavs@gmail.com \
    --cc=31455@debbugs.gnu.org \
    --cc=mambo.levis@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).