summaryrefslogtreecommitdiff
path: root/cli/tools/bench/mod.rs
diff options
context:
space:
mode:
authorDavid Sherret <dsherret@users.noreply.github.com>2024-06-05 11:04:16 -0400
committerGitHub <noreply@github.com>2024-06-05 17:04:16 +0200
commit7ed90a20d04982ae15a52ae2378cbffd4b6839df (patch)
tree3297d6f7227fbf1cf80e17a2a376ef4dfa52e6ad /cli/tools/bench/mod.rs
parent0544d60012006b1c7799d8b6eafacec9567901ad (diff)
fix: better handling of npm resolution occurring on workers (#24094)
Closes https://github.com/denoland/deno/issues/24063
Diffstat (limited to 'cli/tools/bench/mod.rs')
-rw-r--r--cli/tools/bench/mod.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/cli/tools/bench/mod.rs b/cli/tools/bench/mod.rs
index dd94205cb..a6c8d3e16 100644
--- a/cli/tools/bench/mod.rs
+++ b/cli/tools/bench/mod.rs
@@ -506,14 +506,14 @@ pub async fn run_benchmarks_with_watch(
let bench_modules_to_reload = if let Some(changed_paths) = changed_paths
{
let changed_paths = changed_paths.into_iter().collect::<HashSet<_>>();
- let mut result = Vec::new();
+ let mut result = IndexSet::with_capacity(bench_modules.len());
for bench_module_specifier in bench_modules {
if has_graph_root_local_dependent_changed(
&graph,
bench_module_specifier,
&changed_paths,
) {
- result.push(bench_module_specifier.clone());
+ result.insert(bench_module_specifier.clone());
}
}
result