in reply to Re^5: ref eq "REF"
in thread ref == "REF"
My problem arises from a seeming inconsistency of the concept "scalar" in Perl. In the guts, there are IVs and NVs and PVs and RVs; but the user just wants his $scalar, with all these possible values conflated. I'd venture to say that this conflation is a widely accepted feature by Perl programmers. Note how another, well-known breach of this generalization — you can't use references as hash keys — is often regarded as suprising (and frustrating) behavior the first time someone encounters it (I think!). Certainly from the user perspective, of the Perl language, it isn't a useful feature, but presumably it makes more sense from the implementation, perl, point of view.
So is ref returning REF on \\"moose" just some leftover hairiness? Or is there a nice hack waiting to be found here?
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^7: ref eq "REF"
by revdiablo (Prior) on Oct 18, 2004 at 20:09 UTC | |
by gaal (Parson) on Oct 18, 2004 at 20:31 UTC | |
by revdiablo (Prior) on Oct 18, 2004 at 23:18 UTC | |
by gaal (Parson) on Oct 19, 2004 at 10:00 UTC |