aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorMiles Bader2001-10-19 07:08:29 +0000
committerMiles Bader2001-10-19 07:08:29 +0000
commitb57c2708f0ab0155f7e27cae9d3a42408a947052 (patch)
tree964a0c5637008870e4bc352673164556b2ec1e7e /src
parent79f1f96cb1a7eac42d9c0fe8e78a1cdcb17281dc (diff)
downloademacs-b57c2708f0ab0155f7e27cae9d3a42408a947052.tar.gz
emacs-b57c2708f0ab0155f7e27cae9d3a42408a947052.zip
(text_property_stickiness): Non-rear-non-stickiness doesn't take
precedence if the affected property's value is nil. (Fencode_time): Escape a BOL paren in the doc-string.
Diffstat (limited to 'src')
-rw-r--r--src/ChangeLog5
-rw-r--r--src/editfns.c28
2 files changed, 22 insertions, 11 deletions
diff --git a/src/ChangeLog b/src/ChangeLog
index 90de9550267..b125b1f149a 100644
--- a/src/ChangeLog
+++ b/src/ChangeLog
@@ -1,5 +1,10 @@
12001-10-19 Miles Bader <miles@gnu.org> 12001-10-19 Miles Bader <miles@gnu.org>
2 2
3 * editfns.c (text_property_stickiness): Non-rear-non-stickiness
4 doesn't take precedence if the affected property's value is nil.
5
6 * editfns.c (Fencode_time): Escape a BOL paren in the doc-string.
7
3 * cmds.c (Fbeginning_of_line, Fend_of_line): Clarify interaction 8 * cmds.c (Fbeginning_of_line, Fend_of_line): Clarify interaction
4 with fields and suggest using `forward-line' to avoid them. 9 with fields and suggest using `forward-line' to avoid them.
5 * editfns.c (Fline_beginning_position, Fline_end_position): 10 * editfns.c (Fline_beginning_position, Fline_end_position):
diff --git a/src/editfns.c b/src/editfns.c
index 661ad95d292..d0b682ff67e 100644
--- a/src/editfns.c
+++ b/src/editfns.c
@@ -357,17 +357,23 @@ text_property_stickiness (prop, pos)
357 if (XINT (pos) > BEGV) 357 if (XINT (pos) > BEGV)
358 /* Consider previous character. */ 358 /* Consider previous character. */
359 { 359 {
360 Lisp_Object prev_pos, rear_non_sticky; 360 Lisp_Object prev_pos = make_number (XINT (pos) - 1);
361 361
362 prev_pos = make_number (XINT (pos) - 1); 362 if (! NILP (Fget_text_property (prev_pos, prop, Qnil)))
363 rear_non_sticky = Fget_text_property (prev_pos, Qrear_nonsticky, Qnil); 363 /* Non-rear-non-stickiness only takes precedence if the
364 364 preceding property value is non-nil. */
365 if (EQ (rear_non_sticky, Qnil) 365 {
366 || (CONSP (rear_non_sticky) 366 Lisp_Object rear_non_sticky
367 && NILP (Fmemq (prop, rear_non_sticky)))) 367 = Fget_text_property (prev_pos, Qrear_nonsticky, Qnil);
368 /* PROP is not rear-non-sticky, and since this takes precedence over 368
369 any front-stickiness, PROP is inherited from before. */ 369 if (EQ (rear_non_sticky, Qnil)
370 return -1; 370 || (CONSP (rear_non_sticky)
371 && NILP (Fmemq (prop, rear_non_sticky))))
372 /* PROP is not rear-non-sticky, and since this takes
373 precedence over any front-stickiness, PROP is inherited
374 from before. */
375 return -1;
376 }
371 } 377 }
372 378
373 /* Consider following character. */ 379 /* Consider following character. */
@@ -1599,7 +1605,7 @@ DEFUN ("encode-time", Fencode_time, Sencode_time, 6, MANY, 0,
1599This is the reverse operation of `decode-time', which see. 1605This is the reverse operation of `decode-time', which see.
1600ZONE defaults to the current time zone rule. This can 1606ZONE defaults to the current time zone rule. This can
1601be a string or t (as from `set-time-zone-rule'), or it can be a list 1607be a string or t (as from `set-time-zone-rule'), or it can be a list
1602(as from `current-time-zone') or an integer (as from `decode-time') 1608\(as from `current-time-zone') or an integer (as from `decode-time')
1603applied without consideration for daylight savings time. 1609applied without consideration for daylight savings time.
1604 1610
1605You can pass more than 7 arguments; then the first six arguments 1611You can pass more than 7 arguments; then the first six arguments