Nigel Wetters wrote: > On Wed, 2002-12-11 at 13:55, Ruth Albocher wrote: > > I need to "cast" a scalar reference (SCALAR0x9999) into a reference to > > an object that I can use. (in other words, bless it). > > How can I do it? > > my $object = bless $scalar_reference, 'Your::Class'; >
well, it's a bit more complicated than that. I am tie-ing an array that represents memory, and its size should be bigger than 2^32. my tied store/fetch methods get a reference to an object I define that allow such numbers (in c++, I am interfacing c++ with perl using swig) The problem is that perl automatically casts my reference to a reference to an interger, and I can't seem to bless it back to my original object, since the reference's guts are already int-scalar typed. any ideas? thanks, ruthie -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]