summaryrefslogtreecommitdiff
path: root/src/syntax.c
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2007-08-14 21:07:36 +0000
committerBram Moolenaar <Bram@vim.org>2007-08-14 21:07:36 +0000
commit349955a20596858c4b07f235f8102fd16774de3b (patch)
treebacb71a53008c12c4f0b65c471dea1cba4ad7d25 /src/syntax.c
parentb0db5699058946fa9ae6638a3b6c1fb039e8bd1f (diff)
downloadvim-git-349955a20596858c4b07f235f8102fd16774de3b.tar.gz
updated for version 7.1-077v7.1.077
Diffstat (limited to 'src/syntax.c')
-rw-r--r--src/syntax.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/syntax.c b/src/syntax.c
index c47a6026d..2cef9782c 100644
--- a/src/syntax.c
+++ b/src/syntax.c
@@ -1727,6 +1727,13 @@ get_syntax_attr(col, can_spell)
{
int attr = 0;
+ if (can_spell != NULL)
+ /* Default: Only do spelling when there is no @Spell cluster or when
+ * ":syn spell toplevel" was used. */
+ *can_spell = syn_buf->b_syn_spell == SYNSPL_DEFAULT
+ ? (syn_buf->b_spell_cluster_id == 0)
+ : (syn_buf->b_syn_spell == SYNSPL_TOP);
+
/* check for out of memory situation */
if (syn_buf->b_sst_array == NULL)
return 0;