extensions/markdown-language-features/src/commands/openDocumentLink.ts/OpenDocumentLinkCommand/tryOpen
class OpenDocumentLinkCommand:	private static async tryOpen(engine: MarkdownEngine, resource: vscode.Uri, args: OpenDocumentLinkArgs, column: vscode.ViewColumn): Promise<boolean> {
		const tryUpdateForActiveFile = async (): Promise<boolean> => {
			if (vscode.window.activeTextEditor && isMarkdownFile(vscode.window.activeTextEditor.document)) {
				if (vscode.window.activeTextEditor.document.uri.fsPath === resource.fsPath) {
					await this.tryRevealLine(engine, vscode.window.activeTextEditor, args.fragment);
					return true;
				}
			}
			return false;
		};

		if (await tryUpdateForActiveFile()) {
			return true;
		}

		let stat: vscode.FileStat;
		try {
			stat = await vscode.workspace.fs.stat(resource);
		} catch {
			return false;
		}

		if (stat.type === vscode.FileType.Directory) {
			await vscode.commands.executeCommand('revealInExplorer', resource);
			return true;
		}

		try {
			await vscode.commands.executeCommand('vscode.open', resource, column);
		} catch {
			return false;
		}

		return tryUpdateForActiveFile();
	}