[Numpy-discussion] Lists in fromfile shape?

Magnus Lie Hetland magnus at hetland.org
Tue Dec 31 07:49:03 EST 2002


I just noticed that the shape argument in fromfile cannot be an
unhashable sequence. I assume tuples are the norm, but still -- it
would be nice to accept other sequences?

And... I also saw an explicit type check in fromfile, comparing
_type(file) with _type("") -- what if I supplied some other
string-like object? Perhaps a try/except with file+"" would be
appropriate, to check for "string-like-ness" instead of an explicit
type check? (I've just grown suspicious of typechecking in general...)

Sorry if I'm being a pest, nagging about all these details, but I
expect it may be useful to get them resolved? :]

-- 
Magnus Lie Hetland
http://hetland.org




More information about the NumPy-Discussion mailing list