On Fri, Aug 04, 2000 at 02:57:45PM -0000, Perl6 RFC Librarian wrote:

> =item 'BOOLEAN'
> 
> The subroutine was called in a boolean context:
> 
>         if ( func() ) {}
>         $val = func() || 0;
>         $val = func() or die;

This one is debateable. BOOLEAN could be seen as asking for a TRUE or FALSE
value, which in the first case is fine. But in the second although the
value is tested for true/false, if it is true it is used, so there should
be some way to determine between them.

And if you are adding values into the context based on the operator, what
about defined() and the mythical ?? operator that someone is bound
to put an RFC in for sooner or later.

Graham.

Reply via email to