On Thu, 28 Jun 2007 05:57:09 +0200, Cameron McCormack <[EMAIL PROTECTED]>
wrote:
For sequence<octet> it would be really nice if we could have a more
native representation of a byte array than a UTF-16 string.
Strange, I really should have used sequence<unsigned short> there.
Fixed.
I still am a little unsettled by the special casing of
sequence<unsigned short> for string values.
We could revisit the decision not to use wstring, and just state that
wstrings must be sequences of UTF-16 code units, and that they can
include 0x0000.
It would still be very good to have an octet / byte representation in
ECMAScript. I'm aware of a couple of implementations of such a thing, but
I haven't been able to play with them or figure out how they work exactly
myself:
1. XMLHttpRequest has a responseBody member in Internet Explorer 7 that
returns an array of unsigned integers representing octets.
Likewise, the send() method accepts such an array.
2. I heard Adobe Flex has some notion of a byte array to represent files.
--
Anne van Kesteren
<http://annevankesteren.nl/>
<http://www.opera.com/>