diff options
author | Simon Sapin <simon.sapin@exyr.org> | 2017-10-14 12:54:57 +0200 |
---|---|---|
committer | Simon Sapin <simon.sapin@exyr.org> | 2017-10-16 20:19:56 +0200 |
commit | e2fafd2dfc7a1b66fb224c83e15042d8f6d595c0 (patch) | |
tree | 51fa54657e9b0dddc4a0e1f6dc660c8943284335 /components/script/dom/vrstageparameters.rs | |
parent | 115d859551323c821beb412d550c6dacbcdd5e23 (diff) | |
download | servo-e2fafd2dfc7a1b66fb224c83e15042d8f6d595c0.tar.gz servo-e2fafd2dfc7a1b66fb224c83e15042d8f6d595c0.zip |
Replace NonZero<*mut JSObject> with a wrapper to enable local trait impls.
Diffstat (limited to 'components/script/dom/vrstageparameters.rs')
-rw-r--r-- | components/script/dom/vrstageparameters.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/components/script/dom/vrstageparameters.rs b/components/script/dom/vrstageparameters.rs index 8996f0fdbad..a2a185fd6cc 100644 --- a/components/script/dom/vrstageparameters.rs +++ b/components/script/dom/vrstageparameters.rs @@ -2,10 +2,10 @@ * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ -use core::nonzero::NonZero; use dom::bindings::cell::DomRefCell; use dom::bindings::codegen::Bindings::VRStageParametersBinding; use dom::bindings::codegen::Bindings::VRStageParametersBinding::VRStageParametersMethods; +use dom::bindings::nonnull::NonNullJSObjectPtr; use dom::bindings::num::Finite; use dom::bindings::reflector::{DomObject, Reflector, reflect_dom_object}; use dom::bindings::root::DomRoot; @@ -69,8 +69,8 @@ impl VRStageParameters { impl VRStageParametersMethods for VRStageParameters { #[allow(unsafe_code)] // https://w3c.github.io/webvr/#dom-vrstageparameters-sittingtostandingtransform - unsafe fn SittingToStandingTransform(&self, _cx: *mut JSContext) -> NonZero<*mut JSObject> { - NonZero::new_unchecked(self.transform.get()) + unsafe fn SittingToStandingTransform(&self, _cx: *mut JSContext) -> NonNullJSObjectPtr { + NonNullJSObjectPtr::new_unchecked(self.transform.get()) } // https://w3c.github.io/webvr/#dom-vrstageparameters-sizex |