src/vs/base/common/filters.ts/_matchesWords
function _matchesWords(word: string, target: string, i: number, j: number, contiguous: boolean): IMatch[] | null {
	if (i === word.length) {
		return [];
	} else if (j === target.length) {
		return null;
	} else if (!charactersMatch(word.charCodeAt(i), target.charCodeAt(j))) {
		return null;
	} else {
		let result: IMatch[] | null = null;
		let nextWordIndex = j + 1;
		result = _matchesWords(word, target, i + 1, j + 1, contiguous);
		if (!contiguous) {
			while (!result && (nextWordIndex = nextWord(target, nextWordIndex)) < target.length) {
				result = _matchesWords(word, target, i + 1, nextWordIndex, contiguous);
				nextWordIndex++;
			}
		}

		if (!result) {
			return null;
		}

		// If the characters don't exactly match, then they must be word separators (see charactersMatch(...)).
		// We don't want to include this in the matches but we don't want to throw the target out all together so we return `result`.
		if (word.charCodeAt(i) !== target.charCodeAt(j)) {
			return result;
		}

		return join({ start: j, end: j + 1 }, result);
	}
}