In order to remove XPIDL interfaces when corresponding Web Platform features are available, I've been trying to get our internal JS code to switch from nsIScriptableUnicodeConverter to TextDecoder and TextEncoder.
The main problem is that XPCOM streams expose binary buffers as JS strings where the lower half of each UTF-16 code unit is a byte value whereas new Web Platform APIs use Uint8Array for binary. It seems that we have some Uint8Array support in XPIDL, but it involves rather complicated XPIDL syntax, so it's easier to figure out how to use ACString. Do we have the following and documentation is just lacking? If not, should we have these? * Ability to declare Uint8Array in XPIDL with the same ease as ACString * Ability to pass a Uint8Array from JS to an XPIDL method that takes an ACString * Have a method in nsIScriptableInputStream to read an Uint8Buffer with the same ease as reading the string and without the complication of nsIBinaryInputStream.readArrayBuffer(). -- Henri Sivonen [email protected] https://hsivonen.fi/ _______________________________________________ dev-platform mailing list [email protected] https://lists.mozilla.org/listinfo/dev-platform

