From d13300b0a129bb4f206523215dd0d45cea41722a Mon Sep 17 00:00:00 2001 From: jyviko <2501648+jyviko@users.noreply.github.com> Date: Tue, 27 Oct 2026 02:33:33 -0400 Subject: [PATCH] cargo fmt: the format-40 change and the rebase's export list Co-Authored-By: Claude Opus 5.5 --- crates/doc/src/lib.rs | 4 ++-- crates/engine/src/thread_tests.rs | 4 +--- crates/ui-egui/src/hole_presets.rs | 7 +++++-- 3 files changed, 8 insertions(+), 7 deletions(-) diff --git a/crates/doc/src/lib.rs b/crates/doc/src/lib.rs index 5b40e55b0..aa98c13dd 100644 --- a/crates/doc/src/lib.rs +++ b/crates/doc/src/lib.rs @@ -70,8 +70,8 @@ pub mod text_params; pub mod thread_forms; pub use assembly::{ - IDENTITY, MAX_PLACEMENT_DEPTH, MAX_PLACEMENTS, Mat, Occurrence, WorldNames, apply_point, apply_vector, is_identity, is_placement, - map_point_expr, mat_inverse, mat_mul, rigid, + IDENTITY, MAX_PLACEMENT_DEPTH, MAX_PLACEMENTS, Mat, Occurrence, WorldNames, apply_point, apply_vector, is_identity, is_placement, map_point_expr, + mat_inverse, mat_mul, rigid, }; pub use document::*; pub use eval::KeptResults; diff --git a/crates/engine/src/thread_tests.rs b/crates/engine/src/thread_tests.rs index 943023948..6183fea7e 100644 --- a/crates/engine/src/thread_tests.rs +++ b/crates/engine/src/thread_tests.rs @@ -720,9 +720,7 @@ fn a_format_39_left_hand_thread_and_tapped_hole_open_left_handed() { run(&mut s, "solid.hole", json!({"position": [20, 30, 12], "thread": "M6", "depth": 8, "hand": "left"})); run(&mut s, "solid.cylinder", json!({"radius": 5, "height": 9, "base": [80, 0, 0], "body_name": "Shaft", "operation": "new"})); run(&mut s, "solid.thread", json!({"face": [85, 0, 4.5], "designation": "M10", "hand": "left"})); - let hands = |s: &Session| -> Vec { - s.model.state().threads.iter().map(|t| t.hand).collect() - }; + let hands = |s: &Session| -> Vec { s.model.state().threads.iter().map(|t| t.hand).collect() }; let left = solidcraft_doc::thread_forms::ThreadHand::Left; assert_eq!(hands(&s), [left, left]); // What format 39 wrote: the direction as `handedness`, no pending changes. diff --git a/crates/ui-egui/src/hole_presets.rs b/crates/ui-egui/src/hole_presets.rs index 284695c50..dea428ac5 100644 --- a/crates/ui-egui/src/hole_presets.rs +++ b/crates/ui-egui/src/hole_presets.rs @@ -266,8 +266,11 @@ impl Preset { opts.thread.clone_from(&self.thread); opts.custom_thread = None; opts.thread_full_depth = self.thread_options.full_length; - opts.hand = - if self.thread_options.handedness == "left" { solidcraft_engine::doc::thread_forms::ThreadHand::Left } else { solidcraft_engine::doc::thread_forms::ThreadHand::Right }; + opts.hand = if self.thread_options.handedness == "left" { + solidcraft_engine::doc::thread_forms::ThreadHand::Left + } else { + solidcraft_engine::doc::thread_forms::ThreadHand::Right + }; opts.thread_depth = self.thread_options.depth.clone().unwrap_or_else(|| crate::dialogs::HoleOpts::default().thread_depth); // Existing placement picks stay with this dialog. To Object stores its mode only: // recalling it always asks for a fresh destination in the current design.