Apache-LoggedAuthDBI
view release on metacpan or search on metacpan
$diff ||= "Strings contain the same sequence of characters"
if length($a);
$diff .= "\n" if $diff;
return "a: $a_desc\nb: $b_desc\n$diff";
}
sub data_string_diff {
# Compares 'logical' characters, not bytes, so a latin1 string and an
# an equivalent unicode string will compare as equal even though their
# byte encodings are different.
my ($a, $b) = @_;
unless (defined $a and defined $b) { # one undef
return ""
if !defined $a and !defined $b;
return "String a is undef, string b has ".length($b)." characters"
if !defined $a;
return "String b is undef, string a has ".length($a)." characters"
if !defined $b;
}
( run in 0.430 second using v1.01-cache-2.11-cpan-88abd93f124 )