*** runtime/filetype.vim	2013-10-06 04:10:46.034012361 -0500
--- /tmp/filetype.vim	2013-10-06 04:08:52.430679003 -0500
***************
*** 2061,2068 ****
  " SVG (Scalable Vector Graphics)
  au BufNewFile,BufRead *.svg			setf svg
  
! " If the file has an extension of 't' and is in a directory 't' then it is
! " almost certainly a Perl test file.
  " If the first line starts with '#' and contains 'perl' it's probably a Perl
  " file.
  " (Slow test) If a file contains a 'use' statement then it is almost certainly
--- 2061,2068 ----
  " SVG (Scalable Vector Graphics)
  au BufNewFile,BufRead *.svg			setf svg
  
! " If the file has an extension of 't' and is in a directory 't' or a directory
! " 'xt' then it is almost certainly a Perl test file.
  " If the first line starts with '#' and contains 'perl' it's probably a Perl
  " file.
  " (Slow test) If a file contains a 'use' statement then it is almost certainly
***************
*** 2072,2077 ****
--- 2072,2081 ----
      setf perl
      return 1
    endif
+   if expand("%:e") == 't' && expand("%:p:h:t") == 'xt'
+     setf perl
+     return 1
+   endif
    if getline(1)[0] == '#' && getline(1) =~ 'perl'
      setf perl
      return 1
