src/vs/base/browser/ui/tree/indexTreeModel.ts/IndexTreeModel/getLastElementAncestor
class IndexTreeModel:	getLastElementAncestor(location: number[] = []): T | undefined {
		const node = this.getTreeNode(location);

		if (node.children.length === 0) {
			return undefined;
		}

		return this._getLastElementAncestor(node);
	}