0
0
mirror of https://github.com/vim/vim.git synced 2025-07-26 11:04:33 -04:00

139 Commits

Author SHA1 Message Date
Christian Brabandt
f2b16986a1
patch 9.1.1258: regexp: max \U and \%U value is limited by INT_MAX
Problem:  regexp: max \U and \%U value is limited by INT_MAX but gives a
          confusing error message (related: v8.1.0985).
Solution: give a better error message when the value reaches INT_MAX

When searching Vim allows to get up to 8 hex characters using the /\V
and /\%V regex atoms.  However, when using "/\UFFFFFFFF" the code point is
already above what an integer variable can hold, which is 2,147,483,647.

Since patch v8.1.0985, Vim already limited the max codepoint to INT_MAX
(otherwise it caused a crash in the nfa regex engine), but instead of
error'ing out it silently fell back to parse the number as a backslash
value and not as a codepoint value and as such this "/[\UFFFFFFFF]" will
happily find a "\" or an literal "F".  And this "/[\d127-\UFFFFFFFF]"
will error out as "reverse range in character class).

Interestingly, the max Unicode codepoint value is U+10FFFF which still
fits into an ordinary integer value,  which means, that we don't even
need to parse 8 hex characters, but 6 should have been enough.

However, let's not limit Vim to search for only max 6 hex characters
(which would be a backward incompatible change), but instead allow all 8
characters and only if the codepoint reaches INT_MAX, give a more
precise error message (about what the max unicode codepoint value is).
This allows to search for "[\U7FFFFFFE]" (will likely return "E486
Pattern not found") and "[/\U7FFFFFF]" now errors "E1517: Value too
large, max Unicode codepoint is U+10FFFF".

While this change is straight forward on architectures where long is 8
bytes, this is not so simple on Windows or 32bit architectures where long
is 4 bytes (and therefore the test fails there).  To account for that,
let's make use of the vimlong_T number type and make a few corresponding
changes in the regex engine code and cast the value to the expected data
type. This however may not work correctly on systems that doesn't have
the long long datatype (e.g. OpenVMS) and probably the test will fail
there.

fixes: #16949
closes: #16994

Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-03-29 09:08:58 +01:00
glepnir
8a63529a2f
patch 9.1.1230: inconsistent CTRL-C behaviour for popup windows
Problem:  Ctrl-C closes popup windows that have a filter callback,
          but does not close popups without a filter callback.
Solution: Modified popup_do_filter() to also close popups without
          filter callback when Ctrl-C is pressed (glepnir).

fixes: #16839
closes: #16928

Signed-off-by: glepnir <glephunter@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-03-21 18:12:32 +01:00
glepnir
5a04999a74
patch 9.1.0963: fuzzy-matching does not prefer full match
Problem:  fuzzy-matching does not prefer full match
          (Maxim Kim)
Solution: add additional score for a full match
          (glepnir)

fixes: #15654
closes: #16300

Signed-off-by: glepnir <glephunter@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2024-12-26 15:46:56 +01:00
h-east
624bb83619
runtime(doc): Tweak documentation style a bit
closes: #11419

Signed-off-by: h-east <h.east.727@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2024-11-09 18:37:32 +01:00
Maxim Kim
26de90c631
runtime(nohlsearch): include the the simple nohlsearch package
fixes: #15039
closes: #15042

Signed-off-by: Maxim Kim <habamax@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2024-06-18 19:32:39 +02:00
glepnir
a218cc6cda
patch 9.1.0463: no fuzzy-matching support for insert-completion
Problem:  no fuzzy-matching support for insert-completion
Solution: enable insert-mode completion with fuzzy-matching
          using :set completopt+=fuzzy (glepnir).

closes: #14878

Signed-off-by: glepnir <glephunter@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2024-06-03 19:46:13 +02:00
Philip H
9525f62136
runtime(doc): fix typo synconcealend -> synconcealed (#14644)
Signed-off-by: Philip H <47042125+pheiduck@users.noreply.github.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2024-04-26 19:57:20 +02:00
Christian Brabandt
fe1e2b5e2d
runtime(doc): clarify syntax vs matching mechanism
fixes: #14643

Signed-off-by: Christian Brabandt <cb@256bit.org>
2024-04-26 18:44:03 +02:00
Christian Brabandt
b4ddc6c11e
patch 9.1.0000: Vim 9.1 release
Problem:  Need a new release
Solution: Release Vim 9.1

Signed-off-by: Christian Brabandt <cb@256bit.org>
2024-01-02 16:51:11 +01:00
Ernie Rael
a5a1534753
runtime(doc): small updates to the documentation for varargs
- update and correct the documentation for varargs for Vim9 and make
  sure to mention that a <list> type is required.
- mention that 3match is used the matchparen plugin before 9.0.2054
  (actually this is not correct, but before that patch, Vim used the
  hardcoded id 3)

closes: #13403
closes: #13409

Signed-off-by: Christian Brabandt <cb@256bit.org>
Co-authored-by: Ernie Rael <errael@raelity.com>
2023-10-23 19:13:16 +02:00
Christian Brabandt
d3e277f279
matchparen: do not use hard-coded match id (#13393)
* matchparen: do not use hard-coded match id

Instead of using the hard-coded match id 3, which may also be used by
other plugins, let the matchparen plugin use whatever ids are
automatically returned when calling matchaddpos().

For backwards-compatibility, keep the `:3match` call, which will still
use the hard-coded id 3 (as mentioned in :h :3match).

closes: #13381

Signed-off-by: Christian Brabandt <cb@256bit.org>
2023-10-21 11:06:50 +02:00
h_east
ba77bbb5c7
runtime(doc): fix typos.
* Fix typo in document (Related: #12516)
* Fix E1363 duplication
* Fix one more typo.

Signed-off-by: Christian Brabandt <cb@256bit.org>
2023-10-02 21:47:13 +02:00
Bram Moolenaar
938ae280c7 Update runtime files. 2023-02-20 20:44:55 +00:00
Bram Moolenaar
9fbdbb814f Update runtime files 2022-09-27 17:30:34 +01:00
Bram Moolenaar
2ecbe53f45 Update runtime files 2022-07-29 21:36:21 +01:00
Bram Moolenaar
eb49041875 release version 9.0
Problem:    About time to release Vim 9.0.
Solution:   Update the version number everywhere.
2022-06-28 13:44:46 +01:00
Christian Brabandt
360da40b47 patch 8.2.4978: no error if engine selection atom is not at the start
Problem:    No error if engine selection atom is not at the start.
Solution:   Give an error. (Christian Brabandt, closes #10439)
2022-05-18 15:04:02 +01:00
Bram Moolenaar
1588bc8ebe Update runtime files 2022-03-08 21:35:07 +00:00
Bram Moolenaar
c51cf03298 Update runtime files. 2022-02-26 12:25:45 +00:00
Bram Moolenaar
a2baa73d1d Update runtime files. 2022-02-04 16:09:54 +00:00
Bram Moolenaar
2f0936cb9a Update runtime files 2022-01-08 21:51:59 +00:00
Bram Moolenaar
2286304cdb Update runtime files 2021-10-16 15:23:36 +01:00
Bram Moolenaar
53f7fccc94 Update runtime files 2021-07-28 20:10:16 +02:00
Bram Moolenaar
04db26b360 patch 8.2.3110: a pattern that matches the cursor position is complicated
Problem:    A pattern that matches the cursor position is bit complicated.
Solution:   Use a dot to indicate the cursor line and column. (Christian
            Brabandt, closes #8497, closes #8179)
2021-07-05 20:15:23 +02:00
Bram Moolenaar
2346a63784 Update runtime files 2021-06-13 19:02:49 +02:00
Bram Moolenaar
3ec3217f04 Update runtime files 2021-05-16 12:39:47 +02:00
Bram Moolenaar
9faec4e3d4 Update runtime files. 2021-02-27 16:38:07 +01:00
Bram Moolenaar
82be4849ee Update runtime files. 2021-01-11 19:40:15 +01:00
Bram Moolenaar
7e6a515ed1 Update runtime files. 2021-01-02 16:39:53 +01:00
Bram Moolenaar
1b884a0053 Update runtime files. 2020-12-10 21:11:27 +01:00
Bram Moolenaar
1c6737b20a Update runtime files. 2020-09-07 22:18:52 +02:00
Bram Moolenaar
207f009326 Update runtime files. 2020-08-30 17:20:20 +02:00
Bram Moolenaar
7ff78465f7 Update runtime files 2020-07-10 22:00:53 +02:00
Bram Moolenaar
5666fcd0bd Update runtime files. 2019-12-26 14:35:26 +01:00
Bram Moolenaar
98056533b9 Vim 8.2 release 2019-12-12 14:18:35 +01:00
Bram Moolenaar
664f3cf3f2 Runtime file updates. 2019-12-07 16:03:51 +01:00
Bram Moolenaar
68e6560b84 Update runtime files. 2019-05-26 21:33:31 +02:00
Bram Moolenaar
25c9c680ec patch 8.1.1280: remarks about functionality not in Vi clutters the help
Problem:    Remarks about functionality not in Vi clutters the help.
Solution:   Move all info about what is new in Vim or already existed in Vi to
            vi_diff.txt.  Remove {not in Vi} remarks. (closes #4268) Add
            "noet" to the help files modeline.  Also include many other help
            file improvements.
2019-05-05 18:13:34 +02:00
Bram Moolenaar
9dfa313919 patch 8.1.1270: cannot see current match position
Problem:    Cannot see current match position.
Solution:   Show "3/44" when using the "n" command and "S" is not in
            'shortmess'. (Christian Brabandt, closes #4317)
2019-05-04 21:08:40 +02:00
Bram Moolenaar
f6b401090e Update runtime files 2019-02-22 15:24:03 +01:00
Bram Moolenaar
4c92e75dd4 Update runtime files. 2019-02-17 21:18:32 +01:00
Bram Moolenaar
221cd9f4dd patch 8.1.0862: no verbose version of character classes
Problem:    No verbose version of character classes.
Solution:   Add [:ident:], [:keyword:] and [:fname:]. (Ozaki Kiichi,
            closes #1373)
2019-01-31 15:34:40 +01:00
Bram Moolenaar
c8c8849267 Update runtime files. 2018-12-27 23:59:26 +01:00
Bram Moolenaar
f0d58efc9d Update runtime files. 2018-11-16 16:13:44 +01:00
Bram Moolenaar
91f84f6e11 Update runtime files. 2018-07-29 15:07:52 +02:00
Bram Moolenaar
a9604e6145 Update runtime files. 2018-07-21 05:56:22 +02:00
Bram Moolenaar
b1c9198afb Vim 8.1 release
Update version number and information.  Fix a couple of tests.
2018-05-17 17:04:55 +02:00
Bram Moolenaar
98ef233e14 Update runtime files. Convert a couple of help files to utf-8. 2018-03-18 14:44:37 +01:00
Bram Moolenaar
7254067ee9 Update runtime files. 2018-02-09 22:00:53 +01:00
Bram Moolenaar
3ec574f2b5 Update runtime files.
Includes changing &sw to shiftwidth() for all indent scripts.
2017-06-13 18:12:01 +02:00