<font face="courier new,monospace"><br></font><br><div class="gmail_quote">On Fri, Dec 28, 2012 at 10:57 PM, James E Keenan <span dir="ltr"><<a href="mailto:jkeen@verizon.net" target="_blank">jkeen@verizon.net</a>></span> wrote:<br>

<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">On 12/27/12 11:43 PM, Uri Guttman wrote:<br>
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
i want to clarify my statement there. it is the scalar prototype of not<br>
that is causing this as well as its low precedence.<br>
</blockquote>
<br>
I'm familiar with prototypes as an aspect of subroutines in Perl (for instance, Test::More::is is, under the hood, prototyped $$;$), but not with the concept of prototypes for operators.  Can you point me toward the documentation or source code for that?<br>

</blockquote><div><br><br>Don't think about prototypes, its seems you are encountering a precedence issue.<br>Check out the following, and play with variations on the theme:<br><br> perl -e 'use Data::Dumper; sub is {print Dumper($_) foreach (@_); } is(! 1, not 1, "test1");'<br>

<br>$VAR1 = '';<br>$VAR1 = '';<br><br>what you in effect have are<br>arg 1:  ! 1<br>arg 2:  not 1, "test1"<br><br>that is, because of precedence, the latter part effectively becomes<br><br>not (1, "test1")<br>

<br>Then look what happens when you remove the 'not':<br><br>perl -e 'use Data::Dumper; sub is {print Dumper($_) foreach (@_); } is(! 1, 1, "test1");'<br>$VAR1 = '';<br>$VAR1 = 1;<br>$VAR1 = 'test1';<br>

<br>You see the three parameters you think your providing,<br>so what you really wanted is:<br><br>is ( ! 1, (not 1), "test1");<br><br>Fulko<br><br></div></div><br>