aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--lisp/ChangeLog7
-rw-r--r--lisp/subr.el14
2 files changed, 9 insertions, 12 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index f7e3cb4fc7a..072de2b6caa 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,3 +1,8 @@
12012-07-19 Stefan Monnier <monnier@iro.umontreal.ca>
2
3 * subr.el (eventp): Presume that if it looks vaguely like an event,
4 it's an event (bug#10190).
5
12012-07-19 Fabián Ezequiel Gallina <fgallina@cuca> 62012-07-19 Fabián Ezequiel Gallina <fgallina@cuca>
2 7
3 Enhancements to ppss related code (thanks Stefan). 8 Enhancements to ppss related code (thanks Stefan).
@@ -5,7 +10,7 @@
5 (python-indent-calculate-indentation, python-indent-dedent-line) 10 (python-indent-calculate-indentation, python-indent-dedent-line)
6 (python-indent-electric-colon, python-nav-forward-block) 11 (python-indent-electric-colon, python-nav-forward-block)
7 (python-mode-abbrev-table) 12 (python-mode-abbrev-table)
8 (python-info-assignment-continuation-line-p): Simplified checks 13 (python-info-assignment-continuation-line-p): Simplify checks
9 for ppss context. 14 for ppss context.
10 (python-info-continuation-line-p): Cleanup. 15 (python-info-continuation-line-p): Cleanup.
11 (python-info-ppss-context): Do not catch 'quote. 16 (python-info-ppss-context): Do not catch 'quote.
diff --git a/lisp/subr.el b/lisp/subr.el
index 19b3475a95b..0afe33c6a4c 100644
--- a/lisp/subr.el
+++ b/lisp/subr.el
@@ -909,17 +909,9 @@ The normal global definition of the character C-x indirects to this keymap.")
909 909
910(defsubst eventp (obj) 910(defsubst eventp (obj)
911 "True if the argument is an event object." 911 "True if the argument is an event object."
912 (or (and (integerp obj) 912 (or (integerp obj)
913 ;; FIXME: Why bother? 913 (and (symbolp obj) obj (not (keywordp obj)))
914 ;; Filter out integers too large to be events. 914 (and (consp obj) (symbolp (car obj)))))
915 ;; M is the biggest modifier.
916 (zerop (logand obj (lognot (1- (lsh ?\M-\^@ 1)))))
917 (characterp (event-basic-type obj)))
918 (and (symbolp obj)
919 (get obj 'event-symbol-elements))
920 (and (consp obj)
921 (symbolp (car obj))
922 (get (car obj) 'event-symbol-elements))))
923 915
924(defun event-modifiers (event) 916(defun event-modifiers (event)
925 "Return a list of symbols representing the modifier keys in event EVENT. 917 "Return a list of symbols representing the modifier keys in event EVENT.