comparison src/testdir/test_method.vim @ 32417:3c2c1cb61004 v9.0.1540

patch 9.0.1540: reverse() on string doesn't work in compiled function Commit: https://github.com/vim/vim/commit/f9dc278946d52235a0025fd347bd9ff571258470 Author: Yegappan Lakshmanan <yegappan@yahoo.com> Date: Thu May 11 15:02:56 2023 +0100 patch 9.0.1540: reverse() on string doesn't work in compiled function Problem: reverse() on string doesn't work in compiled function. Solution: Accept string in argument type check. (Yegappan Lakshmanan, closes #12377)
author Bram Moolenaar <Bram@vim.org>
date Thu, 11 May 2023 16:15:08 +0200
parents dbec60b8c253
children 448aef880252
comparison
equal deleted inserted replaced
32416:06997bf5e6a8 32417:3c2c1cb61004
60 call assert_equal(3, d->max()) 60 call assert_equal(3, d->max())
61 call assert_equal(1, d->min()) 61 call assert_equal(1, d->min())
62 call assert_equal(2, d->remove("two")) 62 call assert_equal(2, d->remove("two"))
63 let d.two = 2 63 let d.two = 2
64 call assert_fails('let x = d->repeat(2)', 'E731:') 64 call assert_fails('let x = d->repeat(2)', 'E731:')
65 call assert_fails('let x = d->reverse()', 'E899:') 65 call assert_fails('let x = d->reverse()', 'E1252:')
66 call assert_fails('let x = d->sort()', 'E686:') 66 call assert_fails('let x = d->sort()', 'E686:')
67 call assert_equal("{'one': 1, 'two': 2, 'three': 3}", d->string()) 67 call assert_equal("{'one': 1, 'two': 2, 'three': 3}", d->string())
68 call assert_equal(v:t_dict, d->type()) 68 call assert_equal(v:t_dict, d->type())
69 call assert_fails('let x = d->uniq()', 'E686:') 69 call assert_fails('let x = d->uniq()', 'E686:')
70 call assert_equal([1, 2, 3], d->values()) 70 call assert_equal([1, 2, 3], d->values())