types
types copied to clipboard
Make some/all input types readonly? (dict members, arrays, tuples)
This way if an application holds a readonly type it can pass it into WebGPU without having to cast it to writable.
Looking at this again, realizing it should apply to all of the dictionary members too, not just arrays.
In practice this is not very much of a problem because TypeScript is extremely lax about readonly enforcement and allows implicit conversion from readonly to writable in a lot of cases. I'm not even aware of warnings or lint options that make it stricter.