Skip Menu |
 

This queue is for tickets about the Unicode-UTF8 CPAN distribution.

Report information
The Basics
Id: 127007
Status: new
Priority: 0/
Queue: Unicode-UTF8

People
Owner: Nobody in particular
Requestors: Stephan.M.Latta-nr [...] raytheon.com
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



Subject: Unicode::UTF8 Testing bug
Date: Fri, 31 Aug 2018 15:10:20 +0000
To: "bug-Unicode-UTF8 [...] rt.cpan.org" <bug-Unicode-UTF8 [...] rt.cpan.org>
From: Stephan Latta <Stephan.M.Latta-nr [...] raytheon.com>
Download (untitled) / with headers
text/plain 1.5k
Christian, I'm working on a project that requires me to create a 32-bit and 64-bit version of Perl v5.28.0. During the inclusion of your Unicode::UTF8 module, I noticed that the 080_super.t test case does not take into account the Perl bit architecture and thus fails on a 32-bit Perl version. An plausible updated version of the test is shown below: #!perl use Config; ### Inclusion of the Config module use strict; use warnings; use lib 't'; use Test::More tests => 1537; use Util qw[throws_ok]; BEGIN { use_ok('Unicode::UTF8', qw[ encode_utf8 ]); } my @SUPER = (); { for (my $i = 0x0011_0000; $i < 0x7FFF_FFFF; $i += 0x200000) { push @SUPER, $i; } ### ### 64-bit ptrsize validation against the Config module ### if ($Config{ptrsize} == 8) { for (my $i = 0x8000_0000; $i < 0xFFFF_FFFF; $i += 0x400000) { push @SUPER, $i; } } } foreach my $cp (@SUPER) { my $name = sprintf 'encode_utf8("\\x{%.4X}") super U-%.8X', $cp, $cp; my $string = do { no warnings 'utf8'; pack('U', $cp) }; throws_ok { use warnings FATAL => 'utf8'; encode_utf8($string); } qr/Can't represent super code point/, $name; } Kind Regards, Stephan M. Latta NISSC Software Engineer Raytheon / Braxton Technologies 1330 Inverness Drive, Suite 450-1 Colorado Springs, CO 80910 Voice: (719) 622-2269<tel:%28719%29%20637-4286> E-mail: stephan.m.latta-nr@raytheon.com<mailto:stephan.m.latta-nr@raytheon.com> [Braxton_logo]<http://www.braxtontech.com/>
Download image001.jpg
image/jpeg 2.9k
image001.jpg


This service is sponsored and maintained by Best Practical Solutions and runs on Perl.org infrastructure.

Please report any issues with rt.cpan.org to rt-cpan-admin@bestpractical.com.