diff options
| author | Joakim Verona | 2013-03-10 00:04:02 +0100 |
|---|---|---|
| committer | Joakim Verona | 2013-03-10 00:04:02 +0100 |
| commit | c446797d60edf1058f6cbec28e57255d245dd47b (patch) | |
| tree | cde628bacb1ec48c0bea9b9db71516c953b1e534 /src | |
| parent | 4b882bf72aa0ed074cde5c27af51b8cf0b4d8620 (diff) | |
| parent | 78cd48e721d04b94b35f6e02e7c1022092bf702e (diff) | |
| download | emacs-c446797d60edf1058f6cbec28e57255d245dd47b.tar.gz emacs-c446797d60edf1058f6cbec28e57255d245dd47b.zip | |
auto upstream
Diffstat (limited to 'src')
| -rw-r--r-- | src/ChangeLog | 21 | ||||
| -rw-r--r-- | src/coding.c | 2 | ||||
| -rw-r--r-- | src/keyboard.c | 2 | ||||
| -rw-r--r-- | src/keyboard.h | 12 |
4 files changed, 23 insertions, 14 deletions
diff --git a/src/ChangeLog b/src/ChangeLog index 69e8303111a..ae25a3c5d00 100644 --- a/src/ChangeLog +++ b/src/ChangeLog | |||
| @@ -1,3 +1,12 @@ | |||
| 1 | 2013-03-09 Stefan Monnier <monnier@iro.umontreal.ca> | ||
| 2 | |||
| 3 | * keyboard.h (EVENT_START, EVENT_END, POSN_WINDOW, POSN_POSN) | ||
| 4 | (POSN_WINDOW_POSN, POSN_TIMESTAMP): Be careful since events may come | ||
| 5 | from Elisp via unread-command-events. | ||
| 6 | |||
| 7 | * keyboard.c (access_keymap_keyremap): Accept nil return value from | ||
| 8 | functions to mean "no change". | ||
| 9 | |||
| 1 | 2013-03-08 Paul Eggert <eggert@cs.ucla.edu> | 10 | 2013-03-08 Paul Eggert <eggert@cs.ucla.edu> |
| 2 | 11 | ||
| 3 | region-cache.c, scroll.c, search.c: Use bool for booleans. | 12 | region-cache.c, scroll.c, search.c: Use bool for booleans. |
| @@ -19,8 +28,8 @@ | |||
| 19 | * lisp.h (find_newline, find_newline_no_quit): Adjust prototype. | 28 | * lisp.h (find_newline, find_newline_no_quit): Adjust prototype. |
| 20 | * bidi.c (bidi_find_paragraph_start): Pass byte position to | 29 | * bidi.c (bidi_find_paragraph_start): Pass byte position to |
| 21 | find_newline_no_quit, thus eliminating CHAR_TO_BYTE. | 30 | find_newline_no_quit, thus eliminating CHAR_TO_BYTE. |
| 22 | * editfns.c (Fconstrain_to_field): Break long line. Adjust | 31 | * editfns.c (Fconstrain_to_field): Break long line. |
| 23 | call to find_newline. | 32 | Adjust call to find_newline. |
| 24 | * indent.c (vmotion): Adjust calls to find_newline_no_quit. | 33 | * indent.c (vmotion): Adjust calls to find_newline_no_quit. |
| 25 | Use DEC_BOTH to start next search from the previous buffer | 34 | Use DEC_BOTH to start next search from the previous buffer |
| 26 | position, where appropriate. | 35 | position, where appropriate. |
| @@ -270,8 +279,8 @@ | |||
| 270 | 279 | ||
| 271 | 2013-03-02 Eli Zaretskii <eliz@gnu.org> | 280 | 2013-03-02 Eli Zaretskii <eliz@gnu.org> |
| 272 | 281 | ||
| 273 | * textprop.c (Fadd_text_properties, Fremove_text_properties): If | 282 | * textprop.c (Fadd_text_properties, Fremove_text_properties): |
| 274 | the interval tree changes as a side effect of calling | 283 | If the interval tree changes as a side effect of calling |
| 275 | modify_region, re-do processing starting from the call to | 284 | modify_region, re-do processing starting from the call to |
| 276 | validate_interval_range. (Bug#13743) | 285 | validate_interval_range. (Bug#13743) |
| 277 | 286 | ||
| @@ -347,8 +356,8 @@ | |||
| 347 | * textprop.c (Fadd_text_properties, Fremove_text_properties) | 356 | * textprop.c (Fadd_text_properties, Fremove_text_properties) |
| 348 | (Fremove_list_of_text_properties): Skip all of the intervals in | 357 | (Fremove_list_of_text_properties): Skip all of the intervals in |
| 349 | the region between START and END that already have resp. don't | 358 | the region between START and END that already have resp. don't |
| 350 | have the requested properties, not just the first one. Add | 359 | have the requested properties, not just the first one. |
| 351 | assertions that the loop afterwards always modifies the | 360 | Add assertions that the loop afterwards always modifies the |
| 352 | properties. (Bug#13743) | 361 | properties. (Bug#13743) |
| 353 | 362 | ||
| 354 | 2013-02-25 Stefan Monnier <monnier@iro.umontreal.ca> | 363 | 2013-02-25 Stefan Monnier <monnier@iro.umontreal.ca> |
diff --git a/src/coding.c b/src/coding.c index 32da72ab626..78e6cff7078 100644 --- a/src/coding.c +++ b/src/coding.c | |||
| @@ -7970,7 +7970,7 @@ wchar_t * | |||
| 7970 | to_unicode (Lisp_Object str, Lisp_Object *buf) | 7970 | to_unicode (Lisp_Object str, Lisp_Object *buf) |
| 7971 | { | 7971 | { |
| 7972 | *buf = code_convert_string_norecord (str, Qutf_16le, 1); | 7972 | *buf = code_convert_string_norecord (str, Qutf_16le, 1); |
| 7973 | /* We need to make a another copy (in addition to the one made by | 7973 | /* We need to make another copy (in addition to the one made by |
| 7974 | code_convert_string_norecord) to ensure that the final string is | 7974 | code_convert_string_norecord) to ensure that the final string is |
| 7975 | _doubly_ zero terminated --- that is, that the string is | 7975 | _doubly_ zero terminated --- that is, that the string is |
| 7976 | terminated by two zero bytes and one utf-16le null character. | 7976 | terminated by two zero bytes and one utf-16le null character. |
diff --git a/src/keyboard.c b/src/keyboard.c index 3faffbe565a..65d44ca3d1f 100644 --- a/src/keyboard.c +++ b/src/keyboard.c | |||
| @@ -8718,7 +8718,7 @@ access_keymap_keyremap (Lisp_Object map, Lisp_Object key, Lisp_Object prompt, | |||
| 8718 | barf--don't ignore it. | 8718 | barf--don't ignore it. |
| 8719 | (To ignore it safely, we would need to gcpro a bunch of | 8719 | (To ignore it safely, we would need to gcpro a bunch of |
| 8720 | other variables.) */ | 8720 | other variables.) */ |
| 8721 | if (! (VECTORP (next) || STRINGP (next))) | 8721 | if (! (NILP (next) || VECTORP (next) || STRINGP (next))) |
| 8722 | error ("Function %s returns invalid key sequence", | 8722 | error ("Function %s returns invalid key sequence", |
| 8723 | SSDATA (SYMBOL_NAME (tem))); | 8723 | SSDATA (SYMBOL_NAME (tem))); |
| 8724 | } | 8724 | } |
diff --git a/src/keyboard.h b/src/keyboard.h index c6ade35dd52..8bb1c409efc 100644 --- a/src/keyboard.h +++ b/src/keyboard.h | |||
| @@ -421,18 +421,18 @@ typedef struct _widget_value | |||
| 421 | (EVENT_HAS_PARAMETERS (event) ? XCAR (event) : (event)) | 421 | (EVENT_HAS_PARAMETERS (event) ? XCAR (event) : (event)) |
| 422 | 422 | ||
| 423 | /* Extract the starting and ending positions from a composite event. */ | 423 | /* Extract the starting and ending positions from a composite event. */ |
| 424 | #define EVENT_START(event) (XCAR (XCDR (event))) | 424 | #define EVENT_START(event) (CAR_SAFE (CDR_SAFE (event))) |
| 425 | #define EVENT_END(event) (XCAR (XCDR (XCDR (event)))) | 425 | #define EVENT_END(event) (CAR_SAFE (CDR_SAFE (CDR_SAFE (event)))) |
| 426 | 426 | ||
| 427 | /* Extract the click count from a multi-click event. */ | 427 | /* Extract the click count from a multi-click event. */ |
| 428 | #define EVENT_CLICK_COUNT(event) (Fnth (make_number (2), (event))) | 428 | #define EVENT_CLICK_COUNT(event) (Fnth (make_number (2), (event))) |
| 429 | 429 | ||
| 430 | /* Extract the fields of a position. */ | 430 | /* Extract the fields of a position. */ |
| 431 | #define POSN_WINDOW(posn) (XCAR (posn)) | 431 | #define POSN_WINDOW(posn) (CAR_SAFE (posn)) |
| 432 | #define POSN_POSN(posn) (XCAR (XCDR (posn))) | 432 | #define POSN_POSN(posn) (CAR_SAFE (CDR_SAFE (posn))) |
| 433 | #define POSN_SET_POSN(posn,x) (XSETCAR (XCDR (posn), (x))) | 433 | #define POSN_SET_POSN(posn,x) (XSETCAR (XCDR (posn), (x))) |
| 434 | #define POSN_WINDOW_POSN(posn) (XCAR (XCDR (XCDR (posn)))) | 434 | #define POSN_WINDOW_POSN(posn) (CAR_SAFE (CDR_SAFE (CDR_SAFE (posn)))) |
| 435 | #define POSN_TIMESTAMP(posn) (XCAR (XCDR (XCDR (XCDR (posn))))) | 435 | #define POSN_TIMESTAMP(posn) (CAR_SAFE (CDR_SAFE (CDR_SAFE (CDR_SAFE (posn))))) |
| 436 | #define POSN_SCROLLBAR_PART(posn) (Fnth (make_number (4), (posn))) | 436 | #define POSN_SCROLLBAR_PART(posn) (Fnth (make_number (4), (posn))) |
| 437 | 437 | ||
| 438 | /* A cons (STRING . STRING-CHARPOS), or nil in mouse-click events. | 438 | /* A cons (STRING . STRING-CHARPOS), or nil in mouse-click events. |