digraphs: fix string alternative in character include
authorMischa POSLAWSKY <perl@shiar.org>
Sat, 21 Feb 2015 03:54:06 +0000 (04:54 +0100)
committerMischa POSLAWSKY <perl@shiar.org>
Tue, 9 Jun 2015 03:43:41 +0000 (05:43 +0200)
tools/mkcharinfo

index b58f0c373f6215e828e4ad787683d1cfc23cd114..1cac30ad7ee597fe4f288b7418f5f09e591db184 100755 (executable)
@@ -90,15 +90,15 @@ for my $chr (keys %info) {
        $info->{class}->{Xa}++ if $info->{block} eq 'Basic Latin';
        $info->{class}->{Xl}++ if $info->{block} eq 'Latin-1 Supplement';
 
-       given ($cp) {
-               when ($info->{string}) {
+       {
+               if ($info->{string}) {
                        # keep predefined presentational string
                }
-               when ($info->{combining}) {
+               elsif ($info->{combining}) {
                        # overlay combining accents
                        $info->{string} = chr(9676) . $chr;
                }
-               when (($cp & ~0b1001_1111) == 0 or $cp == 127) {
+               elsif (($cp & ~0b1001_1111) == 0 or $cp == 127) {
                        # control characters (first 32 chars from 0 and 128)
                        # rename to something more descriptive
                        $info->{name} = $info->{unicode10}