1 parent e114d2f commit 5526e4eCopy full SHA for 5526e4e
1 file changed
wgpu-core/src/device/life.rs
@@ -2,6 +2,7 @@ use alloc::{sync::Arc, vec::Vec};
2
3
use smallvec::SmallVec;
4
use thiserror::Error;
5
+use wgt::error::{ErrorType, WebGpuError};
6
7
use crate::{
8
device::{
@@ -146,6 +147,17 @@ impl WaitIdleError {
146
147
}
148
149
150
+impl WebGpuError for WaitIdleError {
151
+ fn webgpu_error_type(&self) -> ErrorType {
152
+ match self {
153
+ WaitIdleError::Device(device_error) => device_error.webgpu_error_type(),
154
+ WaitIdleError::WrongSubmissionIndex(_, _) | WaitIdleError::Timeout => {
155
+ ErrorType::Internal
156
+ }
157
158
159
+}
160
+
161
/// Resource tracking for a device.
162
///
163
/// ## Host mapping buffers
0 commit comments