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/. */
8 namespace mozilla::webgpu
{
10 GPU_IMPL_CYCLE_COLLECTION(Error
, mGlobal
)
12 Error::Error(nsIGlobalObject
* const aGlobal
, const nsACString
& aMessage
)
14 CopyUTF8toUTF16(aMessage
, mMessage
);
17 Error::Error(nsIGlobalObject
* const aGlobal
, const nsAString
& aMessage
)
18 : mGlobal(aGlobal
), mMessage(aMessage
) {}
20 } // namespace mozilla::webgpu