diff options
author | Jan Edmund Lazo <jan.lazo@mail.utoronto.ca> | 2019-12-22 18:45:17 -0500 |
---|---|---|
committer | Jan Edmund Lazo <jan.lazo@mail.utoronto.ca> | 2019-12-22 19:43:18 -0500 |
commit | 80ebfc304e295cdb1bed3d0f2781d7884933719a (patch) | |
tree | 32158dcff76a1b976223c9cb387b52fc68599ba6 /src/nvim/window.c | |
parent | bc8da6cdbe4e300344e45dbc2eb5b22a7afc9e89 (diff) | |
download | rneovim-80ebfc304e295cdb1bed3d0f2781d7884933719a.tar.gz rneovim-80ebfc304e295cdb1bed3d0f2781d7884933719a.tar.bz2 rneovim-80ebfc304e295cdb1bed3d0f2781d7884933719a.zip |
vim-patch:8.2.0030: "gF" does not work on output of "verbose command"
Problem: "gF" does not work on output of "verbose command".
Solution: Recognize " line " and translations. (closes vim/vim#5391)
https://github.com/vim/vim/commit/64e74c9cc7d5aab215cf72d9bdd3aac32e128191
Diffstat (limited to 'src/nvim/window.c')
-rw-r--r-- | src/nvim/window.c | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/src/nvim/window.c b/src/nvim/window.c index 76fc36607c..af78c89618 100644 --- a/src/nvim/window.c +++ b/src/nvim/window.c @@ -6020,10 +6020,20 @@ file_name_in_line ( if (file_lnum != NULL) { char_u *p; + const char *line_english = " line "; + const char *line_transl = _(line_msg); // Get the number after the file name and a separator character. + // Also accept " line 999" with and without the same translation as + // used in last_set_msg(). p = ptr + len; - p = skipwhite(p); + if (STRNCMP(p, line_english, STRLEN(line_english)) == 0) { + p += STRLEN(line_english); + } else if (STRNCMP(p, line_transl, STRLEN(line_transl)) == 0) { + p += STRLEN(line_transl); + } else { + p = skipwhite(p); + } if (*p != NUL) { if (!isdigit(*p)) { p++; // skip the separator |