> Instead of focussing on just these two shift operations I wonder if an > analogy with arrays of bits, or strings of bits, could be developed into a > more general interface. Like a splicebits() analogous with splice() or > subbits() analogous with substr(). > > With more specialized functions implemented, or at least specified, in > terms of the general one. > > Just a thought. > > Tim. > I concur. When I was writing Scalar::Vec::Util, I felt like the atomic operation for vec strings really was the copy of bits, from an arbitrary position to another. Shifting, unshifting, splicing and such then seem to be more or less compositions of those. Vincent.Thread Previous | Thread Next