Mercurial > vim
comparison src/ex_getln.c @ 3398:d1096a4e96bd v7.3.465
updated for version 7.3.465
Problem: Cannot get file name with newline from glob().
Solution: Add argument to glob() and expand() to indicate they must return a
list. (Christian Brabandt)
author | Bram Moolenaar <bram@vim.org> |
---|---|
date | Wed, 07 Mar 2012 19:18:23 +0100 |
parents | 791baa7b35e1 |
children | 7e4428115d2c |
comparison
equal
deleted
inserted
replaced
3397:5077b4eb0d61 | 3398:d1096a4e96bd |
---|---|
3459 * mode = WILD_EXPAND_KEEP: normal expansion, keep matches | 3459 * mode = WILD_EXPAND_KEEP: normal expansion, keep matches |
3460 * mode = WILD_NEXT: use next match in multiple match, wrap to first | 3460 * mode = WILD_NEXT: use next match in multiple match, wrap to first |
3461 * mode = WILD_PREV: use previous match in multiple match, wrap to first | 3461 * mode = WILD_PREV: use previous match in multiple match, wrap to first |
3462 * mode = WILD_ALL: return all matches concatenated | 3462 * mode = WILD_ALL: return all matches concatenated |
3463 * mode = WILD_LONGEST: return longest matched part | 3463 * mode = WILD_LONGEST: return longest matched part |
3464 * mode = WILD_ALL_KEEP: get all matches, keep matches | |
3464 * | 3465 * |
3465 * options = WILD_LIST_NOTFOUND: list entries without a match | 3466 * options = WILD_LIST_NOTFOUND: list entries without a match |
3466 * options = WILD_HOME_REPLACE: do home_replace() for buffer names | 3467 * options = WILD_HOME_REPLACE: do home_replace() for buffer names |
3467 * options = WILD_USE_NL: Use '\n' for WILD_ALL | 3468 * options = WILD_USE_NL: Use '\n' for WILD_ALL |
3468 * options = WILD_NO_BEEP: Don't beep for multiple matches | 3469 * options = WILD_NO_BEEP: Don't beep for multiple matches |
3582 ExpandEscape(xp, str, xp->xp_numfiles, xp->xp_files, options); | 3583 ExpandEscape(xp, str, xp->xp_numfiles, xp->xp_files, options); |
3583 | 3584 |
3584 /* | 3585 /* |
3585 * Check for matching suffixes in file names. | 3586 * Check for matching suffixes in file names. |
3586 */ | 3587 */ |
3587 if (mode != WILD_ALL && mode != WILD_LONGEST) | 3588 if (mode != WILD_ALL && mode != WILD_ALL_KEEP |
3589 && mode != WILD_LONGEST) | |
3588 { | 3590 { |
3589 if (xp->xp_numfiles) | 3591 if (xp->xp_numfiles) |
3590 non_suf_match = xp->xp_numfiles; | 3592 non_suf_match = xp->xp_numfiles; |
3591 else | 3593 else |
3592 non_suf_match = 1; | 3594 non_suf_match = 1; |