Backed out 2 changesets (bug 1818237) for causing xpc failures on browser/components...
[gecko.git] / dom / webgpu / InternalError.cpp
blob6cda9673f6540520a092f4828ec8394482348060
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
2 /* This Source Code Form is subject to the terms of the Mozilla Public
3 * License, v. 2.0. If a copy of the MPL was not distributed with this
4 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
6 #include "InternalError.h"
7 #include "mozilla/dom/WebGPUBinding.h"
9 namespace mozilla::webgpu {
11 GPU_IMPL_JS_WRAP(InternalError)
13 already_AddRefed<InternalError> InternalError::Constructor(
14 const dom::GlobalObject& aGlobal, const nsAString& aString,
15 ErrorResult& aRv) {
16 nsCOMPtr<nsIGlobalObject> global = do_QueryInterface(aGlobal.GetAsSupports());
17 MOZ_RELEASE_ASSERT(global);
18 return MakeAndAddRef<InternalError>(global, aString);
21 } // namespace mozilla::webgpu