diff options
| author | Po Lu | 2023-02-08 22:41:46 +0800 |
|---|---|---|
| committer | Po Lu | 2023-02-08 22:41:46 +0800 |
| commit | 2c5e36e00bdfb06bf965f3dcd1ebe3c68cca6d33 (patch) | |
| tree | 69f8b9aa9c92c9d6c3c116db7b071ca4c2e0c35e /src | |
| parent | 0bd4b7fdab2fdf437c4a759d53dfdc9f667aefb1 (diff) | |
| parent | 680bc20553ebf01375ab7957b6f0be066335fd6e (diff) | |
| download | emacs-2c5e36e00bdfb06bf965f3dcd1ebe3c68cca6d33.tar.gz emacs-2c5e36e00bdfb06bf965f3dcd1ebe3c68cca6d33.zip | |
Merge remote-tracking branch 'origin/master' into feature/android
Diffstat (limited to 'src')
| -rw-r--r-- | src/bidi.c | 15 | ||||
| -rw-r--r-- | src/buffer.c | 4 | ||||
| -rw-r--r-- | src/eval.c | 7 | ||||
| -rw-r--r-- | src/treesit.c | 2 | ||||
| -rw-r--r-- | src/xdisp.c | 5 |
5 files changed, 23 insertions, 10 deletions
diff --git a/src/bidi.c b/src/bidi.c index e01251263be..93875d243e4 100644 --- a/src/bidi.c +++ b/src/bidi.c | |||
| @@ -3300,12 +3300,15 @@ bidi_level_of_next_char (struct bidi_it *bidi_it) | |||
| 3300 | it belongs to a sequence of WS characters preceding a newline | 3300 | it belongs to a sequence of WS characters preceding a newline |
| 3301 | or a TAB or a paragraph separator. */ | 3301 | or a TAB or a paragraph separator. */ |
| 3302 | if ((bidi_it->orig_type == NEUTRAL_WS | 3302 | if ((bidi_it->orig_type == NEUTRAL_WS |
| 3303 | || bidi_it->orig_type == WEAK_BN | 3303 | || (bidi_it->orig_type == WEAK_BN |
| 3304 | /* If this BN character is already at base level, we don't | ||
| 3305 | need to consider resetting it, since I1 and I2 below | ||
| 3306 | will not change the level, so avoid the potentially | ||
| 3307 | costly loop below. */ | ||
| 3308 | && level != bidi_it->level_stack[0].level) | ||
| 3304 | || bidi_isolate_fmt_char (bidi_it->orig_type)) | 3309 | || bidi_isolate_fmt_char (bidi_it->orig_type)) |
| 3305 | && bidi_it->next_for_ws.charpos < bidi_it->charpos | 3310 | /* This means the informaition about WS resolution is not valid. */ |
| 3306 | /* If this character is already at base level, we don't need to | 3311 | && bidi_it->next_for_ws.charpos < bidi_it->charpos) |
| 3307 | reset it, so avoid the potentially costly loop below. */ | ||
| 3308 | && level != bidi_it->level_stack[0].level) | ||
| 3309 | { | 3312 | { |
| 3310 | int ch; | 3313 | int ch; |
| 3311 | ptrdiff_t clen = bidi_it->ch_len; | 3314 | ptrdiff_t clen = bidi_it->ch_len; |
| @@ -3340,7 +3343,7 @@ bidi_level_of_next_char (struct bidi_it *bidi_it) | |||
| 3340 | || bidi_it->orig_type == NEUTRAL_S | 3343 | || bidi_it->orig_type == NEUTRAL_S |
| 3341 | || bidi_it->ch == '\n' || bidi_it->ch == BIDI_EOB | 3344 | || bidi_it->ch == '\n' || bidi_it->ch == BIDI_EOB |
| 3342 | || ((bidi_it->orig_type == NEUTRAL_WS | 3345 | || ((bidi_it->orig_type == NEUTRAL_WS |
| 3343 | || bidi_it->orig_type == WEAK_BN | 3346 | || bidi_it->orig_type == WEAK_BN /* L1/Retaining */ |
| 3344 | || bidi_isolate_fmt_char (bidi_it->orig_type) | 3347 | || bidi_isolate_fmt_char (bidi_it->orig_type) |
| 3345 | || bidi_explicit_dir_char (bidi_it->ch)) | 3348 | || bidi_explicit_dir_char (bidi_it->ch)) |
| 3346 | && (bidi_it->next_for_ws.type == NEUTRAL_B | 3349 | && (bidi_it->next_for_ws.type == NEUTRAL_B |
diff --git a/src/buffer.c b/src/buffer.c index 88ca69b0dd8..38648519ba0 100644 --- a/src/buffer.c +++ b/src/buffer.c | |||
| @@ -5081,8 +5081,8 @@ the mode line appears at the bottom. */); | |||
| 5081 | The header line appears, optionally, at the top of a window; the mode | 5081 | The header line appears, optionally, at the top of a window; the mode |
| 5082 | line appears at the bottom. | 5082 | line appears at the bottom. |
| 5083 | 5083 | ||
| 5084 | Also see `header-line-indent-mode' if `display-line-number-mode' is | 5084 | Also see `header-line-indent-mode' if `display-line-numbers-mode' is |
| 5085 | used. */); | 5085 | turned on and header-line text should be aligned with buffer text. */); |
| 5086 | 5086 | ||
| 5087 | DEFVAR_PER_BUFFER ("mode-line-format", &BVAR (current_buffer, mode_line_format), | 5087 | DEFVAR_PER_BUFFER ("mode-line-format", &BVAR (current_buffer, mode_line_format), |
| 5088 | Qnil, | 5088 | Qnil, |
diff --git a/src/eval.c b/src/eval.c index d42f7ffe894..e377e30c6fb 100644 --- a/src/eval.c +++ b/src/eval.c | |||
| @@ -2348,6 +2348,8 @@ it defines a macro. */) | |||
| 2348 | } | 2348 | } |
| 2349 | 2349 | ||
| 2350 | 2350 | ||
| 2351 | static Lisp_Object list_of_t; /* Never-modified constant containing (t). */ | ||
| 2352 | |||
| 2351 | DEFUN ("eval", Feval, Seval, 1, 2, 0, | 2353 | DEFUN ("eval", Feval, Seval, 1, 2, 0, |
| 2352 | doc: /* Evaluate FORM and return its value. | 2354 | doc: /* Evaluate FORM and return its value. |
| 2353 | If LEXICAL is t, evaluate using lexical scoping. | 2355 | If LEXICAL is t, evaluate using lexical scoping. |
| @@ -2357,7 +2359,7 @@ alist mapping symbols to their value. */) | |||
| 2357 | { | 2359 | { |
| 2358 | specpdl_ref count = SPECPDL_INDEX (); | 2360 | specpdl_ref count = SPECPDL_INDEX (); |
| 2359 | specbind (Qinternal_interpreter_environment, | 2361 | specbind (Qinternal_interpreter_environment, |
| 2360 | CONSP (lexical) || NILP (lexical) ? lexical : list1 (Qt)); | 2362 | CONSP (lexical) || NILP (lexical) ? lexical : list_of_t); |
| 2361 | return unbind_to (count, eval_sub (form)); | 2363 | return unbind_to (count, eval_sub (form)); |
| 2362 | } | 2364 | } |
| 2363 | 2365 | ||
| @@ -4392,6 +4394,9 @@ alist of active lexical bindings. */); | |||
| 4392 | Qcatch_all_memory_full | 4394 | Qcatch_all_memory_full |
| 4393 | = Fmake_symbol (build_pure_c_string ("catch-all-memory-full")); | 4395 | = Fmake_symbol (build_pure_c_string ("catch-all-memory-full")); |
| 4394 | 4396 | ||
| 4397 | staticpro (&list_of_t); | ||
| 4398 | list_of_t = list1 (Qt); | ||
| 4399 | |||
| 4395 | defsubr (&Sor); | 4400 | defsubr (&Sor); |
| 4396 | defsubr (&Sand); | 4401 | defsubr (&Sand); |
| 4397 | defsubr (&Sif); | 4402 | defsubr (&Sif); |
diff --git a/src/treesit.c b/src/treesit.c index 8e772523cc7..b15d44fca01 100644 --- a/src/treesit.c +++ b/src/treesit.c | |||
| @@ -620,7 +620,7 @@ treesit_load_language (Lisp_Object language_symbol, | |||
| 620 | char *c_name = xstrdup (SSDATA (base_name)); | 620 | char *c_name = xstrdup (SSDATA (base_name)); |
| 621 | treesit_symbol_to_c_name (c_name); | 621 | treesit_symbol_to_c_name (c_name); |
| 622 | if (found_override) | 622 | if (found_override) |
| 623 | c_name = SSDATA (override_c_name); | 623 | c_name = xstrdup (SSDATA (override_c_name)); |
| 624 | langfn = dynlib_sym (handle, c_name); | 624 | langfn = dynlib_sym (handle, c_name); |
| 625 | xfree (c_name); | 625 | xfree (c_name); |
| 626 | error = dynlib_error (); | 626 | error = dynlib_error (); |
diff --git a/src/xdisp.c b/src/xdisp.c index 8082534c0a9..8bbb80b1c8c 100644 --- a/src/xdisp.c +++ b/src/xdisp.c | |||
| @@ -29385,6 +29385,7 @@ fill_gstring_glyph_string (struct glyph_string *s, int face_id, | |||
| 29385 | int start, int end, int overlaps) | 29385 | int start, int end, int overlaps) |
| 29386 | { | 29386 | { |
| 29387 | struct glyph *glyph, *last; | 29387 | struct glyph *glyph, *last; |
| 29388 | int voffset; | ||
| 29388 | Lisp_Object lgstring; | 29389 | Lisp_Object lgstring; |
| 29389 | int i; | 29390 | int i; |
| 29390 | bool glyph_not_available_p; | 29391 | bool glyph_not_available_p; |
| @@ -29392,6 +29393,7 @@ fill_gstring_glyph_string (struct glyph_string *s, int face_id, | |||
| 29392 | s->for_overlaps = overlaps; | 29393 | s->for_overlaps = overlaps; |
| 29393 | glyph = s->row->glyphs[s->area] + start; | 29394 | glyph = s->row->glyphs[s->area] + start; |
| 29394 | last = s->row->glyphs[s->area] + end; | 29395 | last = s->row->glyphs[s->area] + end; |
| 29396 | voffset = glyph->voffset; | ||
| 29395 | glyph_not_available_p = glyph->glyph_not_available_p; | 29397 | glyph_not_available_p = glyph->glyph_not_available_p; |
| 29396 | s->cmp_id = glyph->u.cmp.id; | 29398 | s->cmp_id = glyph->u.cmp.id; |
| 29397 | s->cmp_from = glyph->slice.cmp.from; | 29399 | s->cmp_from = glyph->slice.cmp.from; |
| @@ -29442,6 +29444,9 @@ fill_gstring_glyph_string (struct glyph_string *s, int face_id, | |||
| 29442 | if (glyph_not_available_p) | 29444 | if (glyph_not_available_p) |
| 29443 | s->font_not_found_p = true; | 29445 | s->font_not_found_p = true; |
| 29444 | 29446 | ||
| 29447 | /* Adjust base line for subscript/superscript text. */ | ||
| 29448 | s->ybase += voffset; | ||
| 29449 | |||
| 29445 | return glyph - s->row->glyphs[s->area]; | 29450 | return glyph - s->row->glyphs[s->area]; |
| 29446 | } | 29451 | } |
| 29447 | 29452 | ||