in reply to Compact and sparse bit vector
The only thing is a lot of the time people use vec() specifically because they want the string to be a bit-vector. They dont want to use it as an array of <8 bit units of information so much, as a way to individually control bits in a string with a reasonably syntax.
Although having said that, the problem with vec() in this form is that it doesnt use native byte order, so you cant normally pass it directly into a C routine. So i guess your proposal has some merit...
---
$world=~s/war/peace/g
$world=~s/war/peace/g
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^2: Compact and sparse bit vector
by BrowserUk (Patriarch) on Jan 03, 2009 at 15:00 UTC | |
by demerphq (Chancellor) on Jan 03, 2009 at 18:01 UTC | |
by diotalevi (Canon) on Jan 04, 2009 at 09:30 UTC | |
by BrowserUk (Patriarch) on Jan 04, 2009 at 10:34 UTC |
In Section
Cool Uses for Perl