Pari Python

J. Cliff Dyer jcd at sdf.lonestar.org
Sun Oct 28 21:26:42 EDT 2007


Anton Mellit wrote:
> And I think (correct me if I am wrong) that the ^ operator (xor) is
> used very very infrequently. And it is not difficult to replace all ^
> with say ^^. 
Oh God!  *Please* don't start that conversation again.  We had a thread
about bitwise operators a few weeks back.  Half the people will pipe up
and say, "Nope, I never use them," and the other half will say, "I can't
live without them."  And the ones who can't live without them tend to be
the ones doing more math-heavy work.

It's not worth messing with the bitwise operators. 
> The division is probably used more often, but python has
> this trend anyway - to replace division with 'true' division, so
> people should use // when they divide integers and expect an integer

If you want to use true division, delay your release until python 3 or
import it from __future__ yourself.  Don't break all current code by
recompiling python to do it.  You'll alienate most of your potential
user base, and develop a reputation for not playing well with others.

Cheers,
Cliff





More information about the Python-list mailing list