HEX
Server: Apache
System: Linux box5134.bluehost.com 5.14.0-162.23.1.9991722448259.nf.el9.x86_64 #1 SMP PREEMPT_DYNAMIC Wed Jul 31 18:11:45 UTC 2024 x86_64
User: bqfpihmy (1846)
PHP: 8.2.30
Disabled: NONE
Upload Files
File: //proc/self/root/usr/share/doc/perl-Hash-FieldHash/example/simpleuse.pl
#!perl -w
use strict;

use Hash::FieldHash qw(:all);
use Data::Dumper;

fieldhashes \my(%foo, %bar);;

{
	my $o = [42];
	my $x = {};
	$foo{$o} = 3.14;
	$bar{$o} = 1.14;

	$foo{$x} = 'x.foo';
	$bar{$x} = 'x.bar';

	print "inside the scope:\n";
	print Data::Dumper->Dump([\%foo, \%bar], [qw(*foo *bar)]);

	#my $y = $o;
	#use Devel::Peek; Dump $y;
}

print "outside the scope:\n";
print Data::Dumper->Dump([\%foo, \%bar], [qw(*foo *bar)]);