Skip Menu |

This queue is for tickets about the Text-Levenshtein CPAN distribution.

Report information
The Basics
Id: 36686
Status: rejected
Priority: 0/
Queue: Text-Levenshtein

People
Owner: JGOLDBERG [...] cpan.org
Requestors: bkb [...] cpan.org
Cc:
AdminCc:

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



Subject: utf8 problems
The routine works correctly with utf8, but prints out nonsense to STDERR when processing: ben ~ 634 $ ./lev.pl substr outside of string at /usr/local/lib/perl5/site_perl/5.10.0/Text/Levenshtein.pm line 49. Use of uninitialized value in string eq at /usr/local/lib/perl5/site_perl/5.10.0/Text/Levenshtein.pm line 49. 2 See attached file (utf8 format) for test case. Replacing with ASCII returns it to normal behaviour.
Subject: lev.pl
#!/usr/local/bin/perl -w use strict; use Text::Levenshtein 'distance'; use utf8; my $haystack = 'かきくけこ'; my $needle = 'かきく'; $haystack = 'boboi'; $needle = 'babi'; print distance ($needle, $haystack),"\n";
The script provided gave me expected result of 2. If I had more system information from the tester it would be a useful bug report. Perhaps utf8 is not properly implemented on the reporter's system or they are using a different version of perl than the systems I have tested on.