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

19166 Commits

Author SHA1 Message Date
Yegappan Lakshmanan
cc0bcf4c9f
patch 9.0.1883: Vim9: Calling an interface method using a child object fails
Problem:  Vim9: Calling an interface method using a child object fails
Solution: Search methods of parent class

When a class implementing an interface is extended by another class and
a child class instance is passed to a function that accepts the
interface, calling an interface method doesn't work properly.

closes: #13053

Signed-off-by: Christian Brabandt <cb@256bit.org>
Co-authored-by: Yegappan Lakshmanan <yegappan@yahoo.com>
2023-09-08 19:12:03 +02:00
Christian Brabandt
da200c2f78
patch 9.0.1882: Trailing white space in tests
Problem:  Trailing white space in tests
Solution: Delete it

This causes test_codestyle to fail, so we need to remove it again.
Hopefully that makes the CI green again.

Note: I will start using annotated tags from now on.

Signed-off-by: Christian Brabandt <cb@256bit.org>
2023-09-06 21:12:24 +02:00
Christian Brabandt
5856b07795
patch 9.0.1881: Test_crash fails on Mac
Problem:  Test_crash fails on Mac
Solution: Skip test on Mac

Signed-off-by: Christian Brabandt <cb@256bit.org>
2023-09-06 20:53:46 +02:00
Ernie Rael
cf138d4ea5
patch 9.0.1880: Vim9: Need more tests for inheritance
Problem:  Vim9: Need more tests for inheritance
Solution: Add access tests and fixes.

`inside_class` fix from yegappan. `object_index_from_itf_index` fix
access of member on class extending class implementing interface.

Based on tests from Vim9: Class/Object member variable access control #12979

closes: #13032
related: #12979

Signed-off-by: Christian Brabandt <cb@256bit.org>
Co-authored-by: Ernie Rael <errael@raelity.com>
Co-authored-by: Yegappan Lakshmanan <yegappan@yahoo.com>
2023-09-06 20:45:03 +02:00
Yegappan Lakshmanan
1689e847ff
patch 9.0.1879: Vim9: incorrect duplicate class member detection
Problem:  Vim9: incorrect duplicate class member detection
Solution: Incorrect duplicate class member detection when variable names
          have the same prefix.  Not able to access class member variables
          using an object. Fix coding style issues

closes: #13042

Signed-off-by: Christian Brabandt <cb@256bit.org>
Co-authored-by: Yegappan Lakshmanan <yegappan@yahoo.com>
2023-09-06 20:23:23 +02:00
Philip H
1690ec64ff
patch 9.0.1878: tests running sh have problems
Problem:  tests running sh have problems
Solution: Check that dash is installed

closes: #13040

Signed-off-by: Christian Brabandt <cb@256bit.org>
Co-authored-by: Philip H <47042125+pheiduck@users.noreply.github.com>
Co-authored-by: Christian Brabandt <cb@256bit.org>
2023-09-06 20:20:07 +02:00
Christian Brabandt
18d2709aa1
patch 9.0.1877: missing test for patch 9.0.1873
Problem:  missing test for patch 9.0.1873
Solution: add a test trying to exchange windows

Add a test, making sure that switching windows is not allowed when
textlock is active, e.g. when running `:s/<pat>/\=func()/`

Signed-off-by: Christian Brabandt <cb@256bit.org>
2023-09-06 20:02:27 +02:00
Christian Brabandt
00cb247465
patch 9.0.1876: Vim9: parsing commands with newlines wrong
Problem:  Vim9: parsing commands with newlines wrong
Solution: Accept a '\n' for parsing lists and command arguments

closes: #13015
closes: #13020

Signed-off-by: Christian Brabandt <cb@256bit.org>
2023-09-05 20:53:46 +02:00
Yegappan Lakshmanan
28a60f898d
patch 9.0.1875: Vim9: improve test for disassemble + static
Problem:  Vim9: improve test for disassemble + static
Solution: Add a Vim9 script disassemble test for an interface with
          static members
closes: #13037

