[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] /srv/bzr/emacs/trunk r99979: Fix bug #5992.
From: |
Eli Zaretskii |
Subject: |
[Emacs-diffs] /srv/bzr/emacs/trunk r99979: Fix bug #5992. |
Date: |
Wed, 21 Apr 2010 20:59:39 +0300 |
User-agent: |
Bazaar (2.0.3) |
------------------------------------------------------------
revno: 99979
committer: Eli Zaretskii <address@hidden>
branch nick: trunk
timestamp: Wed 2010-04-21 20:59:39 +0300
message:
Fix bug #5992.
bidi.c (bidi_find_paragraph_start, bidi_at_paragraph_end): Don't
use buffer-local values of paragraph-start and paragraph-separate.
<paragraph_start_re, paragraph_separate_re>: Rename from
fallback_paragraph_start_re and fallback_paragraph_separate_re.
modified:
src/ChangeLog
src/bidi.c
=== modified file 'src/ChangeLog'
--- a/src/ChangeLog 2010-04-20 18:52:07 +0000
+++ b/src/ChangeLog 2010-04-21 17:59:39 +0000
@@ -1,3 +1,11 @@
+2010-04-21 Eli Zaretskii <address@hidden>
+
+ * bidi.c (bidi_find_paragraph_start, bidi_at_paragraph_end): Don't
+ use buffer-local values of paragraph-start and paragraph-separate.
+ <paragraph_start_re, paragraph_separate_re>: Rename from
+ fallback_paragraph_start_re and fallback_paragraph_separate_re.
+ (Bug#5992)
+
2010-04-21 Jan Djärv <address@hidden>
* xsettings.c: Qmonospace_font_name, Qtool_bar_style and
=== modified file 'src/bidi.c'
--- a/src/bidi.c 2010-04-20 17:01:39 +0000
+++ b/src/bidi.c 2010-04-21 17:59:39 +0000
@@ -102,7 +102,7 @@
int bidi_ignore_explicit_marks_for_paragraph_level = 1;
-static Lisp_Object fallback_paragraph_start_re, fallback_paragraph_separate_re;
+static Lisp_Object paragraph_start_re, paragraph_separate_re;
static Lisp_Object Qparagraph_start, Qparagraph_separate;
static void
@@ -401,16 +401,16 @@
Qparagraph_start = intern ("paragraph-start");
staticpro (&Qparagraph_start);
- fallback_paragraph_start_re = Fsymbol_value (Qparagraph_start);
- if (!STRINGP (fallback_paragraph_start_re))
- fallback_paragraph_start_re = build_string ("\f\\|[ \t]*$");
- staticpro (&fallback_paragraph_start_re);
+ paragraph_start_re = Fsymbol_value (Qparagraph_start);
+ if (!STRINGP (paragraph_start_re))
+ paragraph_start_re = build_string ("\f\\|[ \t]*$");
+ staticpro (¶graph_start_re);
Qparagraph_separate = intern ("paragraph-separate");
staticpro (&Qparagraph_separate);
- fallback_paragraph_separate_re = Fsymbol_value (Qparagraph_separate);
- if (!STRINGP (fallback_paragraph_separate_re))
- fallback_paragraph_separate_re = build_string ("[ \t\f]*$");
- staticpro (&fallback_paragraph_separate_re);
+ paragraph_separate_re = Fsymbol_value (Qparagraph_separate);
+ if (!STRINGP (paragraph_separate_re))
+ paragraph_separate_re = build_string ("[ \t\f]*$");
+ staticpro (¶graph_separate_re);
bidi_initialized = 1;
}
@@ -751,16 +751,12 @@
bidi_at_paragraph_end (EMACS_INT charpos, EMACS_INT bytepos)
{
/* FIXME: Why Fbuffer_local_value rather than just Fsymbol_value? */
- Lisp_Object sep_re = Fbuffer_local_value (Qparagraph_separate,
- Fcurrent_buffer ());
- Lisp_Object start_re = Fbuffer_local_value (Qparagraph_start,
- Fcurrent_buffer ());
+ Lisp_Object sep_re;
+ Lisp_Object start_re;
EMACS_INT val;
- if (!STRINGP (sep_re))
- sep_re = fallback_paragraph_separate_re;
- if (!STRINGP (start_re))
- start_re = fallback_paragraph_start_re;
+ sep_re = paragraph_separate_re;
+ start_re = paragraph_start_re;
val = fast_looking_at (sep_re, charpos, bytepos, ZV, ZV_BYTE, Qnil);
if (val < 0)
@@ -829,12 +825,9 @@
static EMACS_INT
bidi_find_paragraph_start (EMACS_INT pos, EMACS_INT pos_byte)
{
- /* FIXME: Why Fbuffer_local_value rather than just Fsymbol_value? */
- Lisp_Object re = Fbuffer_local_value (Qparagraph_start, Fcurrent_buffer ());
+ Lisp_Object re = paragraph_start_re;
EMACS_INT limit = ZV, limit_byte = ZV_BYTE;
- if (!STRINGP (re))
- re = fallback_paragraph_start_re;
while (pos_byte > BEGV_BYTE
&& fast_looking_at (re, pos, pos_byte, limit, limit_byte, Qnil) < 0)
{
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Emacs-diffs] /srv/bzr/emacs/trunk r99979: Fix bug #5992.,
Eli Zaretskii <=