-
Notifications
You must be signed in to change notification settings - Fork 13
Open
Description
use strict;
use warnings;
use LMDB_File qw(:envflags :cursor_op);
use File::Temp;
my $dir = File::Temp::tempdir( CLEANUP => 1 );
my $d = "é";
my $u = "ü";
utf8::upgrade $u;
my $path = "$dir/file";
{
my %hash;
my $db = tie %hash, 'LMDB_File', "$dir/file", MDB_NOSUBDIR;
$hash{$d} = $d;
$hash{$u} = $u;
}
use Data::Dumper;
{
my %hash;
my $db = tie %hash, 'LMDB_File', "$dir/file", MDB_NOSUBDIR;
print Dumper \%hash;
}
… prints:
$VAR1 = {
'ü' => 'ü',
'é' => 'é'
};
The UTF8 option toggles between SvPV and SvPVutf8; it should actually toggle between SvPVbyte and SvPVutf8 to avoid a spurious dependency on Perl’s internal string storage logic.
Metadata
Metadata
Assignees
Labels
No labels