From: Francesc A. <fa...@op...> - 2003-01-27 19:22:02
|
A Dilluns 27 Gener 2003 17:28, Todd Miller va escriure: > >So, as numarray has to work with previous python versions, there is no > > point to care about that. > > In truth, numarray-0.4 and up already require Python-2.2 and up. Oh!, I didn't know that. In such a case, I think it's worth to consider t= he possibility to define records as classes descendants from metaclasses. Bu= t, of course, you have the ultimate decision. > >>I'm thinking the general format for this may be converting N-tuples o= f > >>types and ints into N arrays of types and ints. And vice versa. > >>It's obvious how this works with numarray types. I think the chararr= ay > >>types need work and need to be mapped into the same integer enumerati= on > >>as the numeric types in a non-overlapping way. > > > >I can't catch your point here. Why there should be a problem with > >chararrays?. > > What I was trying to see is that chararray types are not as well > designed as the numarray types, nor are they reflected in the C-API. I see. Well, is it really desirable such a unification? CharArray entitie= s come from a module and NumArray from another one, and that should be ok. = Why bother in creating a unified API or integer enumeration?. I think this should be not a big drawback for C-extension crafters (although, to say t= he truth, that would be very elegant if you manage to do that, but maybe it = is not worth the effort, I don't know). --=20 Francesc Alted |