Well you can't even assign a scalar to an @array to preallocate size,
the way you can assign to $#array.  @array = 8 always creates an array
with a single element, namely 8.  So I am pretty sure you're screwed
trying to make perl do what you want.  Maybe you couldjust  *read* the
scalar value via $#array too, with the appropriate modification to
FETCHSIZE?

Did you check out Tie::VecArray or Bit::Vector::Minimal ?  T::VA is
pretty close to what you're trying to do, maybe you can use it instead.


 -- Jeremy


On Tue, 2004-01-13 at 17:33, [EMAIL PROTECTED] wrote:

> I want to create a tied array to simplify 
> using bit vectors.
...
> why is it that during FETCHSIZE
> I can use @arr, like I do in the print statement.
> But when I want to invoke STORESIZE, I have to
> use $#arr instead of @arr=8;  ???
> 
> shouldn't @arr be scalar context unless it
> is fetching or storing a list? if I wanted to
> store a list into @arr, I would have said
> @arr = ( 10 );


_______________________________________________
Boston-pm mailing list
[EMAIL PROTECTED]
http://mail.pm.org/mailman/listinfo/boston-pm

Reply via email to