-
Notifications
You must be signed in to change notification settings - Fork 2k
Description
rust-analyzer version: 0.3.2769-standalone (2532c48 2026-01-25)
rustc version: 1.93.0 (254b59607 2026-01-19)
editor or extension: VSCode 0.3.2769 (Windows 11)
relevant settings: N/A
repository link (if public, optional): https://github.com/tauri-apps/muda/ 0.17.1
code snippet to reproduce:
use muda::{Menu, Submenu};
fn main() {
let menu_bar = Menu::new();
let file_m = Submenu::new("&File", true);
menu_bar.append_items(&[&file_m]).ok();
// ^^^^^^^^^^
// expected &[&(dyn IsMenuItem + 'static)], found &[{unknown}; 1]
// expected &(dyn IsMenuItem + 'static), found &Submenu
// rust-analyzer E0308
}Hello,
I tried to understand where this warning might be coming from (to get some sensible minimal reproduction), but cargo check doesn't show any warnings, and programs with all kinds of these strange coercion errors run without runtime errors.
The same (or something similar) happens with using Dioxus 0.7.3 desktop feature,
use dioxus::prelude::*;
// but Element is Result<VNode, RenderError>
// VNode is a struct with an Rc
// rsx! is a proc macro
fn popup() -> Element {
rsx! {
div { "This is a popup window!" }
// ^
// expected &[TemplateNode], found &[TemplateNode; 1]
// rust-analyzer E0308
}
}
I tried searching for similar issues on the library repositories too, and via Google. (Only found closed issues like #13864, but that's supposed to be fixed, and here is also a missing 'static bound.)
Thanks for considering!