Author: lwall Date: 2009-11-28 22:07:44 +0100 (Sat, 28 Nov 2009) New Revision: 29205
Modified: docs/Perl6/Spec/S03-operators.pod docs/Perl6/Spec/S04-control.pod Log: [S03,S04] more treatment of .true as highlevel, .Bool as lowlevel Modified: docs/Perl6/Spec/S03-operators.pod =================================================================== --- docs/Perl6/Spec/S03-operators.pod 2009-11-28 20:56:54 UTC (rev 29204) +++ docs/Perl6/Spec/S03-operators.pod 2009-11-28 21:07:44 UTC (rev 29205) @@ -15,8 +15,8 @@ Created: 8 Mar 2004 - Last Modified: 20 Nov 2009 - Version: 180 + Last Modified: 28 Nov 2009 + Version: 181 =head1 Overview @@ -3503,11 +3503,12 @@ when False {...} } -because it will always choose the C<True> case. Instead use something like: +because it will always choose the C<True> case. Instead use something like +a conditional context uses: given $boolean { - when .true {...} - when .not {...} + when .Bool.Int.true {...} + when .Bool.Int.not {...} } Better, just use an C<if> statement. Modified: docs/Perl6/Spec/S04-control.pod =================================================================== --- docs/Perl6/Spec/S04-control.pod 2009-11-28 20:56:54 UTC (rev 29204) +++ docs/Perl6/Spec/S04-control.pod 2009-11-28 21:07:44 UTC (rev 29205) @@ -1125,7 +1125,7 @@ exception, and if the old main exception is not marked as handled, it is pushed onto the internal list of unhandled exceptions. -If you test a C<Failure> for C<.defined> or C<.true>, it causes C<$!> +If you test a C<Failure> for C<.defined> or C<.Bool>, it causes C<$!> to mark the main exception as I<handled>; the exception acts as a relatively harmless undefined value thereafter. Any other use of the C<Failure> object to extract a normal value will throw its associated