Ingo Karkat wrote:

> Hello Vim developers,
> 
> I just noticed a regression when using a custom command's complete
> function that is file-based. When I do :echo glob('dir/*/'), I expect
> the result to only include directories, because of the trailing "/" path
> separator (same when using "\" btw.), but in recent Windows builds, it
> also includes *all files*. For example, from the Vim repository root dir,
> I get:
> 
> ,----[ bad ]----
> | src\arabic.c\
> | src\arabic.h\
> | src\ascii.h\
> | src\auto\
> | src\bigvim.bat\
> | ...
> `----
> 
> instead of
> 
> ,----[ good ]----
> | src\auto\
> | ...
> `----
> 
> With this command:
> 
> src\vim.exe -N -u NONE -c "if len(glob('src/*/',0,1)) > 20 | cquit | else | 
> quit | endif"
> 
> I've bisected this problem to the following patch:
> 
> ,----[ bad change ]----
> | 7.3.1182  'backupcopy' default on MS-Windows does not work for links
> `----
> 
> I still see this in the latest 7.4.295 (HUGE build, using Make_mvc.mak
> with the Windows SDK 7.1 compiler) on Windows/x64. No problems on Linux.

Can you do some debugging to find out what part of that patch causes
this?  Perhaps one of the ways to expand a file name removes the
trailing slash?  Considering the output above, it looks like the slash
is added back afterwards, also after normal files.

-- 
hundred-and-one symptoms of being an internet addict:
189. You put your e-mail address in the upper left-hand corner of envelopes.

 /// Bram Moolenaar -- [email protected] -- http://www.Moolenaar.net   \\\
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\  an exciting new programming language -- http://www.Zimbu.org        ///
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///

-- 
-- 
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Raspunde prin e-mail lui