patch 7.4.2244
Problem:    Adding pattern to ":oldfiles" is not a generic solution.
Solution:   Add the ":filter /pat/ cmd" command modifier.  Only works for some
            commands right now.
diff --git a/src/testdir/test_alot.vim b/src/testdir/test_alot.vim
index b89d4b0..f8804e0 100644
--- a/src/testdir/test_alot.vim
+++ b/src/testdir/test_alot.vim
@@ -13,6 +13,7 @@
 source test_feedkeys.vim
 source test_fnamemodify.vim
 source test_file_perm.vim
+source test_filter_cmd.vim
 source test_filter_map.vim
 source test_glob2regpat.vim
 source test_goto.vim
diff --git a/src/testdir/test_filter_cmd.vim b/src/testdir/test_filter_cmd.vim
new file mode 100644
index 0000000..f85a11c
--- /dev/null
+++ b/src/testdir/test_filter_cmd.vim
@@ -0,0 +1,15 @@
+" Test the :filter command modifier
+
+func Test_filter()
+  edit Xdoesnotmatch
+  edit Xwillmatch
+  call assert_equal('"Xwillmatch"', substitute(execute('filter willma ls'), '[^"]*\(".*"\)[^"]*', '\1', ''))
+endfunc
+
+func Test_filter_fails()
+  call assert_fails('filter', 'E471:')
+  call assert_fails('filter pat', 'E476:')
+  call assert_fails('filter /pat', 'E476:')
+  call assert_fails('filter /pat/', 'E476:')
+  call assert_fails('filter /pat/ asdf', 'E492:')
+endfunc
diff --git a/src/testdir/test_viminfo.vim b/src/testdir/test_viminfo.vim
index d4ec6f7..264baa1 100644
--- a/src/testdir/test_viminfo.vim
+++ b/src/testdir/test_viminfo.vim
@@ -476,7 +476,7 @@
   rviminfo! Xviminfo
   call delete('Xviminfo')
 
-  call assert_equal(['1: /tmp/file_one.txt', '2: /tmp/file_two.txt', '3: /tmp/another.txt'], filter(split(execute('oldfile'), "\n"), {i, v -> v =~ '/tmp/'}))
-  call assert_equal(['1: /tmp/file_one.txt', '2: /tmp/file_two.txt'], filter(split(execute('oldfile file_'), "\n"), {i, v -> v =~ '/tmp/'}))
-  call assert_equal(['3: /tmp/another.txt'], filter(split(execute('oldfile /another/'), "\n"), {i, v -> v =~ '/tmp/'}))
+  call assert_equal(['1: /tmp/file_one.txt', '2: /tmp/file_two.txt', '3: /tmp/another.txt'], filter(split(execute('oldfiles'), "\n"), {i, v -> v =~ '/tmp/'}))
+  call assert_equal(['1: /tmp/file_one.txt', '2: /tmp/file_two.txt'], filter(split(execute('filter file_ oldfiles'), "\n"), {i, v -> v =~ '/tmp/'}))
+  call assert_equal(['3: /tmp/another.txt'], filter(split(execute('filter /another/ oldfiles'), "\n"), {i, v -> v =~ '/tmp/'}))
 endfunc