Chars / Str type
Christopher Armstrong
radix at twistedmatrix.com
Mon Jul 16 16:43:25 BST 2007
To continue this really boring discussion (which originally started on
IRC), I have some more points.
I think the choice of the name "Chars" was a mistake for the 0.9
release of Storm. I assume the choice of name was based on a context
of knowledge of the C "char*" type, or something. There are two big
problems with this, though:
* The english word "character" doesn't restrict itself to those things
defined in ASCII
* Databases commonly use "Char" and "Varchar" to refer to *unicode*
data, or at least auto-en/decoded data. I realized how confusing this
was when I was drafting a table of Storm properties to database-level
types. I had to say "For CHAR and VARCHAR types, use Unicode(); for
BYTEA and BINARY types, use Chars()".
I think "Binary" would probably be a better name for this thing than
"Chars", even though "Binary" is a totally meaningless word when it
comes to anything other than 0s or 1s, but at least it doesn't have
those two major flaws.
--
Christopher Armstrong
International Man of Twistery
http://radix.twistedmatrix.com/
http://twistedmatrix.com/
http://canonical.com/
More information about the storm
mailing list