Signed-off-by: Christian Brabandt <cb@256bit.org>
Co-authored-by: Yegappan Lakshmanan <yegappan@yahoo.com>
2023-09-05 20:44:32 +02:00
Christian Brabandt
1c7397f3f1
patch 9.0.1874: CI may fail in test_recover_empty_swap
Problem:  CI may fail in test_recover_empty_swap
Solution: Set directory option

Fix failing Test_recover_empty_swap test

:recover by default not only looks in the current directory, but also in
~/tmp for files to recover. If it finds some files to recover, it will
interactively prompt for a file to recover. However, prompting doesn't
work when running the test suite (and even if it would, there is no one
that can answer the prompt).

So it doesn't really make sense during testing, to inspect different
directories for swap files and prompt and wait (which will lead to a
timeout and therefore a failing test).

So set the 'directory' option temporarily to the current directory only
and reset it back once the test finishes.

closes: #13038

Signed-off-by: Christian Brabandt <cb@256bit.org>
2023-09-05 20:40:25 +02:00
Christian Brabandt
f6d28fe2c9
patch 9.0.1873: [security] heap-buffer-overflow in vim_regsub_both
Problem:  heap-buffer-overflow in vim_regsub_both
Solution: Disallow exchanging windows when textlock is active

Signed-off-by: Christian Brabandt <cb@256bit.org>
2023-09-05 20:18:06 +02:00
Christian Brabandt
d2a08ba0fa
patch 9.0.1872: CI: test_crash() fails on CI
Problem:  CI: test_crash() fails on CI
Solution: Skip test on BSD

Signed-off-by: Christian Brabandt <cb@256bit.org>
2023-09-05 07:45:04 +02:00
James McCoy
a4245a10ea
patch 9.0.1871: Github CI does not run i386 job
Problem:  Github CI does not run i386 job
Solution: Add a i386 architecture

Add CI testing for i386

message_test recently failed on i386, which exposed a gap in the CI
testing.  Convert the shadowdir job to one that runs on i386 so we get
32-bit test coverage.

Since the GHA runners are x86_64, we can enable the i386 architecture
in dpkg and install i386 packages for the i386 CI jobs.  However, this
can't currently be done with features=huge since that would require
installing python3-dev:i386, which breaks the CI environment.

closes: #12975

Signed-off-by: Christian Brabandt <cb@256bit.org>
Co-authored-by: James McCoy <jamessan@jamessan.com>
2023-09-05 07:41:23 +02:00
Ernie Rael
00df69e62b
patch 9.0.1870: Vim9: disassamble does not show static
Problem:  Vim9: disassamble does not show static
Solution: Show static flag

Fix disassemble for instructions with optional static:
ISN_GET_OBJ_MEMBER and ISN_GET_ITF_MEMBER

closes: #13030

Signed-off-by: Christian Brabandt <cb@256bit.org>
Co-authored-by: Ernie Rael <errael@raelity.com>
2023-09-05 07:39:14 +02:00
Ernie Rael
86eda07805
patch 9.0.1869: Coverity warns about unitialized var
Problem:  Coverity warns about unitialized var
Solution: initialize it

closes: #13029

Signed-off-by: Christian Brabandt <cb@256bit.org>
Co-authored-by: Ernie Rael <errael@raelity.com>
2023-09-05 07:33:48 +02:00
Christian Brabandt
59adcb4c20
patch 9.0.1868: test_crash still fails for circle ci
Problem:  test_crash still fails for circle ci
Solution: give even more time to complete

Signed-off-by: Christian Brabandt <cb@256bit.org>
2023-09-04 22:42:55 +02:00
Ivan Pešić
e4ba5df7c7
runtime(sr): Update Serbian messages translation
Signed-off-by: Christian Brabandt <cb@256bit.org>
2023-09-04 22:37:03 +02:00
Ernie Rael
18143d3111
patch 9.0.1867: Vim9: access to interface statics possible
Problem:  Vim9: access to interface statics possible
Solution: Prevent direct access to interface statics

closes: #13007

