Skip to content

Commit

Permalink
Adds single and double quotes to matching pairs (helix-editor#995)
Browse files Browse the repository at this point in the history
This enables `mm` to work on quote characters as well as highlighting of
matching quote when on it.
  • Loading branch information
EpocSquadron authored Nov 8, 2021
1 parent a252ecd commit 1e793c2
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion helix-core/src/match_brackets.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,13 @@
use crate::{Rope, Syntax};

const PAIRS: &[(char, char)] = &[('(', ')'), ('{', '}'), ('[', ']'), ('<', '>')];
const PAIRS: &[(char, char)] = &[
('(', ')'),
('{', '}'),
('[', ']'),
('<', '>'),
('\'', '\''),
('"', '"'),
];
// limit matching pairs to only ( ) { } [ ] < >

#[must_use]
Expand Down

0 comments on commit 1e793c2

Please sign in to comment.