
In looking through other magic code, I found that when -U was removed. It was only removed from the usage msg. Should the option and code be removed altogether? ie, -U is still used by getopt and still changes the magic, so -U is just a hidden option now.
-U is a handy option for developers wanting to test Unicode conformance of their code, but the help message promised more than it could deliver. Please leave this alone.
There is one other possible problem. [wr]_short() is now only used in one place: for long.digits which are unsigned ints. But r_short() does sign extension. Is this a problem?
Long digits are only 15 bits, so if you change it to return an unsigned short that shouldn't matter. Dunno if there's magic for negative numbers though (in memory, the length is negative, but the digits are not).
--Guido van Rossum (home page: http://www.python.org/~guido/)