Skip to content

Commit 521f8ce

Browse files
committed
Improve handling of negated bracket expressions
1 parent ba61773 commit 521f8ce

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

‎src/IgnoreMatcher.vala‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,8 @@ namespace ValaLint {
6666
res.append ("]");
6767
} else if (c == '\\') {
6868
res.append ("\\\\");
69+
} else if (c == '!' && res.str.has_suffix ("[")) {
70+
res.append ("^");
6971
} else {
7072
res.append_c (c);
7173
}

0 commit comments

Comments
 (0)