pub trait CheckNullError
where Self: Null + Sized,
{ // Required method fn nonnull_or_e_handle(self) -> Result<Self>; }

Required Methods§

source

fn nonnull_or_e_handle(self) -> Result<Self>

Passes a non-null self through to an Ok value, or, in case of it being null, returns Err with HRESULT E_HANDLE.

To be used with functions like CreateBitmap() that return a handle type or null, not offering an error code via GetLastError().

Object Safety§

This trait is not object safe.

Implementors§

source§

impl<T> CheckNullError for T
where T: Null,