diff --git a/crates/bevy_app/src/app.rs b/crates/bevy_app/src/app.rs index 20f15bb0984c4..9ce162d21774b 100644 --- a/crates/bevy_app/src/app.rs +++ b/crates/bevy_app/src/app.rs @@ -1276,7 +1276,7 @@ impl App { /// Set the global system error handler to use for systems that return a [`Result`]. /// - /// See the [`bevy_ecs::result` module-level documentation](../../bevy_ecs/result/index.html) + /// See the [`bevy_ecs::error` module-level documentation](bevy_ecs::error) /// for more information. pub fn set_system_error_handler( &mut self, diff --git a/crates/bevy_app/src/sub_app.rs b/crates/bevy_app/src/sub_app.rs index 0cb50ac887add..7d0dfd3106766 100644 --- a/crates/bevy_app/src/sub_app.rs +++ b/crates/bevy_app/src/sub_app.rs @@ -338,7 +338,7 @@ impl SubApp { /// Set the global error handler to use for systems that return a [`Result`]. /// - /// See the [`bevy_ecs::result` module-level documentation](../../bevy_ecs/result/index.html) + /// See the [`bevy_ecs::error` module-level documentation](bevy_ecs::error) /// for more information. pub fn set_system_error_handler( &mut self, diff --git a/crates/bevy_ecs/src/error/mod.rs b/crates/bevy_ecs/src/error/mod.rs index 307d93158f3e8..4c8ad10d8ec9c 100644 --- a/crates/bevy_ecs/src/error/mod.rs +++ b/crates/bevy_ecs/src/error/mod.rs @@ -8,10 +8,10 @@ //! [`panic`] error handler function is used, resulting in a panic with the error message attached. //! //! You can change the default behavior by registering a custom error handler, either globally or -//! per `Schedule`: +//! per [`Schedule`]: //! -//! - [`App::set_system_error_handler`] sets the global error handler for all systems of the -//! current [`World`]. +//! - `App::set_system_error_handler` (via `bevy_app`) sets the global error handler for all systems of the +//! current [`World`] by modifying the [`DefaultSystemErrorHandler`]. //! - [`Schedule::set_error_handler`] sets the error handler for all systems of that schedule. //! //! Bevy provides a number of pre-built error-handlers for you to use: @@ -76,5 +76,7 @@ mod handler; pub use bevy_error::*; pub use handler::*; -/// A result type for use in fallible systems. +/// A result type for use in fallible systems, commands and observers. +/// +/// The [`BevyError`] type is a type-erased error type with optional Bevy-specific diagnostics. pub type Result = core::result::Result;