X-Git-Url: http://git.shiar.net/sheet.git/blobdiff_plain/97f850c55daaf35929b87fdc7f335556d17e0edc..d74545af2334960d43ae45714b4eddb5ecdbd528:/tools/mkdigraphs-plan9 diff --git a/tools/mkdigraphs-plan9 b/tools/mkdigraphs-plan9 index 54b8b3c..31bab3c 100755 --- a/tools/mkdigraphs-plan9 +++ b/tools/mkdigraphs-plan9 @@ -5,7 +5,7 @@ use utf8; use open IO => ':utf8', ':std'; use Data::Dump 'pp'; -our $VERSION = '1.00'; +our $VERSION = '1.01'; # translation table for deprecated code points my %replace = ( @@ -23,8 +23,9 @@ say "# automatically generated by $0"; say 'use utf8;'; say '+{'; while ($_ = readline) { - my ($chrhex, $mnems, $sample, $name) = m{\A([0-9A-F]{4}) (.{11}) (.)\t(.*)}i + my ($chrhex, $mnems, $sample, $name) = m{\A([0-9A-F ]{5}) (.{11}) (.)\h(.*)}i or warn("syntax error on line $.: $_"), next; + $chrhex =~ s/ $//; my $chrnum = hex $chrhex; my $chr = chr $chrnum; $chr eq $sample