Files
openidea/crates/ide-plugin
Mr0Bread 33ffa6cac1 refactor(plugin): make HostApi methods required, drop dead default bodies (#5489)
`HostApi` (`crates/ide-plugin/src/runtime.rs`) had 66 methods with default bodies (`Err(... unavailable on this host)`, `Ok(Vec::new())`, `let _ = (...)`). Its only implementor, `PluginApi`, overrides all of them, so those bodies could never run. They had to be kept in sync with real behaviour and let a forgotten override compile silently. They are now required methods (doc comments kept, signatures unchanged). No behaviour change.
`HostApi::project_of(&self, path)` is the one default that stays: `PluginApi` does not override it and it is live (`wit_host.rs` calls it, and the `project-of` guest fixtures exercise it). `PluginApi`'s own `project_of(window)` belongs to a different trait.

Co-authored-by: Mr0Bread <55754540+Mr0Bread@users.noreply.github.com>
2026-11-24 05:29:51 +08:00
..