#876738 better 'when' examples

Package:
perl-doc
Source:
perl
Submitter:
積丹尼 Dan Jacobson
Date:
2017-09-25 12:48:04 UTC
Severity:
wishlist
#876738#5
Date:
2017-09-25 11:43:19 UTC
From:
To:
The man page says

       The "when" modifier is an experimental feature that first appeared in
       Perl 5.14.  To use it, you should include a "use v5.14" declaration.

However the man page contradicts itself, instead giving two examples
using v5.10.1, e.g.,

           use v5.10.1;
           for ($var) {
               when (/^abc/) { $abc = 1 }
               when (/^def/) { $def = 1 }
               when (/^xyz/) { $xyz = 1 }
               default       { $nothing = 1 }
           }

Also there is a space missing in "frequentlythe".