2
我有此腳本獲取參考。預計內容
#!/usr/bin/perl
use warnings;
use strict;
use Data::Dumper;
use YAML::Syck;
my $x = {'x' => [1,2,3],
'y' => {'z' => 8},
'q' => 'abc',
};
my $yaml = YAML::Syck::Load($x);
print "\n" . $yaml . "\n\n\n";
my $h = YAML::Syck::Dump($yaml);
print Dumper $h;
其輸出
HASH(0x7539cb0)
$VAR1 = '--- HASH(0x7539cb0)
';
我希望看到的$x
其內容的結構。那裏有什麼問題?