⚝
One Hat Cyber Team
⚝
Your IP:
216.73.216.177
Server IP:
50.6.168.112
Server:
Linux server-617809.webnetzimbabwe.com 5.14.0-570.25.1.el9_6.x86_64 #1 SMP PREEMPT_DYNAMIC Wed Jul 9 04:57:09 EDT 2025 x86_64
Server Software:
Apache
PHP Version:
8.4.10
Buat File
|
Buat Folder
Eksekusi
Dir :
~
/
home
/
.cpan
/
build
/
Storable-3.25-0
/
t
/
View File Name :
tied_store.t
#!./perl sub BEGIN { unshift @INC, 't'; unshift @INC, 't/compat' if $] < 5.006002; require Config; import Config; if ($ENV{PERL_CORE} and $Config{'extensions'} !~ /\bStorable\b/) { print "1..0 # Skip: Storable was not built\n"; exit 0; } } use Storable (); use Test::More tests => 3; our $f; package TIED_HASH; sub TIEHASH { bless({}, $_[0]) } sub STORE { $f = Storable::freeze(\$_[2]); 1; } package TIED_ARRAY; sub TIEARRAY { bless({}, $_[0]) } sub STORE { $f = Storable::freeze(\$_[2]); 1; } package TIED_SCALAR; sub TIESCALAR { bless({}, $_[0]) } sub STORE { $f = Storable::freeze(\$_[1]); 1; } package main; my($s, @a, %h); tie $s, "TIED_SCALAR"; tie @a, "TIED_ARRAY"; tie %h, "TIED_HASH"; $f = undef; $s = 111; is $f, Storable::freeze(\111); $f = undef; $a[3] = 222; is $f, Storable::freeze(\222); $f = undef; $h{foo} = 333; is $f, Storable::freeze(\333); 1;