diff options
author | ridiculousfish <corydoras@ridiculousfish.com> | 2015-08-03 16:36:10 -0700 |
---|---|---|
committer | ridiculousfish <corydoras@ridiculousfish.com> | 2015-08-08 13:55:50 -0700 |
commit | 602e9cebd9b3d8feb80c338d80bce570077239ba (patch) | |
tree | 1aeb0779d9aab086c891f822117abf7ad64b4fc9 /src/wildcard.cpp | |
parent | d2049edcab6b2046b7e3e01b4a48f2e13f2aa878 (diff) |
rename FOR_COMPLETIONS to EXPAND_FOR_COMPLETIONS
This is yet clearer
Diffstat (limited to 'src/wildcard.cpp')
-rw-r--r-- | src/wildcard.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/wildcard.cpp b/src/wildcard.cpp index 66318546..795423a8 100644 --- a/src/wildcard.cpp +++ b/src/wildcard.cpp @@ -769,7 +769,7 @@ void wildcard_expander_t::expand_trailing_slash(const wcstring &base_dir) return; } - if (! (flags & FOR_COMPLETIONS)) + if (! (flags & EXPAND_FOR_COMPLETIONS)) { /* Trailing slash and not accepting incomplete, e.g. `echo /tmp/`. Insert this file if it exists. */ if (waccess(base_dir, F_OK)) @@ -840,7 +840,7 @@ void wildcard_expander_t::expand_last_segment(const wcstring &base_dir, DIR *bas wcstring name_str; while (wreaddir(base_dir_fp, name_str)) { - if (flags & FOR_COMPLETIONS) + if (flags & EXPAND_FOR_COMPLETIONS) { /* Test for matches before stating file, so as to minimize the number of calls to the much slower stat function. The only expand flag we care about is EXPAND_FUZZY_MATCH; we have no complete flags. */ std::vector<completion_t> local_matches; @@ -1018,7 +1018,7 @@ static int wildcard_expand_internal(const wchar_t *wc, const size_t base_dir_len = wcslen(base_dir); const size_t wc_len = wcslen(wc); - if (flags & FOR_COMPLETIONS) + if (flags & EXPAND_FOR_COMPLETIONS) { /* Avoid excessive number of returned matches for wc ending with a * @@ -1083,7 +1083,7 @@ static int wildcard_expand_internal(const wchar_t *wc, The last wildcard segment is empty. Insert everything if completing, the directory itself otherwise. */ - if (flags & FOR_COMPLETIONS) + if (flags & EXPAND_FOR_COMPLETIONS) { wcstring next; while (wreaddir(dir, next)) @@ -1111,7 +1111,7 @@ static int wildcard_expand_internal(const wchar_t *wc, wcstring name_str; while (wreaddir(dir, name_str)) { - if (flags & FOR_COMPLETIONS) + if (flags & EXPAND_FOR_COMPLETIONS) { const wcstring long_name = make_path(base_dir, name_str); @@ -1296,7 +1296,7 @@ static int wildcard_expand(const wchar_t *wc, wildcard_expander_t expander(flags, out); expander.expand(base_dir, wc); - if (flags & FOR_COMPLETIONS) + if (flags & EXPAND_FOR_COMPLETIONS) { wcstring wc_base; const wchar_t *wc_base_ptr = wcsrchr(wc, L'/'); |