diff --git a/components/compositing/webview_manager.rs b/components/compositing/webview_manager.rs index 201f9d1c5c5..544f90d489c 100644 --- a/components/compositing/webview_manager.rs +++ b/components/compositing/webview_manager.rs @@ -127,7 +127,7 @@ mod test { webviews: &WebViewManager, ) -> Vec<(WebViewId, WebView)> { let mut keys = webviews.webviews.keys().collect::>(); - keys.sort(); + keys.sort_unstable(); keys.iter() .map(|&id| (*id, webviews.webviews.get(id).cloned().unwrap())) .collect() diff --git a/components/constellation/constellation.rs b/components/constellation/constellation.rs index 1e6ea7d94e5..c979ec01c95 100644 --- a/components/constellation/constellation.rs +++ b/components/constellation/constellation.rs @@ -5401,7 +5401,7 @@ where }; // In order to get repeatability, we sort the pipeline ids. let mut pipeline_ids: Vec<&PipelineId> = self.pipelines.keys().collect(); - pipeline_ids.sort(); + pipeline_ids.sort_unstable(); if let Some((ref mut rng, probability)) = self.random_pipeline_closure { if let Some(pipeline_id) = pipeline_ids.choose(rng) { if let Some(pipeline) = self.pipelines.get(pipeline_id) { diff --git a/components/constellation/webview_manager.rs b/components/constellation/webview_manager.rs index 3421de5a52f..f6673977740 100644 --- a/components/constellation/webview_manager.rs +++ b/components/constellation/webview_manager.rs @@ -99,7 +99,7 @@ mod test { webviews: &WebViewManager, ) -> Vec<(WebViewId, WebView)> { let mut keys = webviews.webviews.keys().collect::>(); - keys.sort(); + keys.sort_unstable(); keys.iter() .map(|&id| { ( diff --git a/ports/servoshell/desktop/app.rs b/ports/servoshell/desktop/app.rs index c81ed0583f6..2e560fbe539 100644 --- a/ports/servoshell/desktop/app.rs +++ b/ports/servoshell/desktop/app.rs @@ -814,7 +814,7 @@ fn load_userscripts(userscripts_directory: Option<&Path>) -> std::io::Result, _>>()?; - files.sort(); + files.sort_unstable(); for file in files { userscripts.push(UserScript { script: std::fs::read_to_string(&file)?,