Signed-off-by: Christian Brabandt <cb@256bit.org>
Co-authored-by: Ernie Rael <errael@raelity.com>
2023-09-04 22:30:41 +02:00
zeertzjq
dccc29c228
patch 9.0.1866: undo is synced after character find
Problem:  Undo is synced after character find.
Solution: Set no_u_sync when calling gotchars_nop().

closes: #13022
closes: #13024

Signed-off-by: Christian Brabandt <cb@256bit.org>
Co-authored-by: zeertzjq <zeertzjq@outlook.com>
2023-09-04 22:25:07 +02:00
Yegappan Lakshmanan
544be0d893
patch 9.0.1865: Vim9: garbage collection may cause crash
Problem:  Vim9: garbage collection may cause crash
Solution: validate that class members typeval is not null

closes: #13028

Signed-off-by: Christian Brabandt <cb@256bit.org>
Co-authored-by: Yegappan Lakshmanan <yegappan@yahoo.com>
2023-09-04 22:14:28 +02:00
Christian Brabandt
623ba31821
patch 9.0.1864: still crash with bt_quickfix1_poc
Problem:  crash with bt_quickfix1_poc when cleaning up
          and EXITFREE is defined
Solution: Test if buffer is valid in a window, else close
          window directly, don't try to access buffer properties

While at it, increase the crash timeout slightly, so that CI has a
chance to finish processing the test_crash() test.

Signed-off-by: Christian Brabandt <cb@256bit.org>
2023-09-04 22:09:12 +02:00
zeertzjq
7db89bdc23
patch 9.0.1863: wrong format specifiers in e_aptypes_is_null_str_nr
Problem:  wrong format specifiers in e_aptypes_is_null_str_nr
Solution: Fix the wrong format specifier

closes: #13020

Signed-off-by: Christian Brabandt <cb@256bit.org>
Co-authored-by: zeertzjq <zeertzjq@outlook.com>
2023-09-04 07:54:02 +02:00
Yegappan Lakshmanan
e651e110c1
patch 9.0.1862: Vim9 Garbage Collection issues
Problem:  Vim9 Garbage Collection issues
Solution: Class members are garbage collected early leading to
          use-after-free problems.  Handle the garbage
          collection of classes properly.

closes: #13019

Signed-off-by: Christian Brabandt <cb@256bit.org>
Co-authored-by: Yegappan Lakshmanan <yegappan@yahoo.com>
2023-09-04 07:51:01 +02:00
K.Takata
233f956bd4
patch 9.0.1861: xxd: issue when -R is specified several times
Problem:  xxd: issue when -R is specified several times
Solution: Fix command line parsing

See: https://github.com/vim/vim/pull/12986#issuecomment-1704375892

closes: #13021

Signed-off-by: Christian Brabandt <cb@256bit.org>
Co-authored-by: K.Takata <kentkt@csc.jp>
Co-authored-by: Aapo Rantalainen <aapo.rantalainen@gmail.com>
2023-09-04 07:46:59 +02:00
Christian Brabandt
f44cbe96fa
patch 9.0.1860: CI: test_crash1() is flaky
Problem:  CI: test_crash1() is flaky
Solution: Wait a bit longer

Signed-off-by: Christian Brabandt <cb@256bit.org>
2023-09-04 07:42:27 +02:00
Christian Brabandt
6e60cf444a
patch 9.0.1859: heap-use-after-free in bt_normal()
Problem:  heap-use-after-free in bt_normal()
Solution: check that buffer is still valid

Signed-off-by: Christian Brabandt <cb@256bit.org>
2023-09-03 21:43:46 +02:00
Christian Brabandt
ee9166eb3b
patch 9.0.1858: [security] heap use after free in ins_compl_get_exp()
Problem:  heap use after free in ins_compl_get_exp()
Solution: validate buffer before accessing it

Signed-off-by: Christian Brabandt <cb@256bit.org>
2023-09-03 21:24:33 +02:00
Christian Brabandt
fc68299d43
patch 9.0.1857: [security] heap-use-after-free in is_qf_win()
Problem:  heap-use-after-free in is_qf_win()
Solution: Check buffer is valid before accessing it

