X-Git-Url: http://git.shiar.nl/sheet.git/blobdiff_plain/466e0b0bee6b61530b0be73a394df19828bf24f9..33f2daf5edc4b89711060babeaf8d674d8482128:/Encode/Wingdings.pm diff --git a/Encode/Wingdings.pm b/Encode/Wingdings.pm index cb553dd..f63ec04 100644 --- a/Encode/Wingdings.pm +++ b/Encode/Wingdings.pm @@ -20,11 +20,13 @@ our @MAP = (qw[ 🡪 🡩 🡫 🡬 🡭 🡯 🡮 🡸 🡺 🡹 🡻 🡼 🡽 🡿 🡾 ⇦ ⇨ ⇧ ⇩ ⬄ ⇳ ⬀ ⬁ ⬃ ⬂ 🢬 🢭 🗶 ✔ 🗷 🗹  ]); +our $NOCHAR = '�'; + sub decode ($$;$) { my ($self, $input, $check) = @_; my $output = ''; for (unpack 'C*', $input) { - $output .= $_ < 33 ? chr : ${ref($self).'::MAP'}[$_ - 33]; + $output .= $_ < 33 ? chr : ${ref($self).'::MAP'}[$_ - 33] // $NOCHAR; } return $output; }