Arrays are arrays regardless of what they're arrays of. So it would be
strange for arrays of certain things to have properties that other
arrays don't have and bitwise ops don't make sense for arrays of, say,
strings.
Also some processors support these sizes natively but wouldn't support
a [4096]byte natively. On processors that don't support all or some of
these sizes it would need to fake it by doing m operations† but that's
bounded and if, for example, the target processor supports 256 bit but
not 512 bit values it can use two 256 ORs instead of four 64 bit ORs.
Maybe that could be made to work in general and if so that would be
great but it's not the only benefit of these types.
† except for shifts, those would have to deal with carries. That may
be a problem, but I think even then it should be fast enough to not be
an issue the way faking div or something very expensive like that
would be.
> --
> You received this message because you are subscribed to the Google Groups "golang-nuts" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to
golang-nuts...@googlegroups.com.
> To view this discussion on the web visit
https://groups.google.com/d/msgid/golang-nuts/1f0329c1-8b82-4683-999e-62b9a046c0a8n%40googlegroups.com.