diff options
| author | Maxime Coste <mawww@kakoune.org> | 2017-01-02 04:03:02 +0000 |
|---|---|---|
| committer | Maxime Coste <mawww@kakoune.org> | 2017-01-02 04:03:02 +0000 |
| commit | ac1192f58ac6566f8889d13debdf53b31f1063ed (patch) | |
| tree | b5e61d4a260888b1f39a8739a91556ff827aec94 /src/normal.cc | |
| parent | 3c1f606a2202f0a60e8588c77202d7a81e1cc5b9 (diff) | |
Ensure <esc> cancels in replace with char
After recent changes that associated <esc> with the 0x1b codepoint
r<esc> would replace each char with 0x1b instead of canceling the
replace command.
Diffstat (limited to 'src/normal.cc')
| -rw-r--r-- | src/normal.cc | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/normal.cc b/src/normal.cc index e558fcf1..aa1e1174 100644 --- a/src/normal.cc +++ b/src/normal.cc @@ -307,7 +307,7 @@ void replace_with_char(Context& context, NormalParams) on_next_key_with_autoinfo(context, KeymapMode::None, [](Key key, Context& context) { auto cp = key.codepoint(); - if (not cp) + if (not cp or key == Key::Escape) return; ScopedEdition edition(context); Buffer& buffer = context.buffer(); |
