[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] /srv/bzr/emacs/trunk r109156: * lisp/subr.el (eventp): Pre
From: |
Stefan Monnier |
Subject: |
[Emacs-diffs] /srv/bzr/emacs/trunk r109156: * lisp/subr.el (eventp): Presume that if it looks vaguely like an event, |
Date: |
Thu, 19 Jul 2012 02:24:04 -0400 |
User-agent: |
Bazaar (2.5.0) |
------------------------------------------------------------
revno: 109156
fixes bug: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=10190
committer: Stefan Monnier <address@hidden>
branch nick: trunk
timestamp: Thu 2012-07-19 02:24:04 -0400
message:
* lisp/subr.el (eventp): Presume that if it looks vaguely like an event,
it's an event.
modified:
lisp/ChangeLog
lisp/subr.el
=== modified file 'lisp/ChangeLog'
--- a/lisp/ChangeLog 2012-07-19 00:55:55 +0000
+++ b/lisp/ChangeLog 2012-07-19 06:24:04 +0000
@@ -1,3 +1,8 @@
+2012-07-19 Stefan Monnier <address@hidden>
+
+ * subr.el (eventp): Presume that if it looks vaguely like an event,
+ it's an event (bug#10190).
+
2012-07-19 Fabián Ezequiel Gallina <address@hidden>
Enhancements to ppss related code (thanks Stefan).
@@ -5,7 +10,7 @@
(python-indent-calculate-indentation, python-indent-dedent-line)
(python-indent-electric-colon, python-nav-forward-block)
(python-mode-abbrev-table)
- (python-info-assignment-continuation-line-p): Simplified checks
+ (python-info-assignment-continuation-line-p): Simplify checks
for ppss context.
(python-info-continuation-line-p): Cleanup.
(python-info-ppss-context): Do not catch 'quote.
=== modified file 'lisp/subr.el'
--- a/lisp/subr.el 2012-07-18 14:48:25 +0000
+++ b/lisp/subr.el 2012-07-19 06:24:04 +0000
@@ -909,17 +909,9 @@
(defsubst eventp (obj)
"True if the argument is an event object."
- (or (and (integerp obj)
- ;; FIXME: Why bother?
- ;; Filter out integers too large to be events.
- ;; M is the biggest modifier.
- (zerop (logand obj (lognot (1- (lsh ?\M-\^@ 1)))))
- (characterp (event-basic-type obj)))
- (and (symbolp obj)
- (get obj 'event-symbol-elements))
- (and (consp obj)
- (symbolp (car obj))
- (get (car obj) 'event-symbol-elements))))
+ (or (integerp obj)
+ (and (symbolp obj) obj (not (keywordp obj)))
+ (and (consp obj) (symbolp (car obj)))))
(defun event-modifiers (event)
"Return a list of symbols representing the modifier keys in event EVENT.
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Emacs-diffs] /srv/bzr/emacs/trunk r109156: * lisp/subr.el (eventp): Presume that if it looks vaguely like an event,,
Stefan Monnier <=