Export to GitHub

pynie - issue #3

[PATCH] Fixed semantics of &, | and ^


Posted on Mar 21, 2009 by Helpful Elephant

Previously, & and | were interpreted as logical-and and logical-or, but in python those are bitwise operators. ^ had the same semantics as **, but should mean bitwise xor. I changed the PIR for these to use the appropriate bitwise operations and to accept arguments of type INT, as in python. True and False are not yet handled.

I added a test for these bitwise operators which was failing but now passes.

Attachments

Comment #1

Posted on Apr 8, 2009 by Happy Elephant

Patch applied. Thank you.

Status: Fixed

Labels:
Type-Defect Priority-Medium