News for hackers. Stuff that matters.
Re:Recharging the Python standard library by herge on Friday October 11, 2013 @12:00PM (#6533944)
It does make the code a lot clearer to read. There are a lot of other python packages that overload specific operators/magic functions to aid readability. For example, numpy arrays overload the slice operator to great effect.

Also, on the same topic, what about using the '+' operator with strings and lists/tuples for concatenation? Or the '|', '&' and '^' operator for sets (which I have to admit I never use because I can never remember which is which)?

Re:Recharging the Python standard library by falcolas on Friday October 11, 2013 @12:36PM (#6534182)
> It does make the code a lot clearer to read.

If, and only if, you're familiar with how the path library works. I had to shift mental contexts away from python and into shell to understand that it was a "shortcut" for os.path.join(). The division operator is not typically associated with path joining in programming languages.

Frankly, it's not really offering any greater level of abstraction for paths; just shortcuts. You still have to call makedirs, open, write, etc. I don't find the minute improvements to os.path.join that terribly compelling.

Re:Recharging the Python standard library by mattdeboard on Friday October 11, 2013 @02:46PM (#6535071)
I agree. I inherited some code that did this and it was not immediately obvious what was going on. I thought the variables being used where numbers, and I was very confused.