Dag Sverre Seljebotn, 03.12.2010 20:40: > Well, you don't loose anything with > > cdef double complex x = obj > > either, and it just seems a bit confusing to let "x.real = ..." have > subtly different meaning.
True. Maybe aliasing "complex" to "double complex" isn't a simple after all. > How about this: When you write > > x.real = 4 > > it actually "means" > > x = 4 + x.imag * 1j > > similar to how += works with immutable objects. That is: We allow it to > happen, but it should be understood that no Python object is actually > modified, but that the behaviour is that the "object" is replaced.. Yuck! That's evil. Stefan _______________________________________________ Cython-dev mailing list [email protected] http://codespeak.net/mailman/listinfo/cython-dev
