From 03b989c23544683cc6eb086df7356d99e96324bd Mon Sep 17 00:00:00 2001 From: Leo Kettmeir Date: Tue, 20 Sep 2022 03:54:25 +0100 Subject: [PATCH] Upstream denoland/deno#15853 (#3038) Co-authored-by: Vicary A --- deno_webgpu/src/01_webgpu.js | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/deno_webgpu/src/01_webgpu.js b/deno_webgpu/src/01_webgpu.js index 5643d4243a..f3091baeac 100644 --- a/deno_webgpu/src/01_webgpu.js +++ b/deno_webgpu/src/01_webgpu.js @@ -24,7 +24,6 @@ Error, MathMax, ObjectDefineProperty, - ObjectFreeze, ObjectPrototypeIsPrototypeOf, Promise, PromiseAll, @@ -346,8 +345,8 @@ const inner = new InnerGPUDevice({ rid, adapter: this, - features: ObjectFreeze(features), - limits: ObjectFreeze(limits), + features: createGPUSupportedFeatures(features), + limits: createGPUSupportedFeatures(limits), }); return createGPUDevice( descriptor.label, @@ -746,8 +745,8 @@ * @typedef InnerGPUDeviceOptions * @property {GPUAdapter} adapter * @property {number | undefined} rid - * @property {GPUFeatureName[]} features - * @property {object} limits + * @property {GPUSupportedFeatures} features + * @property {GPUSupportedLimits} limits */ class InnerGPUDevice { @@ -755,9 +754,9 @@ adapter; /** @type {number | undefined} */ rid; - /** @type {GPUFeatureName[]} */ + /** @type {GPUSupportedFeatures} */ features; - /** @type {object} */ + /** @type {GPUSupportedLimits} */ limits; /** @type {WeakRef[]} */ resources;