Hi all,
I've recently been looking at a bug with the new try/catch syntax in
core:
https://github.com/Perl/perl5/issues/18855
It has me thinking that this sort of bug ought really to have been
caught well before 5.34.0, earlier in the 5.33.x development series. I
think a reason it wasn't is because not many people are actually making
use of this. Perhaps understandable given it was "only" a development
release, but now it's out in the wild in a real production version
perhaps there will be more eyeballs on it.
What we need here is more folks to actually use this new feature in
real code to check whether it actually works for real.
So how can you help?
1) If you're already using `Syntax::Keyword::Try`, simply change that
to
use Feature::Compat::Try;
This will pull in S-K-T on older perls, or simply enable the
core 'try' feature on 5.34 onwards.
2) If you're using some other try-providing syntax module and you
don't need to support older than 5.34, you can
use feature 'try';
and adjust your uses of the syntax accordingly (exactly what
changes to make will depend on what other module you're already
using).
If you do need pre-5.34 compatibility as well, then I suggest using
Feature::Compat::Try, as per above.
3) If you don't have any form of module for providing a `try`-like
syntax and are instead using plain ol' `eva{}`, well then now may
be a perfect opportunity to give this a test. Either of the above
techniques would do that - depending whether you need to support
older than 5.34 or not.
--
Paul "LeoNerd" Evans
leonerd@leonerd.org.uk | https://metacpan.org/author/PEVANS
http://www.leonerd.org.uk/ | https://www.tindie.com/stores/leonerd/
I've recently been looking at a bug with the new try/catch syntax in
core:
https://github.com/Perl/perl5/issues/18855
It has me thinking that this sort of bug ought really to have been
caught well before 5.34.0, earlier in the 5.33.x development series. I
think a reason it wasn't is because not many people are actually making
use of this. Perhaps understandable given it was "only" a development
release, but now it's out in the wild in a real production version
perhaps there will be more eyeballs on it.
What we need here is more folks to actually use this new feature in
real code to check whether it actually works for real.
So how can you help?
1) If you're already using `Syntax::Keyword::Try`, simply change that
to
use Feature::Compat::Try;
This will pull in S-K-T on older perls, or simply enable the
core 'try' feature on 5.34 onwards.
2) If you're using some other try-providing syntax module and you
don't need to support older than 5.34, you can
use feature 'try';
and adjust your uses of the syntax accordingly (exactly what
changes to make will depend on what other module you're already
using).
If you do need pre-5.34 compatibility as well, then I suggest using
Feature::Compat::Try, as per above.
3) If you don't have any form of module for providing a `try`-like
syntax and are instead using plain ol' `eva{}`, well then now may
be a perfect opportunity to give this a test. Either of the above
techniques would do that - depending whether you need to support
older than 5.34 or not.
--
Paul "LeoNerd" Evans
leonerd@leonerd.org.uk | https://metacpan.org/author/PEVANS
http://www.leonerd.org.uk/ | https://www.tindie.com/stores/leonerd/