Unfortunately, this is a bug in IronPython. The bit-wise or '|' is not implemented for all types.
Martin -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Boris Capitanu Sent: Tuesday, November 29, 2005 5:24 PM To: [email protected] Subject: [IronPython] operator problem Hello again. Any reason why the "|" operator in not supported in IronPython? I can see that "or" is supported, but I'd like to be able to say something like: stateChanged |= menuChanged This sort of assignment works under CPython, but not IronPython. IronPython 0.9.5 on .NET 2.0.50727.42 Copyright (c) Microsoft Corporation. All rights reserved. >>> True | False Traceback (most recent call last): at <shell> TypeError: unsupported operand type(s) for |: 'bool' and 'bool' >>> True or False True Boris Capitanu _______________________________________________ users mailing list [email protected] http://lists.ironpython.com/listinfo.cgi/users-ironpython.com _______________________________________________ users mailing list [email protected] http://lists.ironpython.com/listinfo.cgi/users-ironpython.com
