Skip to content

Commit f587b54

Browse files
perf: Run async task in concurrent
1 parent dbd0b03 commit f587b54

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

editors/code/src/debug.ts

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -135,8 +135,10 @@ async function getDebugConfiguration(
135135
let sourceFileMap = debugOptions.sourceFileMap;
136136
if (sourceFileMap === "auto") {
137137
// let's try to use the default toolchain
138-
const commitHash = await getRustcId(wsFolder);
139-
const sysroot = await getSysroot(wsFolder);
138+
const [commitHash, sysroot] = await Promise.all([
139+
getRustcId(wsFolder),
140+
getSysroot(wsFolder),
141+
]);
140142
const rustlib = path.normalize(sysroot + "/lib/rustlib/src/rust");
141143
sourceFileMap = {};
142144
sourceFileMap[`/rustc/${commitHash}/`] = rustlib;

0 commit comments

Comments
 (0)