mirror of
https://github.com/gfx-rs/wgpu.git
synced 2024-11-21 22:33:49 +00:00
don't print the scope twice
The scope is already printed by the Display impl of those errors.
This commit is contained in:
parent
ed1e8ecf4b
commit
df7a6defa8
@ -89,7 +89,7 @@ use crate::{
|
||||
AttachmentData, Device, DeviceError, MissingDownlevelFlags, RenderPassContext,
|
||||
SHADER_STAGE_COUNT,
|
||||
},
|
||||
error::{ErrorFormatter, PrettyError},
|
||||
error::PrettyError,
|
||||
hal_api::HalApi,
|
||||
hub::Hub,
|
||||
id,
|
||||
@ -1593,14 +1593,7 @@ impl RenderBundleError {
|
||||
}
|
||||
}
|
||||
}
|
||||
impl PrettyError for RenderBundleError {
|
||||
fn fmt_pretty(&self, fmt: &mut ErrorFormatter) {
|
||||
// This error is wrapper for the inner error,
|
||||
// but the scope has useful labels
|
||||
fmt.error(self);
|
||||
self.scope.fmt_pretty(fmt);
|
||||
}
|
||||
}
|
||||
impl PrettyError for RenderBundleError {}
|
||||
|
||||
impl<T, E> MapPassErr<T, RenderBundleError> for Result<T, E>
|
||||
where
|
||||
|
@ -12,7 +12,7 @@ use crate::{
|
||||
PassErrorScope, PassTimestampWrites, QueryUseError, StateChange,
|
||||
},
|
||||
device::{Device, DeviceError, MissingDownlevelFlags, MissingFeatures},
|
||||
error::{ErrorFormatter, PrettyError},
|
||||
error::PrettyError,
|
||||
global::Global,
|
||||
hal_api::HalApi,
|
||||
hal_label, id,
|
||||
@ -192,14 +192,7 @@ pub struct ComputePassError {
|
||||
#[source]
|
||||
pub(super) inner: ComputePassErrorInner,
|
||||
}
|
||||
impl PrettyError for ComputePassError {
|
||||
fn fmt_pretty(&self, fmt: &mut ErrorFormatter) {
|
||||
// This error is wrapper for the inner error,
|
||||
// but the scope has useful labels
|
||||
fmt.error(self);
|
||||
self.scope.fmt_pretty(fmt);
|
||||
}
|
||||
}
|
||||
impl PrettyError for ComputePassError {}
|
||||
|
||||
impl<T, E> MapPassErr<T, ComputePassError> for Result<T, E>
|
||||
where
|
||||
|
@ -20,7 +20,7 @@ use crate::{
|
||||
AttachmentData, Device, DeviceError, MissingDownlevelFlags, MissingFeatures,
|
||||
RenderPassCompatibilityError, RenderPassContext,
|
||||
},
|
||||
error::{ErrorFormatter, PrettyError},
|
||||
error::PrettyError,
|
||||
global::Global,
|
||||
hal_api::HalApi,
|
||||
hal_label, id,
|
||||
@ -738,14 +738,7 @@ pub struct RenderPassError {
|
||||
#[source]
|
||||
pub(super) inner: RenderPassErrorInner,
|
||||
}
|
||||
impl PrettyError for RenderPassError {
|
||||
fn fmt_pretty(&self, fmt: &mut ErrorFormatter) {
|
||||
// This error is wrapper for the inner error,
|
||||
// but the scope has useful labels
|
||||
fmt.error(self);
|
||||
self.scope.fmt_pretty(fmt);
|
||||
}
|
||||
}
|
||||
impl PrettyError for RenderPassError {}
|
||||
|
||||
impl<T, E> MapPassErr<T, RenderPassError> for Result<T, E>
|
||||
where
|
||||
|
Loading…
Reference in New Issue
Block a user