Syntactic Confectionery Delight | |
PerlMonks |
comment on |
( [id://3333]=superdoc: print w/replies, xml ) | Need Help?? |
eq is supposed to "ignore types" it's just comparing the stringified arguments
eq: Binary "eq" returns true if the left argument is stringwise equal to the right argument. so two arguments mapped to the same string are "equal". I think you want something like === in JS¹, IMHO you have to construct this on your own.
Cheers Rolf UPDATE: repaired broken link to [doc://eq]
(¹) an approach with operator overloading can be found here: In reply to Re: What is the best way to compare variables so that different types are non-equal?
by LanX
|
|