Lisandro wrote: > On Fri, May 15, 2009 at 2:03 PM, Dag Sverre Seljebotn > <[email protected]> wrote: >> Lisandro wrote: >> >> I tried proposing something similar (unknown size) some time ago and it >> was voted down; perhaps the climate has changed now. >> > > I voted it down perhaps because I misunderstood your proposal. I > understood you were proposing this for the whole type system.
I was referring to myself pitching the same idea you just did (syntax for types one does not know the size of) in here during my GSoC last summer. It seems the climate hasn't changed :-) > What would happen below? > > cdef MyInt a, b > .... > cdef object o = a BINOP b Well, since both a and b is MyInt, this is simple, just use sizeof(MyInt) to discriminate. If you refer to cdef IntA a cdef IntB b cdef object o = a + b then...you are right, some creative solution is needed (it is not impossible, any of my tricks proposed earlier this week would do the job). Waiting to see what Robert will write before writing more about this. Dag _______________________________________________ Cython-dev mailing list [email protected] http://codespeak.net/mailman/listinfo/cython-dev
