develooper Front page | perl.perl5.porters | Postings from September 2016

Re: pounding the smartmatch drum

Thread Previous | Thread Next
September 5, 2016 13:51
Re: pounding the smartmatch drum
Message ID:
We should either fix it or kill it.  Fixing it should take the form of
reducing the matching behaviour table to just a handful of rows, of which
the main one relies on ~~ overloading on the rhs.  Tony's branch mostly
does this.  However, I disagree with permitting overloading on the lhs.
That part of Tony's branch (which is also not properly documented) should
be ripped out.  The type of matching to perform should be determined
entirely by the rhs, and any type of matching that amounts to "ask
the lhs whether it matches" is too surprising and not useful enough to
warrant being a built-in matching rule.


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