Perl Monk, Perl Meditation | |
PerlMonks |
comment on |
( [id://3333]=superdoc: print w/replies, xml ) | Need Help?? |
I'm trying to upgrade some code to run correctly in Perl 5.14. However, I still need it to work in older version of perl. I would like to have certain code execute only if Perl 5.14 is detected. Essentially I'm looking for something similar to the #if MACRO #endif construct in C. My specific use case is that I need use re '/d'; in order for some existing regular expressions to want with 5.14 but earlier Perl versions will give a compile error if I add this pragma. I've searched extensively but I haven't found any information for how to do something like this. So any suggestions would be greatly appreciated. Thanks in advance
|
|