Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl Monk, Perl Meditation
 
PerlMonks  

Re^4: Shouldn't references be readonly?

by LanX (Cardinal)
on Aug 05, 2020 at 13:40 UTC ( #11120318=note: print w/replies, xml ) Need Help??


in reply to Re^3: Shouldn't references be readonly?
in thread Shouldn't LITERAL references be readonly? (updated)

Im asking about logic and you are arguing with implementation.

I haven't seen a logical reason why Perl shouldn't throw an error if the alias to a ref is overwritten.

My suspicion is that the ugly truth is that the readonly flag is (mis)used for indicating if the referenced data structure is "constant" not the reference itself.

Cheers Rolf
(addicted to the Perl Programming Language :)
Wikisyntax for the Monastery

  • Comment on Re^4: Shouldn't references be readonly?

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://11120318]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others imbibing at the Monastery: (3)
As of 2020-09-30 02:42 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    If at first I donít succeed, I Ö










    Results (157 votes). Check out past polls.

    Notices?