Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove redundant #[cfg] conditions from backend/direct.rs. #2811

Merged
merged 1 commit into from
Jun 26, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 0 additions & 3 deletions wgpu/src/backend/direct.rs
Original file line number Diff line number Diff line change
Expand Up @@ -47,15 +47,13 @@ impl Context {
))
}

#[cfg(any(not(target_arch = "wasm32"), feature = "webgl"))]
pub unsafe fn instance_as_hal<A: wgc::hub::HalApi, F: FnOnce(Option<&A::Instance>) -> R, R>(
&self,
hal_instance_callback: F,
) -> R {
self.0.instance_as_hal::<A, F, R>(hal_instance_callback)
}

#[cfg(any(not(target_arch = "wasm32"), feature = "webgl"))]
pub unsafe fn from_core_instance(core_instance: wgc::instance::Instance) -> Self {
Self(wgc::hub::Global::from_instance(
wgc::hub::IdentityManagerFactory,
Expand Down Expand Up @@ -83,7 +81,6 @@ impl Context {
self.0.create_adapter_from_hal(hal_adapter, PhantomData)
}

#[cfg(any(not(target_arch = "wasm32"), feature = "webgl"))]
pub unsafe fn adapter_as_hal<A: wgc::hub::HalApi, F: FnOnce(Option<&A::Adapter>) -> R, R>(
&self,
adapter: wgc::id::AdapterId,
Expand Down