in reply to split...or better?

my ($matched) = "foo.bar.aaa" =~ /^(.*?)\./;