summaryrefslogtreecommitdiff
path: root/t/uni/parser.t
diff options
context:
space:
mode:
authorBrian Fraser <fraserbn@gmail.com>2011-08-06 07:55:06 +0100
committerFather Chrysostomos <sprout@cpan.org>2012-03-22 20:23:52 -0700
commite2f06df0a8c96f7d9a5f3214fc5bf2daf34588c3 (patch)
treea1bc5701968fa0828540eb6221e3b3cbfb798135 /t/uni/parser.t
parent734ab32188dca45b1704abc89cd0f08809758da3 (diff)
downloadperl-e2f06df0a8c96f7d9a5f3214fc5bf2daf34588c3.tar.gz
toke.c: 'Unrecognized character' croak cleanup.
Diffstat (limited to 't/uni/parser.t')
-rw-r--r--t/uni/parser.t10
1 files changed, 9 insertions, 1 deletions
diff --git a/t/uni/parser.t b/t/uni/parser.t
index 42c95203c3..5b1c37be3d 100644
--- a/t/uni/parser.t
+++ b/t/uni/parser.t
@@ -7,7 +7,7 @@ BEGIN {
require './test.pl';
}
-plan (tests => 37);
+plan (tests => 38);
use utf8;
use open qw( :utf8 :std );
@@ -100,3 +100,11 @@ our $問 = 10;
is $問, 10, "our works";
is $main::問, 10, "...as does getting the same variable through the fully qualified name";
is ${"main::\345\225\217"}, undef, "..and using the encoded form doesn't";
+
+{
+ use charnames qw( :full );
+
+ eval qq! my \$\x{30cb} \N{DROMEDARY CAMEL} !;
+ is $@, 'Unrecognized character \x{1f42a}; marked by <-- HERE after my $ニ <-- HERE near column 8 at (eval 13) line 1.
+', "'Unrecognized character' croak is UTF-8 clean";
+}