Skip to main content

gpu_err

Macro gpu_err 

Source
macro_rules! gpu_err {
    ($($arg:tt)*) => { ... };
}
Expand description

Build a GpuError::DriverCallFailed { reason: format!(...) } value.

Collapses the ubiquitous GpuError::DriverCallFailed { reason: format!("...: {err}") } struct literal into a single call. The macro forwards every argument to format!, so callers retain full control over the message body, including positional / named captures and interpolation of the per-site err binding.