Re: length of an array in a struct in an array of structs in a struct in an array of structs



Tuan Bui wrote:
> Paul Lalli wrote:
> > Tuan Bui wrote:
> > > I do know that
> > >
> > > scalar(@{@VisitArray[$i]->PSearchStructArray})
> > >
> > > will return the length of PSearchStructArray well enough though.
> >
> > Perhaps I'm having a brain cramp here, but I can't especially see how
> > that could work. The arrow notation is used for either A)
> > dereferencing a hash or array reference to get at its elements or B)
> > calling a method of an object or class.
>
> I am using Class::Struct, and indeed i am implicitly calling methods
> from it. It indeed returns the correct lengths that I want.

Ahh, when you said you had structs, you actually meant structs, as in
objects of Class::Struct. My apolgies - I kinda through that word out
as a "doesn't mean what you think it means" when I scanned your
original post.

I'm reading up on Class::Struct as we speak. Much obliged.

Paul Lalli

.



Relevant Pages