Revision 26241

Date:
2009/04/17 11:36:46
Author:
lwall
Revision Log:
Document the 'when' statement modifier.
Files:

Legend:

 
Added
 
Removed
 
Modified
  • docs/Perl6/Spec/S04-control.pod

     
    12 12
    13 13 Maintainer: Larry Wall <larry@wall.org>
    14 14 Date: 19 Aug 2004
    15 Last Modified: 17 Mar 2009
    15 Last Modified: 17 Apr 2009
    16 16 Number: 4
    17 Version: 74
    17 Version: 75
    18 18
    19 19 This document summarizes Apocalypse 4, which covers the block and
    20 20 statement syntax of Perl.
     
    770 770
    771 771 OUTER.break($retval)
    772 772
    773 There is a C<when> statement modifier, but it does not have any
    774 break semantics. That is,
    775
    776 doit() when 42;
    777
    778 is exactly equivalent to
    779
    780 doit() if $_ ~~ 42;
    781
    773 782 =head1 Exception handlers
    774 783
    775 784 Unlike many other languages, PerlĀ 6 specifies exception handlers by