Signed-off-by: Christian Brabandt <cb@256bit.org>
2023-09-03 20:20:52 +02:00
Christ van Willegen
aa90d4f031
patch 9.0.1856: issues with formatting positional arguments
Problem:  issues with formatting positional arguments
Solution: fix them, add tests and documentation

closes: #12140
closes: #12985

Signed-off-by: Christian Brabandt <cb@256bit.org>
Co-authored-by: Christ van Willegen <cvwillegen@gmail.com>
Tentatively fix message_test. Check NULL ptr.
2023-09-03 17:22:37 +02:00
h-east
71ebf3baca
patch 9.0.1855: mode() doesn't indicate command line for terminal
Problem:  mode() doesn't indicate command line for terminal
Solution: make it return 'ct' for command-line from Terminal mode

closes: #6265
closes: #13017
closes: #13018

Signed-off-by: Christian Brabandt <cb@256bit.org>
Co-authored-by: h-east <h.east.727@gmail.com>
2023-09-03 17:12:55 +02:00
Christian Brabandt
db510ca805
patch 9.0.1854: test_crash1() fails on CI
Problem:  test_crash1() fails on CI
Solution: don't run Screendump test, verify that it doesn't crash
          by running it through a shell command line, testing
          the exit value and concatenating success cmd using '&&'

Signed-off-by: Christian Brabandt <cb@256bit.org>
2023-09-03 09:30:09 +02:00
Christian Brabandt
15cbaae313
patch 9.0.1853: CI error on different signedness in regexp.c
Problem:  CI error on different signedness in regexp.c
          (after patch 9.0.1848)
Solution: Cast strlen() call to int

Signed-off-by: Christian Brabandt <cb@256bit.org>
2023-09-02 22:08:43 +02:00
pierreganty
d69aecf141
patch 9.0.1852: i_CTRL-O does not reset Select Mode
Problem:  i_CTRL-O does not reset Select Mode
Solution: Reset select mode on CTRL-O in insert mode

closes: #13001
closes: #12115

Signed-off-by: Christian Brabandt <cb@256bit.org>
Co-authored-by: Christian Brabandt <cb@256bit.org>
2023-09-02 21:59:52 +02:00
zeertzjq
3c3cf1d689
patch 9.0.1851: breakindent missing by virt text
Problem:  Virtual text at a column causes 'breakindent' and 'showbreak'
          to be missing (after patch 9.0.1124).
Solution: Add check for "tp_col" in another place where TP_FLAG_WRAP is
          checked.

closes: #12769
closes: #13008
closes: #13010

Signed-off-by: Christian Brabandt <cb@256bit.org>
Co-authored-by: zeertzjq <zeertzjq@outlook.com>
2023-09-02 21:55:00 +02:00
LemonBoy
32f3461465
patch 9.0.1850: Vim9: wrong line number where options set
Problem:  Vim9: wrong line number where options set
Solution: Set source line number earlier

closes: #13006
closes: #13013

Signed-off-by: Christian Brabandt <cb@256bit.org>
Co-authored-by: LemonBoy <thatlemon@gmail.com>
2023-09-02 21:52:05 +02:00
Christian Brabandt
c8a034210f
patch 9.0.1849: CI error on different signedness in ex_cmds.c
Problem:  CI error on different signedness
Solution: cast unsigned to int

Signed-off-by: Christian Brabandt <cb@256bit.org>
2023-09-02 21:50:10 +02:00
Christian Brabandt
ced2c7394a
patch 9.0.1848: [security] buffer-overflow in vim_regsub_both()
Problem:  buffer-overflow in vim_regsub_both()
Solution: Check remaining space

Signed-off-by: Christian Brabandt <cb@256bit.org>
2023-09-02 21:37:04 +02:00
Christian Brabandt
889f6af371
patch 9.0.1847: [security] potential oob write in do_addsub()
Problem:  potential oob write in do_addsub()
Solution: don't overflow buf2, check size in for loop()

