Lingua-RU-NameParse
view release on metacpan or search on metacpan
NameParse.pm view on Meta::CPAN
my ( $self, $testme ) = @_;
use utf8;
# voodo to set the string's UTF8 flag
$testme = pack 'U*', unpack( 'U*', $testme );
my ( $w1, $w2 ) = split m/\s+/, $testme;
##################
# ACCUSATIVE
##################
if ( $w2 =~ /[Ñк]а$/ ) {
$w2 =~ s/а$//g;
$w1 =~ s/а$//g;
$w1 =~ s/Ñ$/й/g;
}
( run in 0.901 second using v1.01-cache-2.11-cpan-71847e10f99 )