Implementing routines in PL/Perl