develooper Front page | perl.perl6.language | Postings from July 2006

Re: ===, =:=, ~~, eq and == revisited (blame ajs!) -- Explained

Thread Previous | Thread Next
July 14, 2006 06:27
Re: ===, =:=, ~~, eq and == revisited (blame ajs!) -- Explained
Message ID:
Yuval Kogman writes:

> On Fri, Jul 14, 2006 at 11:42:24 +0100, Smylers wrote:
> > Or rather, while I can manage to read an explanation of what one of
> > these operators does and see how it applies to the variables in the
> > examples next to it, I am struggling to retain a feeling of _why_ I
> > would want to use any of these operators in real-life Perl 6 code.
> To compare deep structures ;-)

Thank you.  That helps.

My initial instinct was that this meant the new operators can all be
dismissed as ignorable by learners, as they won't be using nested data
structures anyway.

But actually "deep" doesn't have to be very deep in order for such a
comparison op to have use: merely wanting to see if the contents of 2
arrays are the same doesn't involve any nesting and is a concept that is
well within the grasp of a beginner.

> so I'll explain more later.

Great.  I appreciate your help, and I'm looking forward to your
explanation of the different behaviours in this thread.


Thread Previous | Thread Next Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About