diff options
author | Jarkko Hietaniemi <jhi@iki.fi> | 2001-05-05 18:16:00 +0000 |
---|---|---|
committer | Jarkko Hietaniemi <jhi@iki.fi> | 2001-05-05 18:16:00 +0000 |
commit | 83df6a1d65c0fba9c27c7fb715fa674b03462cf0 (patch) | |
tree | 0a054e0b4530814c38513f458ed5af5083134f14 /pod/perlsyn.pod | |
parent | 8fc2f983bc0c066c9be215d0b6cf72814390f573 (diff) | |
download | perl-83df6a1d65c0fba9c27c7fb715fa674b03462cf0.tar.gz |
Updates on the pods related to the modules included since 5.6.
TODO: perltodo really could use major updating.
p4raw-id: //depot/perl@9998
Diffstat (limited to 'pod/perlsyn.pod')
-rw-r--r-- | pod/perlsyn.pod | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/pod/perlsyn.pod b/pod/perlsyn.pod index aad4efd2f7..9d0c9209ea 100644 --- a/pod/perlsyn.pod +++ b/pod/perlsyn.pod @@ -393,8 +393,18 @@ structures. } There is no official C<switch> statement in Perl, because there are -already several ways to write the equivalent. In addition to the -above, you could write +already several ways to write the equivalent. + +However, starting from Perl 5.8 to get switch and case one can use +the Switch extension and say: + + use Switch; + +after which one has switch and case. It is not as fast as it could be +because it's not really part of the language (it's done using source +filters) but it is available, and it's very flexible. + +In addition to the above BLOCK construct, you could write SWITCH: { $abc = 1, last SWITCH if /^abc/; |