Last active
August 29, 2015 13:56
-
-
Save syachi/9263900 to your computer and use it in GitHub Desktop.
Data::DumperでUTF-8を表示させる
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package Dumper; | |
use utf8; | |
use base 'Exporter'; | |
our @EXPORT = qw/Dumper/; | |
use Data::Dumper; | |
no warnings 'redefine'; | |
sub Dumper | |
{ | |
my $dump = Data::Dumper::Dumper(@_); | |
$dump =~ s/\\x\{([0-9A-Za-z]{4})\}/pack('U',hex($1))/ge; | |
$dump; | |
} | |
1; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment