in reply to regex and embedded perl code

The issue is that the compilation of the (?{...}) in the regex creates closures on $year, $month and $day and the second time through the sub the my ($year, $month, $day); creates different instances of the variables which are not the ones the regex is using. Change my ($year,$month,$day); to our ($year,$month,$day);.


DWIM is Perl's answer to Gödel