Mercurial > vim
comparison src/highlight.c @ 18251:c8a53c0daeed v8.1.2120
patch 8.1.2120: some MB_ macros are more complicated than necessary
Commit: https://github.com/vim/vim/commit/1614a14901558ca091329315d14a7d5e1b53aa47
Author: Bram Moolenaar <Bram@vim.org>
Date: Sun Oct 6 22:00:13 2019 +0200
patch 8.1.2120: some MB_ macros are more complicated than necessary
Problem: Some MB_ macros are more complicated than necessary. (Dominique
Pelle)
Solution: Simplify the macros. Expand inline.
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Sun, 06 Oct 2019 22:15:04 +0200 |
parents | 1101eacc1444 |
children | 506bf60a30a0 |
comparison
equal
deleted
inserted
replaced
18250:f1d9d3f76c98 | 18251:c8a53c0daeed |
---|---|
4390 { | 4390 { |
4391 if (shl->startcol != MAXCOL | 4391 if (shl->startcol != MAXCOL |
4392 && col >= shl->startcol | 4392 && col >= shl->startcol |
4393 && col < shl->endcol) | 4393 && col < shl->endcol) |
4394 { | 4394 { |
4395 int next_col = col + MB_PTR2LEN(*line + col); | 4395 int next_col = col + mb_ptr2len(*line + col); |
4396 | 4396 |
4397 if (shl->endcol < next_col) | 4397 if (shl->endcol < next_col) |
4398 shl->endcol = next_col; | 4398 shl->endcol = next_col; |
4399 shl->attr_cur = shl->attr; | 4399 shl->attr_cur = shl->attr; |
4400 # ifdef FEAT_CONCEAL | 4400 # ifdef FEAT_CONCEAL |