aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorzeertzjq <zeertzjq@outlook.com>2022-08-14 06:19:12 +0800
committerGitHub <noreply@github.com>2022-08-14 06:19:12 +0800
commitfa8fde99e6170af7ea08bf4db53cd9a464727ac8 (patch)
tree20537e7d42cdb58b7158e9a95b368393894cdffd /src
parent8cd116729fe2a15d62cd10e5ba7d3dcf1f677337 (diff)
downloadrneovim-fa8fde99e6170af7ea08bf4db53cd9a464727ac8.tar.gz
rneovim-fa8fde99e6170af7ea08bf4db53cd9a464727ac8.tar.bz2
rneovim-fa8fde99e6170af7ea08bf4db53cd9a464727ac8.zip
vim-patch:9.0.0203: confusing variable name (#19762)
Problem: Confusing variable name. Solution: Use "prim_aep" instead of "spell_aep". https://github.com/vim/vim/commit/c9b6570fab46bf2c246a954cfb8c0d95fe2746b3
Diffstat (limited to 'src')
-rw-r--r--src/nvim/highlight.c46
1 files changed, 23 insertions, 23 deletions
diff --git a/src/nvim/highlight.c b/src/nvim/highlight.c
index 71c7194479..dfd077840e 100644
--- a/src/nvim/highlight.c
+++ b/src/nvim/highlight.c
@@ -437,52 +437,52 @@ int hl_combine_attr(int char_attr, int prim_attr)
}
HlAttrs char_aep = syn_attr2entry(char_attr);
- HlAttrs spell_aep = syn_attr2entry(prim_attr);
+ HlAttrs prim_aep = syn_attr2entry(prim_attr);
// start with low-priority attribute, and override colors if present below.
HlAttrs new_en = char_aep;
- if (spell_aep.cterm_ae_attr & HL_NOCOMBINE) {
- new_en.cterm_ae_attr = spell_aep.cterm_ae_attr;
+ if (prim_aep.cterm_ae_attr & HL_NOCOMBINE) {
+ new_en.cterm_ae_attr = prim_aep.cterm_ae_attr;
} else {
- new_en.cterm_ae_attr |= spell_aep.cterm_ae_attr;
+ new_en.cterm_ae_attr |= prim_aep.cterm_ae_attr;
}
- if (spell_aep.rgb_ae_attr & HL_NOCOMBINE) {
- new_en.rgb_ae_attr = spell_aep.rgb_ae_attr;
+ if (prim_aep.rgb_ae_attr & HL_NOCOMBINE) {
+ new_en.rgb_ae_attr = prim_aep.rgb_ae_attr;
} else {
- new_en.rgb_ae_attr |= spell_aep.rgb_ae_attr;
+ new_en.rgb_ae_attr |= prim_aep.rgb_ae_attr;
}
- if (spell_aep.cterm_fg_color > 0) {
- new_en.cterm_fg_color = spell_aep.cterm_fg_color;
+ if (prim_aep.cterm_fg_color > 0) {
+ new_en.cterm_fg_color = prim_aep.cterm_fg_color;
new_en.rgb_ae_attr &= ((~HL_FG_INDEXED)
- | (spell_aep.rgb_ae_attr & HL_FG_INDEXED));
+ | (prim_aep.rgb_ae_attr & HL_FG_INDEXED));
}
- if (spell_aep.cterm_bg_color > 0) {
- new_en.cterm_bg_color = spell_aep.cterm_bg_color;
+ if (prim_aep.cterm_bg_color > 0) {
+ new_en.cterm_bg_color = prim_aep.cterm_bg_color;
new_en.rgb_ae_attr &= ((~HL_BG_INDEXED)
- | (spell_aep.rgb_ae_attr & HL_BG_INDEXED));
+ | (prim_aep.rgb_ae_attr & HL_BG_INDEXED));
}
- if (spell_aep.rgb_fg_color >= 0) {
- new_en.rgb_fg_color = spell_aep.rgb_fg_color;
+ if (prim_aep.rgb_fg_color >= 0) {
+ new_en.rgb_fg_color = prim_aep.rgb_fg_color;
new_en.rgb_ae_attr &= ((~HL_FG_INDEXED)
- | (spell_aep.rgb_ae_attr & HL_FG_INDEXED));
+ | (prim_aep.rgb_ae_attr & HL_FG_INDEXED));
}
- if (spell_aep.rgb_bg_color >= 0) {
- new_en.rgb_bg_color = spell_aep.rgb_bg_color;
+ if (prim_aep.rgb_bg_color >= 0) {
+ new_en.rgb_bg_color = prim_aep.rgb_bg_color;
new_en.rgb_ae_attr &= ((~HL_BG_INDEXED)
- | (spell_aep.rgb_ae_attr & HL_BG_INDEXED));
+ | (prim_aep.rgb_ae_attr & HL_BG_INDEXED));
}
- if (spell_aep.rgb_sp_color >= 0) {
- new_en.rgb_sp_color = spell_aep.rgb_sp_color;
+ if (prim_aep.rgb_sp_color >= 0) {
+ new_en.rgb_sp_color = prim_aep.rgb_sp_color;
}
- if (spell_aep.hl_blend >= 0) {
- new_en.hl_blend = spell_aep.hl_blend;
+ if (prim_aep.hl_blend >= 0) {
+ new_en.hl_blend = prim_aep.hl_blend;
}
id = get_attr_entry((HlEntry){ .attr = new_en, .kind = kHlCombine,