Skip to content

Commit b486528

Browse files
committed
remove unused code, #38414
1 parent 58e8d53 commit b486528

File tree

1 file changed

+0
-24
lines changed

1 file changed

+0
-24
lines changed

src/vs/base/common/filters.ts

-24
Original file line numberDiff line numberDiff line change
@@ -38,25 +38,6 @@ export function or(...filter: IFilter[]): IFilter {
3838
};
3939
}
4040

41-
/**
42-
* @returns A filter which combines the provided set
43-
* of filters with an and. The combines matches are
44-
* returned if *all* filters match.
45-
*/
46-
export function and(...filter: IFilter[]): IFilter {
47-
return function (word: string, wordToMatchAgainst: string): IMatch[] {
48-
let result: IMatch[] = [];
49-
for (let i = 0, len = filter.length; i < len; i++) {
50-
let match = filter[i](word, wordToMatchAgainst);
51-
if (!match) {
52-
return null;
53-
}
54-
result = result.concat(match);
55-
}
56-
return result;
57-
};
58-
}
59-
6041
// Prefix
6142

6243
export const matchesStrictPrefix: IFilter = _matchesPrefix.bind(undefined, false);
@@ -334,11 +315,6 @@ function nextWord(word: string, start: number): number {
334315

335316
// Fuzzy
336317

337-
export enum SubstringMatching {
338-
Contiguous,
339-
Separate
340-
}
341-
342318
export const fuzzyContiguousFilter = or(matchesPrefix, matchesCamelCase, matchesContiguousSubString);
343319
const fuzzySeparateFilter = or(matchesPrefix, matchesCamelCase, matchesSubString);
344320
const fuzzyRegExpCache = new BoundedMap<RegExp>(10000); // bounded to 10000 elements

0 commit comments

Comments
 (0)