Signed-off-by: Christian Brabandt <cb@256bit.org>
2023-09-02 19:43:33 +02:00
Christian Brabandt
4c6fe2e2ea
patch 9.0.1846: [security] crash in fullcommand
Problem:  crash in fullcommand
Solution: Check for typeval correctly

Signed-off-by: Christian Brabandt <cb@256bit.org>
2023-09-02 19:30:03 +02:00
Christian Brabandt
e0bfb7d301
patch 9.0.1845: xxd: Test_xxd_color start failing
Problem:  xxd: Test_xxd_color start failing
Solution: Revert changes to dump file

Signed-off-by: Christian Brabandt <cb@256bit.org>
2023-09-02 19:13:45 +02:00
Yee Cheng Chin
8b20203141
patch 9.0.1844: doc helptags may not be up to date
Problem:  doc helptags may not be up to date
Solution: Add CI jobs to verify helptags are updated

Also, re-generate the tags file with updated list so it will pass CI.

closes: #13012

Signed-off-by: Christian Brabandt <cb@256bit.org>
2023-09-02 16:04:50 +02:00
Christian Brabandt
b2422f7540
patch 9.0.1843: xxd color test flaky
Problem:  xxd color test flaky
Solution: Filter unneeded lines

Signed-off-by: Christian Brabandt <cb@256bit.org>
2023-09-02 16:01:18 +02:00
Ernie Rael
21d3212361
patch 9.0.1842: Need more accurate profiling
Problem:  Need more accurate profiling
Solution: Improve profiling results

closes: #12192

Reduce overhead of checking if a function should be profiled,
by caching results of checking (which are done with regexp).

Cache uf_hash for uf_name in ufunc_T.

Cache cleared when regexps are changed.

Break at first match for has_profiling lookup.

Signed-off-by: Christian Brabandt <cb@256bit.org>
Co-authored-by: Ernie Rael <errael@raelity.com>
2023-09-02 15:09:18 +02:00
Christian Brabandt
9d093fd056
patch 9.0.1841: style: trailing whitespace in ex_cmds.c
Problem:  style: trailing whitespace in ex_cmds.c
Solution: remove it

Signed-off-by: Christian Brabandt <cb@256bit.org>
2023-09-02 15:08:09 +02:00
Mike Williams
397e356d7b
translation(en_GB): Update UK English translation (#13011)
Signed-off-by: Christian Brabandt <cb@256bit.org>
2023-09-02 15:04:51 +02:00
Christian Brabandt
e1dc9a6275
patch 9.0.1840: [security] use-after-free in do_ecmd
Problem:  use-after-free in do_ecmd
Solution: Verify oldwin pointer after reset_VIsual()

Signed-off-by: Christian Brabandt <cb@256bit.org>
2023-09-02 14:44:47 +02:00
Christian Brabandt
738ce77aa9
patch 9.0.1839: No Makefile rule to build cscope database
Problem:  No Makefile rule to build cscope database
Solution: Add rule

Signed-off-by: Christian Brabandt <cb@256bit.org>
2023-09-01 22:38:26 +02:00
Antonio Giovanni Colombo
f3db141aed
translation(it): updated Italian translation + xxd manpage
Signed-off-by: Christian Brabandt <cb@256bit.org>
2023-09-01 22:19:37 +02:00
Yegappan Lakshmanan
3775f777a6
patch 9.0.1838: Vim9: Cannot modify class member vars from def function
Problem:  Vim9: Cannot modify class member vars from def function
Solution: Add support for modifying class member variables from a def
          function

closes: #12995

Signed-off-by: Christian Brabandt <cb@256bit.org>
Co-authored-by: Yegappan Lakshmanan <yegappan@yahoo.com>
2023-09-01 22:05:45 +02:00
Christian Brabandt
b147d31489
tests: Improve the codestyle test (#12988)
Improve it by the following:

1) Also check xxd source
2) Test_source_files():
   don't stop on the first error found, continue until the
   end of the file and report all found errors like this:

Signed-off-by: Christian Brabandt <cb@256bit.org>
2023-09-01 18:58:35 +02:00