We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
This may be cockpit error, but it seems to me that Readonly::Clone misbehaves when applied to a scalar which is a hashref:
my $original = { AA => [1..3], BB => { X => 5 }, }; my $ro; Readonly::Scalar $ro => $original; my $rw = Readonly::Clone $ro;
The resulting $rw is not a mutable copy of $ro, but is a scalar ref to a READ-ONLY copy of $ro.
$rw = \{'AA' => [1,2,3],'BB' => {'X' => 5}};
I was expecting an exact mirror image of $rw, with everything below mutable. I'll attach a demo script.
Readonlyscript.txt
The text was updated successfully, but these errors were encountered:
No branches or pull requests
This may be cockpit error, but it seems to me that Readonly::Clone misbehaves when applied to a scalar which is a hashref:
The resulting $rw is not a mutable copy of $ro, but is a scalar ref to a READ-ONLY copy of $ro.
I was expecting an exact mirror image of $rw, with everything below mutable.
I'll attach a demo script.
Readonlyscript.txt
The text was updated successfully, but these errors were encountered: