On Tue, Apr 6, 2010 at 2:00 PM, Stefan Behnel <[email protected]> wrote: > Haoyu Bai, 06.04.2010 05:17: >> On Tue, Apr 6, 2010 at 4:25 AM, Stefan Behnel wrote: >>> Robert Bradshaw, 05.04.2010 21:00: >>>> I'm not convinced that grouping internal Cython constructions based on >>>> whether they have a "pure" counterpart is the best way to do things-- >>>> in my ind the directives having to do with division are best handled >>>> in the division node, those dealing with buffers best handled in the >>>> buffer code, etc. >>> >>> It's nice to have a simple language interface to all these features, but >>> that doesn't mean they have to be any similar on the implementation side. >> >> I'm not mean to unify the implementation of these features. The >> decorators would just set directive or flags to the node > > Well, again: it's not just nodes. > >> then the >> nodes only need to dealing with these directives or flags, rather than >> check the decorators directly. > > The decorators work on subtrees, usually functions, so they'd have to apply > their "directive or flags" to the whole subtree, and they'd have to know > what nodes to intercept on. The easiest way to do these things is - a > transform visitor, just what we currently have. > > >> if we forbid "from cython import *", then do we allow this: >> >> from cython import cfunc, int, float > > Sure. > > >> otherwise, I just imagine, it could be pain to write a lot of >> @cython.cfunc instead of the simply cdef. > > If you have to write that a lot, just use a selective import or > > cimport cython as cy > > I get the impression that you are chasing non-problems here. > > Stefan
I just thinking what could I help for improving Cython. Maybe I am thinking the wrong way since I'm not such familiar with the Cython design concept yet. However, no one intend to chase non-problems. -- Haoyu BAI School of Computing, National University of Singapore. _______________________________________________ Cython-dev mailing list [email protected] http://codespeak.net/mailman/listinfo/cython-dev
