patch 8.1.1925: more functions can be used as methods
Problem: More functions can be used as methods.
Solution: Make various functions usable as a method.
diff --git a/src/testdir/test_stat.vim b/src/testdir/test_stat.vim
index e48e887..8ec2a42 100644
--- a/src/testdir/test_stat.vim
+++ b/src/testdir/test_stat.vim
@@ -10,7 +10,7 @@
let fl = ['Hello World!']
for fname in fnames
call writefile(fl, fname)
- call add(times, getftime(fname))
+ call add(times, fname->getftime())
if a:doSleep
sleep 1
endif
@@ -19,8 +19,8 @@
let time_correct = (times[0] <= times[1] && times[1] <= times[2])
if a:doSleep || time_correct
call assert_true(time_correct, printf('Expected %s <= %s <= %s', times[0], times[1], times[2]))
- call assert_equal(strlen(fl[0] . "\n"), getfsize(fnames[0]))
- call assert_equal('file', getftype(fnames[0]))
+ call assert_equal(strlen(fl[0] . "\n"), fnames[0]->getfsize())
+ call assert_equal('file', fnames[0]->getftype())
call assert_equal('rw-', getfperm(fnames[0])[0:2])
let result = 1
endif