From 436e4f1cf4364f59c87fb45f34731726969400c1 Mon Sep 17 00:00:00 2001 From: Emil Ernerfeldt Date: Thu, 25 Apr 2024 14:11:44 +0200 Subject: [PATCH 1/8] Update to Rust 1.74 Motivation: I want to replace `cargo-cranky` with workspace lints. --- .github/workflows/deploy_web_demo.yml | 2 +- .github/workflows/rust.yml | 10 +++++----- Cargo.toml | 2 +- clippy.toml | 2 +- examples/confirm_exit/Cargo.toml | 2 +- examples/custom_3d_glow/Cargo.toml | 2 +- examples/custom_font/Cargo.toml | 2 +- examples/custom_font_style/Cargo.toml | 2 +- examples/custom_keypad/Cargo.toml | 2 +- examples/custom_plot_manipulation/Cargo.toml | 2 +- examples/custom_window_frame/Cargo.toml | 2 +- examples/file_dialog/Cargo.toml | 2 +- examples/hello_world/Cargo.toml | 2 +- examples/hello_world_par/Cargo.toml | 2 +- examples/hello_world_simple/Cargo.toml | 2 +- examples/images/Cargo.toml | 2 +- examples/keyboard_events/Cargo.toml | 2 +- examples/multiple_viewports/Cargo.toml | 2 +- examples/puffin_profiler/Cargo.toml | 2 +- examples/save_plot/Cargo.toml | 2 +- examples/screenshot/Cargo.toml | 2 +- examples/serial_windows/Cargo.toml | 2 +- examples/test_inline_glow_paint/Cargo.toml | 2 +- examples/test_viewports/Cargo.toml | 2 +- examples/user_attention/Cargo.toml | 2 +- rust-toolchain | 2 +- scripts/clippy_wasm/clippy.toml | 2 +- 27 files changed, 31 insertions(+), 31 deletions(-) diff --git a/.github/workflows/deploy_web_demo.yml b/.github/workflows/deploy_web_demo.yml index ea2956db313..5928653ae96 100644 --- a/.github/workflows/deploy_web_demo.yml +++ b/.github/workflows/deploy_web_demo.yml @@ -43,7 +43,7 @@ jobs: with: profile: minimal target: wasm32-unknown-unknown - toolchain: 1.72.0 + toolchain: 1.74.0 override: true - uses: Swatinem/rust-cache@v2 diff --git a/.github/workflows/rust.yml b/.github/workflows/rust.yml index d641b17b284..0576f174f8d 100644 --- a/.github/workflows/rust.yml +++ b/.github/workflows/rust.yml @@ -19,7 +19,7 @@ jobs: - uses: dtolnay/rust-toolchain@master with: - toolchain: 1.72.0 + toolchain: 1.74.0 - name: Install packages (Linux) if: runner.os == 'Linux' @@ -93,7 +93,7 @@ jobs: - uses: actions/checkout@v4 - uses: dtolnay/rust-toolchain@master with: - toolchain: 1.72.0 + toolchain: 1.74.0 targets: wasm32-unknown-unknown - run: sudo apt-get update && sudo apt-get install libgtk-3-dev libatk1.0-dev @@ -151,7 +151,7 @@ jobs: - uses: actions/checkout@v4 - uses: EmbarkStudios/cargo-deny-action@v1 with: - rust-version: "1.72.0" + rust-version: "1.74.0" log-level: error command: check arguments: --target ${{ matrix.target }} @@ -166,7 +166,7 @@ jobs: - uses: dtolnay/rust-toolchain@master with: - toolchain: 1.72.0 + toolchain: 1.74.0 targets: aarch64-linux-android - name: Set up cargo cache @@ -184,7 +184,7 @@ jobs: - uses: actions/checkout@v4 - uses: dtolnay/rust-toolchain@master with: - toolchain: 1.72.0 + toolchain: 1.74.0 - name: Set up cargo cache uses: Swatinem/rust-cache@v2 diff --git a/Cargo.toml b/Cargo.toml index 425eb8de208..a3e24c94024 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -21,7 +21,7 @@ members = [ [workspace.package] edition = "2021" license = "MIT OR Apache-2.0" -rust-version = "1.72" +rust-version = "1.74" version = "0.27.2" diff --git a/clippy.toml b/clippy.toml index 93d7874068e..e11e2505661 100644 --- a/clippy.toml +++ b/clippy.toml @@ -3,7 +3,7 @@ # ----------------------------------------------------------------------------- # Section identical to scripts/clippy_wasm/clippy.toml: -msrv = "1.72" +msrv = "1.74" allow-unwrap-in-tests = true diff --git a/examples/confirm_exit/Cargo.toml b/examples/confirm_exit/Cargo.toml index 09ad2c4f606..0c9566b9411 100644 --- a/examples/confirm_exit/Cargo.toml +++ b/examples/confirm_exit/Cargo.toml @@ -4,7 +4,7 @@ version = "0.1.0" authors = ["Emil Ernerfeldt "] license = "MIT OR Apache-2.0" edition = "2021" -rust-version = "1.72" +rust-version = "1.74" publish = false diff --git a/examples/custom_3d_glow/Cargo.toml b/examples/custom_3d_glow/Cargo.toml index d7e70401a47..41d550a0c4e 100644 --- a/examples/custom_3d_glow/Cargo.toml +++ b/examples/custom_3d_glow/Cargo.toml @@ -4,7 +4,7 @@ version = "0.1.0" authors = ["Emil Ernerfeldt "] license = "MIT OR Apache-2.0" edition = "2021" -rust-version = "1.72" +rust-version = "1.74" publish = false diff --git a/examples/custom_font/Cargo.toml b/examples/custom_font/Cargo.toml index db633431531..a4e228f9b22 100644 --- a/examples/custom_font/Cargo.toml +++ b/examples/custom_font/Cargo.toml @@ -4,7 +4,7 @@ version = "0.1.0" authors = ["Emil Ernerfeldt "] license = "MIT OR Apache-2.0" edition = "2021" -rust-version = "1.72" +rust-version = "1.74" publish = false diff --git a/examples/custom_font_style/Cargo.toml b/examples/custom_font_style/Cargo.toml index 51990ee919d..d7a7b1c0eac 100644 --- a/examples/custom_font_style/Cargo.toml +++ b/examples/custom_font_style/Cargo.toml @@ -4,7 +4,7 @@ version = "0.1.0" authors = ["tami5 "] license = "MIT OR Apache-2.0" edition = "2021" -rust-version = "1.72" +rust-version = "1.74" publish = false diff --git a/examples/custom_keypad/Cargo.toml b/examples/custom_keypad/Cargo.toml index 1557b35c86c..252a3b26bcf 100644 --- a/examples/custom_keypad/Cargo.toml +++ b/examples/custom_keypad/Cargo.toml @@ -4,7 +4,7 @@ version = "0.1.0" authors = ["Varphone Wong "] license = "MIT OR Apache-2.0" edition = "2021" -rust-version = "1.72" +rust-version = "1.74" publish = false diff --git a/examples/custom_plot_manipulation/Cargo.toml b/examples/custom_plot_manipulation/Cargo.toml index 3df5de96f3d..64126654d41 100644 --- a/examples/custom_plot_manipulation/Cargo.toml +++ b/examples/custom_plot_manipulation/Cargo.toml @@ -4,7 +4,7 @@ version = "0.1.0" authors = ["Ygor Souza "] license = "MIT OR Apache-2.0" edition = "2021" -rust-version = "1.72" +rust-version = "1.74" publish = false diff --git a/examples/custom_window_frame/Cargo.toml b/examples/custom_window_frame/Cargo.toml index e163bda492a..a08c6ba40fa 100644 --- a/examples/custom_window_frame/Cargo.toml +++ b/examples/custom_window_frame/Cargo.toml @@ -4,7 +4,7 @@ version = "0.1.0" authors = ["Emil Ernerfeldt "] license = "MIT OR Apache-2.0" edition = "2021" -rust-version = "1.72" +rust-version = "1.74" publish = false diff --git a/examples/file_dialog/Cargo.toml b/examples/file_dialog/Cargo.toml index ceafd1be28a..10c7f1f00ed 100644 --- a/examples/file_dialog/Cargo.toml +++ b/examples/file_dialog/Cargo.toml @@ -4,7 +4,7 @@ version = "0.1.0" authors = ["Emil Ernerfeldt "] license = "MIT OR Apache-2.0" edition = "2021" -rust-version = "1.72" +rust-version = "1.74" publish = false diff --git a/examples/hello_world/Cargo.toml b/examples/hello_world/Cargo.toml index e9e113c6722..301959c420e 100644 --- a/examples/hello_world/Cargo.toml +++ b/examples/hello_world/Cargo.toml @@ -4,7 +4,7 @@ version = "0.1.0" authors = ["Emil Ernerfeldt "] license = "MIT OR Apache-2.0" edition = "2021" -rust-version = "1.72" +rust-version = "1.74" publish = false diff --git a/examples/hello_world_par/Cargo.toml b/examples/hello_world_par/Cargo.toml index 442f671e330..5a8850d2ae0 100644 --- a/examples/hello_world_par/Cargo.toml +++ b/examples/hello_world_par/Cargo.toml @@ -4,7 +4,7 @@ version = "0.1.0" authors = ["Maxim Osipenko "] license = "MIT OR Apache-2.0" edition = "2021" -rust-version = "1.72" +rust-version = "1.74" publish = false diff --git a/examples/hello_world_simple/Cargo.toml b/examples/hello_world_simple/Cargo.toml index 5b93eb686c7..b91792a7753 100644 --- a/examples/hello_world_simple/Cargo.toml +++ b/examples/hello_world_simple/Cargo.toml @@ -4,7 +4,7 @@ version = "0.1.0" authors = ["Emil Ernerfeldt "] license = "MIT OR Apache-2.0" edition = "2021" -rust-version = "1.72" +rust-version = "1.74" publish = false diff --git a/examples/images/Cargo.toml b/examples/images/Cargo.toml index b6cb142f723..e9a0717219c 100644 --- a/examples/images/Cargo.toml +++ b/examples/images/Cargo.toml @@ -4,7 +4,7 @@ version = "0.1.0" authors = ["Jan Procházka "] license = "MIT OR Apache-2.0" edition = "2021" -rust-version = "1.72" +rust-version = "1.74" publish = false diff --git a/examples/keyboard_events/Cargo.toml b/examples/keyboard_events/Cargo.toml index 5428bc6a3ae..628f02a6407 100644 --- a/examples/keyboard_events/Cargo.toml +++ b/examples/keyboard_events/Cargo.toml @@ -4,7 +4,7 @@ version = "0.1.0" authors = ["Jose Palazon "] license = "MIT OR Apache-2.0" edition = "2021" -rust-version = "1.72" +rust-version = "1.74" publish = false diff --git a/examples/multiple_viewports/Cargo.toml b/examples/multiple_viewports/Cargo.toml index 37b27cb5f96..d17d0723b8c 100644 --- a/examples/multiple_viewports/Cargo.toml +++ b/examples/multiple_viewports/Cargo.toml @@ -4,7 +4,7 @@ version = "0.1.0" authors = ["Emil Ernerfeldt "] license = "MIT OR Apache-2.0" edition = "2021" -rust-version = "1.72" +rust-version = "1.74" publish = false [features] diff --git a/examples/puffin_profiler/Cargo.toml b/examples/puffin_profiler/Cargo.toml index 021c05651a6..e164aa19d87 100644 --- a/examples/puffin_profiler/Cargo.toml +++ b/examples/puffin_profiler/Cargo.toml @@ -4,7 +4,7 @@ version = "0.1.0" authors = ["Emil Ernerfeldt "] license = "MIT OR Apache-2.0" edition = "2021" -rust-version = "1.72" +rust-version = "1.74" publish = false diff --git a/examples/save_plot/Cargo.toml b/examples/save_plot/Cargo.toml index cb31594343c..32a32bbb195 100644 --- a/examples/save_plot/Cargo.toml +++ b/examples/save_plot/Cargo.toml @@ -4,7 +4,7 @@ version = "0.1.0" authors = ["hacknus "] license = "MIT OR Apache-2.0" edition = "2021" -rust-version = "1.72" +rust-version = "1.74" publish = false [dependencies] diff --git a/examples/screenshot/Cargo.toml b/examples/screenshot/Cargo.toml index 5c7bbbeec42..e35c0ea13fb 100644 --- a/examples/screenshot/Cargo.toml +++ b/examples/screenshot/Cargo.toml @@ -7,7 +7,7 @@ authors = [ ] license = "MIT OR Apache-2.0" edition = "2021" -rust-version = "1.72" +rust-version = "1.74" publish = false diff --git a/examples/serial_windows/Cargo.toml b/examples/serial_windows/Cargo.toml index ee0f7b78d25..5b76c0abb1a 100644 --- a/examples/serial_windows/Cargo.toml +++ b/examples/serial_windows/Cargo.toml @@ -4,7 +4,7 @@ version = "0.1.0" authors = ["Emil Ernerfeldt "] license = "MIT OR Apache-2.0" edition = "2021" -rust-version = "1.72" +rust-version = "1.74" publish = false diff --git a/examples/test_inline_glow_paint/Cargo.toml b/examples/test_inline_glow_paint/Cargo.toml index f1ff645ac27..7f0cb5df15f 100644 --- a/examples/test_inline_glow_paint/Cargo.toml +++ b/examples/test_inline_glow_paint/Cargo.toml @@ -4,7 +4,7 @@ version = "0.1.0" authors = ["Emil Ernerfeldt "] license = "MIT OR Apache-2.0" edition = "2021" -rust-version = "1.72" +rust-version = "1.74" publish = false # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html diff --git a/examples/test_viewports/Cargo.toml b/examples/test_viewports/Cargo.toml index cd5b2be0e18..5bcc0a5ce28 100644 --- a/examples/test_viewports/Cargo.toml +++ b/examples/test_viewports/Cargo.toml @@ -4,7 +4,7 @@ version = "0.1.0" authors = ["konkitoman"] license = "MIT OR Apache-2.0" edition = "2021" -rust-version = "1.72" +rust-version = "1.74" publish = false [features] diff --git a/examples/user_attention/Cargo.toml b/examples/user_attention/Cargo.toml index 02a776477dd..74734650e84 100644 --- a/examples/user_attention/Cargo.toml +++ b/examples/user_attention/Cargo.toml @@ -4,7 +4,7 @@ version = "0.1.0" authors = ["TicClick "] license = "MIT OR Apache-2.0" edition = "2021" -rust-version = "1.72" +rust-version = "1.74" publish = false [dependencies] diff --git a/rust-toolchain b/rust-toolchain index 694e5af99e5..8c37a023c1e 100644 --- a/rust-toolchain +++ b/rust-toolchain @@ -5,6 +5,6 @@ # to the user in the error, instead of "error: invalid channel name '[toolchain]'". [toolchain] -channel = "1.72.0" +channel = "1.74.0" components = ["rustfmt", "clippy"] targets = ["wasm32-unknown-unknown"] diff --git a/scripts/clippy_wasm/clippy.toml b/scripts/clippy_wasm/clippy.toml index 0e8b9474ea7..073a54012de 100644 --- a/scripts/clippy_wasm/clippy.toml +++ b/scripts/clippy_wasm/clippy.toml @@ -6,7 +6,7 @@ # ----------------------------------------------------------------------------- # Section identical to the root clippy.toml: -msrv = "1.72" +msrv = "1.74" allow-unwrap-in-tests = true From 20663368d7541af636788aa767028cce17e03606 Mon Sep 17 00:00:00 2001 From: Emil Ernerfeldt Date: Thu, 25 Apr 2024 14:14:12 +0200 Subject: [PATCH 2/8] Fix clippy lints --- crates/eframe/src/native/app_icon.rs | 4 +--- crates/eframe/src/native/run.rs | 4 ++++ 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/crates/eframe/src/native/app_icon.rs b/crates/eframe/src/native/app_icon.rs index 4986549cc1b..39c32dfdb3e 100644 --- a/crates/eframe/src/native/app_icon.rs +++ b/crates/eframe/src/native/app_icon.rs @@ -225,9 +225,7 @@ fn set_title_and_icon_mac(title: &str, icon_data: Option<&IconData>) -> AppIconS } unsafe { - let app = if let Some(app) = NSApp { - app - } else { + let Some(app) = NSApp else { log::debug!("NSApp is null"); return AppIconStatus::NotSetIgnored; }; diff --git a/crates/eframe/src/native/run.rs b/crates/eframe/src/native/run.rs index 896d640de36..3ee249edf76 100644 --- a/crates/eframe/src/native/run.rs +++ b/crates/eframe/src/native/run.rs @@ -391,6 +391,8 @@ pub fn run_glow( mut native_options: epi::NativeOptions, app_creator: epi::AppCreator, ) -> Result<()> { + #![allow(clippy::needless_return_with_question_mark)] // False positive + use super::glow_integration::GlowWinitApp; #[cfg(not(target_os = "ios"))] @@ -414,6 +416,8 @@ pub fn run_wgpu( mut native_options: epi::NativeOptions, app_creator: epi::AppCreator, ) -> Result<()> { + #![allow(clippy::needless_return_with_question_mark)] // False positive + use super::wgpu_integration::WgpuWinitApp; #[cfg(not(target_os = "ios"))] From 63b8adbc1555946fd775d0deb9a2762def465bd5 Mon Sep 17 00:00:00 2001 From: Emil Ernerfeldt Date: Thu, 25 Apr 2024 14:59:05 +0200 Subject: [PATCH 3/8] Fix some doclinks --- crates/egui/src/containers/collapsing_header.rs | 2 +- crates/egui/src/style.rs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/crates/egui/src/containers/collapsing_header.rs b/crates/egui/src/containers/collapsing_header.rs index 6fb7662af22..d8881958b90 100644 --- a/crates/egui/src/containers/collapsing_header.rs +++ b/crates/egui/src/containers/collapsing_header.rs @@ -230,7 +230,7 @@ impl CollapsingState { } } - /// Paint this [CollapsingState](CollapsingState)'s toggle button. Takes an [IconPainter](IconPainter) as the icon. + /// Paint this [CollapsingState]'s toggle button. Takes an [IconPainter] as the icon. /// ``` /// # egui::__run_test_ui(|ui| { /// fn circle_icon(ui: &mut egui::Ui, openness: f32, response: &egui::Response) { diff --git a/crates/egui/src/style.rs b/crates/egui/src/style.rs index 9f9aac0534a..aad8e3eea2d 100644 --- a/crates/egui/src/style.rs +++ b/crates/egui/src/style.rs @@ -288,7 +288,7 @@ pub struct Spacing { /// Default rail height of a [`Slider`]. pub slider_rail_height: f32, - /// Default (minimum) width of a [`ComboBox`](crate::ComboBox). + /// Default (minimum) width of a [`ComboBox`]. pub combo_width: f32, /// Default width of a [`TextEdit`]. From ab1329078655ac8b6005bf905678b14ab59d5cd2 Mon Sep 17 00:00:00 2001 From: Emil Ernerfeldt Date: Thu, 25 Apr 2024 15:03:49 +0200 Subject: [PATCH 4/8] Update to 1.76 to avoid extremely slow cargo doc of wgpu crates MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit `cargo doc` would get stuck on wgpu because of a bug in cargo doc …so we go to 1.76 --- .github/workflows/deploy_web_demo.yml | 2 +- .github/workflows/rust.yml | 10 +- Cargo.toml | 140 ++++++++++++++++++- clippy.toml | 2 +- examples/confirm_exit/Cargo.toml | 2 +- examples/custom_3d_glow/Cargo.toml | 2 +- examples/custom_font/Cargo.toml | 2 +- examples/custom_font_style/Cargo.toml | 2 +- examples/custom_keypad/Cargo.toml | 2 +- examples/custom_plot_manipulation/Cargo.toml | 2 +- examples/custom_window_frame/Cargo.toml | 2 +- examples/file_dialog/Cargo.toml | 2 +- examples/hello_world/Cargo.toml | 2 +- examples/hello_world_par/Cargo.toml | 2 +- examples/hello_world_simple/Cargo.toml | 2 +- examples/images/Cargo.toml | 2 +- examples/images/src/ferris.svg | 2 +- examples/keyboard_events/Cargo.toml | 2 +- examples/multiple_viewports/Cargo.toml | 2 +- examples/puffin_profiler/Cargo.toml | 2 +- examples/save_plot/Cargo.toml | 2 +- examples/screenshot/Cargo.toml | 2 +- examples/serial_windows/Cargo.toml | 2 +- examples/test_inline_glow_paint/Cargo.toml | 2 +- examples/test_viewports/Cargo.toml | 2 +- examples/user_attention/Cargo.toml | 2 +- rust-toolchain | 2 +- scripts/clippy_wasm/clippy.toml | 2 +- 28 files changed, 170 insertions(+), 32 deletions(-) diff --git a/.github/workflows/deploy_web_demo.yml b/.github/workflows/deploy_web_demo.yml index 5928653ae96..41203da390b 100644 --- a/.github/workflows/deploy_web_demo.yml +++ b/.github/workflows/deploy_web_demo.yml @@ -43,7 +43,7 @@ jobs: with: profile: minimal target: wasm32-unknown-unknown - toolchain: 1.74.0 + toolchain: 1.76.0 override: true - uses: Swatinem/rust-cache@v2 diff --git a/.github/workflows/rust.yml b/.github/workflows/rust.yml index 0576f174f8d..89983a2c48b 100644 --- a/.github/workflows/rust.yml +++ b/.github/workflows/rust.yml @@ -19,7 +19,7 @@ jobs: - uses: dtolnay/rust-toolchain@master with: - toolchain: 1.74.0 + toolchain: 1.76.0 - name: Install packages (Linux) if: runner.os == 'Linux' @@ -93,7 +93,7 @@ jobs: - uses: actions/checkout@v4 - uses: dtolnay/rust-toolchain@master with: - toolchain: 1.74.0 + toolchain: 1.76.0 targets: wasm32-unknown-unknown - run: sudo apt-get update && sudo apt-get install libgtk-3-dev libatk1.0-dev @@ -151,7 +151,7 @@ jobs: - uses: actions/checkout@v4 - uses: EmbarkStudios/cargo-deny-action@v1 with: - rust-version: "1.74.0" + rust-version: "1.76.0" log-level: error command: check arguments: --target ${{ matrix.target }} @@ -166,7 +166,7 @@ jobs: - uses: dtolnay/rust-toolchain@master with: - toolchain: 1.74.0 + toolchain: 1.76.0 targets: aarch64-linux-android - name: Set up cargo cache @@ -184,7 +184,7 @@ jobs: - uses: actions/checkout@v4 - uses: dtolnay/rust-toolchain@master with: - toolchain: 1.74.0 + toolchain: 1.76.0 - name: Set up cargo cache uses: Swatinem/rust-cache@v2 diff --git a/Cargo.toml b/Cargo.toml index a3e24c94024..eced4c0595f 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -21,7 +21,7 @@ members = [ [workspace.package] edition = "2021" license = "MIT OR Apache-2.0" -rust-version = "1.74" +rust-version = "1.76" version = "0.27.2" @@ -84,3 +84,141 @@ wgpu = { version = "0.19.1", default-features = false, features = [ "fragile-send-sync-non-atomic-wasm", ] } winit = { version = "0.29.4", default-features = false } + + +[workspace.lints.rustdoc] +all = "warn" +missing_crate_level_docs = "warn" + +# See also clippy.toml +[workspace.lints.clippy] +as_ptr_cast_mut = "warn" +await_holding_lock = "warn" +bool_to_int_with_if = "warn" +char_lit_as_u8 = "warn" +checked_conversions = "warn" +clear_with_drain = "warn" +cloned_instead_of_copied = "warn" +dbg_macro = "warn" +debug_assert_with_mut_call = "warn" +derive_partial_eq_without_eq = "warn" +disallowed_macros = "warn" # See clippy.toml +disallowed_methods = "warn" # See clippy.toml +disallowed_names = "warn" # See clippy.toml +disallowed_script_idents = "warn" # See clippy.toml +disallowed_types = "warn" # See clippy.toml +doc_link_with_quotes = "warn" +doc_markdown = "warn" +empty_enum = "warn" +enum_glob_use = "warn" +equatable_if_let = "warn" +exit = "warn" +expl_impl_clone_on_copy = "warn" +explicit_deref_methods = "warn" +explicit_into_iter_loop = "warn" +explicit_iter_loop = "warn" +fallible_impl_from = "warn" +filter_map_next = "warn" +flat_map_option = "warn" +float_cmp_const = "warn" +fn_params_excessive_bools = "warn" +fn_to_numeric_cast_any = "warn" +from_iter_instead_of_collect = "warn" +get_unwrap = "warn" +if_let_mutex = "warn" +implicit_clone = "warn" +imprecise_flops = "warn" +index_refutable_slice = "warn" +inefficient_to_string = "warn" +invalid_upcast_comparisons = "warn" +iter_not_returning_iterator = "warn" +iter_on_empty_collections = "warn" +iter_on_single_items = "warn" +large_digit_groups = "warn" +large_include_file = "warn" +large_stack_arrays = "warn" +large_stack_frames = "warn" +large_types_passed_by_value = "warn" +let_underscore_untyped = "warn" +let_unit_value = "warn" +linkedlist = "warn" +lossy_float_literal = "warn" +macro_use_imports = "warn" +manual_assert = "warn" +manual_clamp = "warn" +manual_instant_elapsed = "warn" +manual_let_else = "warn" +manual_ok_or = "warn" +manual_string_new = "warn" +map_err_ignore = "warn" +map_flatten = "warn" +map_unwrap_or = "warn" +match_on_vec_items = "warn" +match_same_arms = "warn" +match_wild_err_arm = "warn" +match_wildcard_for_single_variants = "warn" +mem_forget = "warn" +mismatched_target_os = "warn" +mismatching_type_param_order = "warn" +missing_assert_message = "warn" +missing_enforced_import_renames = "warn" +missing_errors_doc = "warn" +missing_safety_doc = "warn" +mut_mut = "warn" +mutex_integer = "warn" +needless_borrow = "warn" +needless_continue = "warn" +needless_for_each = "warn" +needless_pass_by_ref_mut = "warn" +needless_pass_by_value = "warn" +negative_feature_names = "warn" +nonstandard_macro_braces = "warn" +option_option = "warn" +path_buf_push_overwrite = "warn" +ptr_as_ptr = "warn" +ptr_cast_constness = "warn" +pub_without_shorthand = "warn" +rc_mutex = "warn" +readonly_write_lock = "warn" +redundant_type_annotations = "warn" +ref_option_ref = "warn" +ref_patterns = "warn" +rest_pat_in_fully_bound_structs = "warn" +same_functions_in_if_condition = "warn" +semicolon_if_nothing_returned = "warn" +should_panic_without_expect = "warn" +significant_drop_tightening = "warn" +single_match_else = "warn" +str_to_string = "warn" +string_add = "warn" +string_add_assign = "warn" +string_lit_as_bytes = "warn" +string_lit_chars_any = "warn" +string_to_string = "warn" +suspicious_command_arg_space = "warn" +suspicious_xor_used_as_pow = "warn" +todo = "warn" +too_many_lines = "warn" +trailing_empty_array = "warn" +trait_duplication_in_bounds = "warn" +tuple_array_conversions = "warn" +unchecked_duration_subtraction = "warn" +undocumented_unsafe_blocks = "warn" +unimplemented = "warn" +uninlined_format_args = "warn" +unnecessary_box_returns = "warn" +unnecessary_safety_doc = "warn" +unnecessary_struct_initialization = "warn" +unnecessary_wraps = "warn" +unnested_or_patterns = "warn" +unused_peekable = "warn" +unused_rounding = "warn" +unused_self = "warn" +unwrap_used = "warn" +useless_transmute = "warn" +verbose_file_reads = "warn" +wildcard_dependencies = "warn" +wildcard_imports = "warn" +zero_sized_map_values = "warn" + +manual_range_contains = "allow" # this one is just worse imho diff --git a/clippy.toml b/clippy.toml index e11e2505661..d91f9666c47 100644 --- a/clippy.toml +++ b/clippy.toml @@ -3,7 +3,7 @@ # ----------------------------------------------------------------------------- # Section identical to scripts/clippy_wasm/clippy.toml: -msrv = "1.74" +msrv = "1.76" allow-unwrap-in-tests = true diff --git a/examples/confirm_exit/Cargo.toml b/examples/confirm_exit/Cargo.toml index 0c9566b9411..8e9d3af2872 100644 --- a/examples/confirm_exit/Cargo.toml +++ b/examples/confirm_exit/Cargo.toml @@ -4,7 +4,7 @@ version = "0.1.0" authors = ["Emil Ernerfeldt "] license = "MIT OR Apache-2.0" edition = "2021" -rust-version = "1.74" +rust-version = "1.76" publish = false diff --git a/examples/custom_3d_glow/Cargo.toml b/examples/custom_3d_glow/Cargo.toml index 41d550a0c4e..ef3d1cbc828 100644 --- a/examples/custom_3d_glow/Cargo.toml +++ b/examples/custom_3d_glow/Cargo.toml @@ -4,7 +4,7 @@ version = "0.1.0" authors = ["Emil Ernerfeldt "] license = "MIT OR Apache-2.0" edition = "2021" -rust-version = "1.74" +rust-version = "1.76" publish = false diff --git a/examples/custom_font/Cargo.toml b/examples/custom_font/Cargo.toml index a4e228f9b22..89840c4526d 100644 --- a/examples/custom_font/Cargo.toml +++ b/examples/custom_font/Cargo.toml @@ -4,7 +4,7 @@ version = "0.1.0" authors = ["Emil Ernerfeldt "] license = "MIT OR Apache-2.0" edition = "2021" -rust-version = "1.74" +rust-version = "1.76" publish = false diff --git a/examples/custom_font_style/Cargo.toml b/examples/custom_font_style/Cargo.toml index d7a7b1c0eac..60e3e37b9c2 100644 --- a/examples/custom_font_style/Cargo.toml +++ b/examples/custom_font_style/Cargo.toml @@ -4,7 +4,7 @@ version = "0.1.0" authors = ["tami5 "] license = "MIT OR Apache-2.0" edition = "2021" -rust-version = "1.74" +rust-version = "1.76" publish = false diff --git a/examples/custom_keypad/Cargo.toml b/examples/custom_keypad/Cargo.toml index 252a3b26bcf..f008884c5c7 100644 --- a/examples/custom_keypad/Cargo.toml +++ b/examples/custom_keypad/Cargo.toml @@ -4,7 +4,7 @@ version = "0.1.0" authors = ["Varphone Wong "] license = "MIT OR Apache-2.0" edition = "2021" -rust-version = "1.74" +rust-version = "1.76" publish = false diff --git a/examples/custom_plot_manipulation/Cargo.toml b/examples/custom_plot_manipulation/Cargo.toml index 64126654d41..3db38a45b92 100644 --- a/examples/custom_plot_manipulation/Cargo.toml +++ b/examples/custom_plot_manipulation/Cargo.toml @@ -4,7 +4,7 @@ version = "0.1.0" authors = ["Ygor Souza "] license = "MIT OR Apache-2.0" edition = "2021" -rust-version = "1.74" +rust-version = "1.76" publish = false diff --git a/examples/custom_window_frame/Cargo.toml b/examples/custom_window_frame/Cargo.toml index a08c6ba40fa..c334c6a662b 100644 --- a/examples/custom_window_frame/Cargo.toml +++ b/examples/custom_window_frame/Cargo.toml @@ -4,7 +4,7 @@ version = "0.1.0" authors = ["Emil Ernerfeldt "] license = "MIT OR Apache-2.0" edition = "2021" -rust-version = "1.74" +rust-version = "1.76" publish = false diff --git a/examples/file_dialog/Cargo.toml b/examples/file_dialog/Cargo.toml index 10c7f1f00ed..ef30dfce8e1 100644 --- a/examples/file_dialog/Cargo.toml +++ b/examples/file_dialog/Cargo.toml @@ -4,7 +4,7 @@ version = "0.1.0" authors = ["Emil Ernerfeldt "] license = "MIT OR Apache-2.0" edition = "2021" -rust-version = "1.74" +rust-version = "1.76" publish = false diff --git a/examples/hello_world/Cargo.toml b/examples/hello_world/Cargo.toml index 301959c420e..acf7e2b8ab8 100644 --- a/examples/hello_world/Cargo.toml +++ b/examples/hello_world/Cargo.toml @@ -4,7 +4,7 @@ version = "0.1.0" authors = ["Emil Ernerfeldt "] license = "MIT OR Apache-2.0" edition = "2021" -rust-version = "1.74" +rust-version = "1.76" publish = false diff --git a/examples/hello_world_par/Cargo.toml b/examples/hello_world_par/Cargo.toml index 5a8850d2ae0..3d0e92eaec4 100644 --- a/examples/hello_world_par/Cargo.toml +++ b/examples/hello_world_par/Cargo.toml @@ -4,7 +4,7 @@ version = "0.1.0" authors = ["Maxim Osipenko "] license = "MIT OR Apache-2.0" edition = "2021" -rust-version = "1.74" +rust-version = "1.76" publish = false diff --git a/examples/hello_world_simple/Cargo.toml b/examples/hello_world_simple/Cargo.toml index b91792a7753..bec4670b790 100644 --- a/examples/hello_world_simple/Cargo.toml +++ b/examples/hello_world_simple/Cargo.toml @@ -4,7 +4,7 @@ version = "0.1.0" authors = ["Emil Ernerfeldt "] license = "MIT OR Apache-2.0" edition = "2021" -rust-version = "1.74" +rust-version = "1.76" publish = false diff --git a/examples/images/Cargo.toml b/examples/images/Cargo.toml index e9a0717219c..cd9157f5715 100644 --- a/examples/images/Cargo.toml +++ b/examples/images/Cargo.toml @@ -4,7 +4,7 @@ version = "0.1.0" authors = ["Jan Procházka "] license = "MIT OR Apache-2.0" edition = "2021" -rust-version = "1.74" +rust-version = "1.76" publish = false diff --git a/examples/images/src/ferris.svg b/examples/images/src/ferris.svg index c7f240dd97a..fe1589d912c 100644 --- a/examples/images/src/ferris.svg +++ b/examples/images/src/ferris.svg @@ -3,7 +3,7 @@ - + diff --git a/examples/keyboard_events/Cargo.toml b/examples/keyboard_events/Cargo.toml index 628f02a6407..08f7ba3a81e 100644 --- a/examples/keyboard_events/Cargo.toml +++ b/examples/keyboard_events/Cargo.toml @@ -4,7 +4,7 @@ version = "0.1.0" authors = ["Jose Palazon "] license = "MIT OR Apache-2.0" edition = "2021" -rust-version = "1.74" +rust-version = "1.76" publish = false diff --git a/examples/multiple_viewports/Cargo.toml b/examples/multiple_viewports/Cargo.toml index d17d0723b8c..b5bd8e80411 100644 --- a/examples/multiple_viewports/Cargo.toml +++ b/examples/multiple_viewports/Cargo.toml @@ -4,7 +4,7 @@ version = "0.1.0" authors = ["Emil Ernerfeldt "] license = "MIT OR Apache-2.0" edition = "2021" -rust-version = "1.74" +rust-version = "1.76" publish = false [features] diff --git a/examples/puffin_profiler/Cargo.toml b/examples/puffin_profiler/Cargo.toml index e164aa19d87..6b6acad726d 100644 --- a/examples/puffin_profiler/Cargo.toml +++ b/examples/puffin_profiler/Cargo.toml @@ -4,7 +4,7 @@ version = "0.1.0" authors = ["Emil Ernerfeldt "] license = "MIT OR Apache-2.0" edition = "2021" -rust-version = "1.74" +rust-version = "1.76" publish = false diff --git a/examples/save_plot/Cargo.toml b/examples/save_plot/Cargo.toml index 32a32bbb195..7c9eb245285 100644 --- a/examples/save_plot/Cargo.toml +++ b/examples/save_plot/Cargo.toml @@ -4,7 +4,7 @@ version = "0.1.0" authors = ["hacknus "] license = "MIT OR Apache-2.0" edition = "2021" -rust-version = "1.74" +rust-version = "1.76" publish = false [dependencies] diff --git a/examples/screenshot/Cargo.toml b/examples/screenshot/Cargo.toml index e35c0ea13fb..0fb5da7fd2a 100644 --- a/examples/screenshot/Cargo.toml +++ b/examples/screenshot/Cargo.toml @@ -7,7 +7,7 @@ authors = [ ] license = "MIT OR Apache-2.0" edition = "2021" -rust-version = "1.74" +rust-version = "1.76" publish = false diff --git a/examples/serial_windows/Cargo.toml b/examples/serial_windows/Cargo.toml index 5b76c0abb1a..58d5cdecced 100644 --- a/examples/serial_windows/Cargo.toml +++ b/examples/serial_windows/Cargo.toml @@ -4,7 +4,7 @@ version = "0.1.0" authors = ["Emil Ernerfeldt "] license = "MIT OR Apache-2.0" edition = "2021" -rust-version = "1.74" +rust-version = "1.76" publish = false diff --git a/examples/test_inline_glow_paint/Cargo.toml b/examples/test_inline_glow_paint/Cargo.toml index 7f0cb5df15f..893b0d07de1 100644 --- a/examples/test_inline_glow_paint/Cargo.toml +++ b/examples/test_inline_glow_paint/Cargo.toml @@ -4,7 +4,7 @@ version = "0.1.0" authors = ["Emil Ernerfeldt "] license = "MIT OR Apache-2.0" edition = "2021" -rust-version = "1.74" +rust-version = "1.76" publish = false # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html diff --git a/examples/test_viewports/Cargo.toml b/examples/test_viewports/Cargo.toml index 5bcc0a5ce28..4e106e37ec8 100644 --- a/examples/test_viewports/Cargo.toml +++ b/examples/test_viewports/Cargo.toml @@ -4,7 +4,7 @@ version = "0.1.0" authors = ["konkitoman"] license = "MIT OR Apache-2.0" edition = "2021" -rust-version = "1.74" +rust-version = "1.76" publish = false [features] diff --git a/examples/user_attention/Cargo.toml b/examples/user_attention/Cargo.toml index 74734650e84..10f0ce711c0 100644 --- a/examples/user_attention/Cargo.toml +++ b/examples/user_attention/Cargo.toml @@ -4,7 +4,7 @@ version = "0.1.0" authors = ["TicClick "] license = "MIT OR Apache-2.0" edition = "2021" -rust-version = "1.74" +rust-version = "1.76" publish = false [dependencies] diff --git a/rust-toolchain b/rust-toolchain index 8c37a023c1e..871f562485d 100644 --- a/rust-toolchain +++ b/rust-toolchain @@ -5,6 +5,6 @@ # to the user in the error, instead of "error: invalid channel name '[toolchain]'". [toolchain] -channel = "1.74.0" +channel = "1.76.0" components = ["rustfmt", "clippy"] targets = ["wasm32-unknown-unknown"] diff --git a/scripts/clippy_wasm/clippy.toml b/scripts/clippy_wasm/clippy.toml index 073a54012de..943444cfc50 100644 --- a/scripts/clippy_wasm/clippy.toml +++ b/scripts/clippy_wasm/clippy.toml @@ -6,7 +6,7 @@ # ----------------------------------------------------------------------------- # Section identical to the root clippy.toml: -msrv = "1.74" +msrv = "1.76" allow-unwrap-in-tests = true From c63ed2591e8ede89d82873756d07b59994be194d Mon Sep 17 00:00:00 2001 From: Emil Ernerfeldt Date: Thu, 25 Apr 2024 15:04:41 +0200 Subject: [PATCH 5/8] Fix more clippy lints --- crates/egui/src/containers/collapsing_header.rs | 2 +- crates/epaint/src/shape.rs | 7 +------ 2 files changed, 2 insertions(+), 7 deletions(-) diff --git a/crates/egui/src/containers/collapsing_header.rs b/crates/egui/src/containers/collapsing_header.rs index d8881958b90..7c541a1a2f7 100644 --- a/crates/egui/src/containers/collapsing_header.rs +++ b/crates/egui/src/containers/collapsing_header.rs @@ -230,7 +230,7 @@ impl CollapsingState { } } - /// Paint this [CollapsingState]'s toggle button. Takes an [IconPainter] as the icon. + /// Paint this [`CollapsingState`]'s toggle button. Takes an [`IconPainter`] as the icon. /// ``` /// # egui::__run_test_ui(|ui| { /// fn circle_icon(ui: &mut egui::Ui, openness: f32, response: &egui::Response) { diff --git a/crates/epaint/src/shape.rs b/crates/epaint/src/shape.rs index 336c9087316..593cc78b0f3 100644 --- a/crates/epaint/src/shape.rs +++ b/crates/epaint/src/shape.rs @@ -1293,12 +1293,7 @@ impl std::fmt::Debug for PaintCallback { impl std::cmp::PartialEq for PaintCallback { fn eq(&self, other: &Self) -> bool { - // As I understand it, the problem this clippy is trying to protect against - // can only happen if we do dynamic casts back and forth on the pointers, and we don't do that. - #[allow(clippy::vtable_address_comparisons)] - { - self.rect.eq(&other.rect) && Arc::ptr_eq(&self.callback, &other.callback) - } + self.rect.eq(&other.rect) && Arc::ptr_eq(&self.callback, &other.callback) } } From 79f7f642b0645e66a70c7ec93d2368fd379d83de Mon Sep 17 00:00:00 2001 From: Emil Ernerfeldt Date: Thu, 25 Apr 2024 15:06:34 +0200 Subject: [PATCH 6/8] Revert the workspace lints I accidentally added too soon --- Cargo.toml | 138 ----------------------------------------------------- 1 file changed, 138 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index eced4c0595f..47ef422cb5a 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -84,141 +84,3 @@ wgpu = { version = "0.19.1", default-features = false, features = [ "fragile-send-sync-non-atomic-wasm", ] } winit = { version = "0.29.4", default-features = false } - - -[workspace.lints.rustdoc] -all = "warn" -missing_crate_level_docs = "warn" - -# See also clippy.toml -[workspace.lints.clippy] -as_ptr_cast_mut = "warn" -await_holding_lock = "warn" -bool_to_int_with_if = "warn" -char_lit_as_u8 = "warn" -checked_conversions = "warn" -clear_with_drain = "warn" -cloned_instead_of_copied = "warn" -dbg_macro = "warn" -debug_assert_with_mut_call = "warn" -derive_partial_eq_without_eq = "warn" -disallowed_macros = "warn" # See clippy.toml -disallowed_methods = "warn" # See clippy.toml -disallowed_names = "warn" # See clippy.toml -disallowed_script_idents = "warn" # See clippy.toml -disallowed_types = "warn" # See clippy.toml -doc_link_with_quotes = "warn" -doc_markdown = "warn" -empty_enum = "warn" -enum_glob_use = "warn" -equatable_if_let = "warn" -exit = "warn" -expl_impl_clone_on_copy = "warn" -explicit_deref_methods = "warn" -explicit_into_iter_loop = "warn" -explicit_iter_loop = "warn" -fallible_impl_from = "warn" -filter_map_next = "warn" -flat_map_option = "warn" -float_cmp_const = "warn" -fn_params_excessive_bools = "warn" -fn_to_numeric_cast_any = "warn" -from_iter_instead_of_collect = "warn" -get_unwrap = "warn" -if_let_mutex = "warn" -implicit_clone = "warn" -imprecise_flops = "warn" -index_refutable_slice = "warn" -inefficient_to_string = "warn" -invalid_upcast_comparisons = "warn" -iter_not_returning_iterator = "warn" -iter_on_empty_collections = "warn" -iter_on_single_items = "warn" -large_digit_groups = "warn" -large_include_file = "warn" -large_stack_arrays = "warn" -large_stack_frames = "warn" -large_types_passed_by_value = "warn" -let_underscore_untyped = "warn" -let_unit_value = "warn" -linkedlist = "warn" -lossy_float_literal = "warn" -macro_use_imports = "warn" -manual_assert = "warn" -manual_clamp = "warn" -manual_instant_elapsed = "warn" -manual_let_else = "warn" -manual_ok_or = "warn" -manual_string_new = "warn" -map_err_ignore = "warn" -map_flatten = "warn" -map_unwrap_or = "warn" -match_on_vec_items = "warn" -match_same_arms = "warn" -match_wild_err_arm = "warn" -match_wildcard_for_single_variants = "warn" -mem_forget = "warn" -mismatched_target_os = "warn" -mismatching_type_param_order = "warn" -missing_assert_message = "warn" -missing_enforced_import_renames = "warn" -missing_errors_doc = "warn" -missing_safety_doc = "warn" -mut_mut = "warn" -mutex_integer = "warn" -needless_borrow = "warn" -needless_continue = "warn" -needless_for_each = "warn" -needless_pass_by_ref_mut = "warn" -needless_pass_by_value = "warn" -negative_feature_names = "warn" -nonstandard_macro_braces = "warn" -option_option = "warn" -path_buf_push_overwrite = "warn" -ptr_as_ptr = "warn" -ptr_cast_constness = "warn" -pub_without_shorthand = "warn" -rc_mutex = "warn" -readonly_write_lock = "warn" -redundant_type_annotations = "warn" -ref_option_ref = "warn" -ref_patterns = "warn" -rest_pat_in_fully_bound_structs = "warn" -same_functions_in_if_condition = "warn" -semicolon_if_nothing_returned = "warn" -should_panic_without_expect = "warn" -significant_drop_tightening = "warn" -single_match_else = "warn" -str_to_string = "warn" -string_add = "warn" -string_add_assign = "warn" -string_lit_as_bytes = "warn" -string_lit_chars_any = "warn" -string_to_string = "warn" -suspicious_command_arg_space = "warn" -suspicious_xor_used_as_pow = "warn" -todo = "warn" -too_many_lines = "warn" -trailing_empty_array = "warn" -trait_duplication_in_bounds = "warn" -tuple_array_conversions = "warn" -unchecked_duration_subtraction = "warn" -undocumented_unsafe_blocks = "warn" -unimplemented = "warn" -uninlined_format_args = "warn" -unnecessary_box_returns = "warn" -unnecessary_safety_doc = "warn" -unnecessary_struct_initialization = "warn" -unnecessary_wraps = "warn" -unnested_or_patterns = "warn" -unused_peekable = "warn" -unused_rounding = "warn" -unused_self = "warn" -unwrap_used = "warn" -useless_transmute = "warn" -verbose_file_reads = "warn" -wildcard_dependencies = "warn" -wildcard_imports = "warn" -zero_sized_map_values = "warn" - -manual_range_contains = "allow" # this one is just worse imho From 5ef017e78438e7bc066b3269d6b82bd0c059f2fd Mon Sep 17 00:00:00 2001 From: Emil Ernerfeldt Date: Thu, 25 Apr 2024 15:16:07 +0200 Subject: [PATCH 7/8] Another clippy fix --- crates/eframe/src/web/storage.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/crates/eframe/src/web/storage.rs b/crates/eframe/src/web/storage.rs index 4a2a53326a1..170798dc662 100644 --- a/crates/eframe/src/web/storage.rs +++ b/crates/eframe/src/web/storage.rs @@ -31,7 +31,7 @@ pub(crate) fn load_memory(_: &egui::Context) {} #[cfg(feature = "persistence")] pub(crate) fn save_memory(ctx: &egui::Context) { - match ctx.memory(|mem| ron::to_string(mem)) { + match ctx.memory(ron::to_string) { Ok(ron) => { local_storage_set("egui_memory_ron", &ron); } From 24e1f6fe98e3aee8a8616eaed63a78fa496ef26c Mon Sep 17 00:00:00 2001 From: Emil Ernerfeldt Date: Thu, 25 Apr 2024 15:32:23 +0200 Subject: [PATCH 8/8] More doc-link fixes --- crates/egui/src/lib.rs | 4 ++-- crates/egui/src/memory.rs | 2 +- crates/egui_extras/src/table.rs | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/crates/egui/src/lib.rs b/crates/egui/src/lib.rs index b8f0c8fa3d2..30e3b804f11 100644 --- a/crates/egui/src/lib.rs +++ b/crates/egui/src/lib.rs @@ -517,7 +517,7 @@ macro_rules! include_image { }; } -/// Create a [`Hyperlink`](crate::Hyperlink) to the current [`file!()`] (and line) on Github +/// Create a [`Hyperlink`] to the current [`file!()`] (and line) on Github /// /// ``` /// # egui::__run_test_ui(|ui| { @@ -532,7 +532,7 @@ macro_rules! github_link_file_line { }}; } -/// Create a [`Hyperlink`](crate::Hyperlink) to the current [`file!()`] on github. +/// Create a [`Hyperlink`] to the current [`file!()`] on github. /// /// ``` /// # egui::__run_test_ui(|ui| { diff --git a/crates/egui/src/memory.rs b/crates/egui/src/memory.rs index 7d61acd965f..2ef8bbf58ba 100644 --- a/crates/egui/src/memory.rs +++ b/crates/egui/src/memory.rs @@ -868,7 +868,7 @@ impl Memory { // ---------------------------------------------------------------------------- /// Keeps track of [`Area`](crate::containers::area::Area)s, which are free-floating [`Ui`](crate::Ui)s. -/// These [`Area`](crate::containers::area::Area)s can be in any [`Order`](crate::Order). +/// These [`Area`](crate::containers::area::Area)s can be in any [`Order`]. #[derive(Clone, Debug, Default)] #[cfg_attr(feature = "serde", derive(serde::Deserialize, serde::Serialize))] #[cfg_attr(feature = "serde", serde(default))] diff --git a/crates/egui_extras/src/table.rs b/crates/egui_extras/src/table.rs index 5e9cf80fdcd..0cbf5e13b5f 100644 --- a/crates/egui_extras/src/table.rs +++ b/crates/egui_extras/src/table.rs @@ -131,7 +131,7 @@ impl Column { self } - /// Allowed range of movement (in points), if in a resizable [`Table`](crate::table::Table). + /// Allowed range of movement (in points), if in a resizable [`Table`]. #[inline] pub fn range(mut self, range: impl Into) -> Self { self.width_range = range.into();