Dag Sverre Seljebotn wrote: > Lisandro Dalcin wrote: >> On Wed, Sep 17, 2008 at 4:54 PM, Dag Sverre Seljebotn >> <[EMAIL PROTECTED]> wrote: >> >>> Lisandro wrote: >>> >>>> I've almost finished the transform in charge of embeding functions >>>> signatures in docstrings. I want to ask your about some issues I need >>>> to handle to finish it. >>>> >>>> * Position in the transform pipeline: I'm curently inserting the >>>> auto-signature transform after the 'ResolveOptions' one in the >>>> transform pipeline. Dag, tell me if this is OK. >>>> >>> For this, anywhere where you have the needed information available >>> is ok. >>> I guess you read the type info from nodes then, and not the "parsed" >>> info >>> that is available later? (that could make sense and is not >>> necesarrily a >>> bad sign) >>> >>> >> >> I did not understand you here, but anyway it seems to work at the >> place I'm inserting it. Or perhaps I could get more info (like return >> type in 'cpdef' funcions) if I insert the transform near the end? >> > Sorry, my fault. Basically, when I wrote my description I meant to > imply (and should have clarified better) that the > AnalyseDeclarationsTransform interprets the nodes containing the type > declarations into a purer Python representation (see PyrexTypes.py). > However for what you are doing, walking the CSimpleTypeNodes might be > just as good. > > (Inserting the transform after AnalyseDeclarationsTransform makes > certain things (I need a countdown timer on my send button...)
I meant to say: Inserting the transform after AnalyseDeclarationsTransform makes certain things more difficult -- because for cpdef functions, a "python version node" is created and the docstring copied so you would need to change it in multiple locations and so on. So actually, what you have done will be more convenient and make this more isolated and less likely to break if the cpdef implementation is changed. Looking forward to see this :-) Dag Sverre _______________________________________________ Cython-dev mailing list [email protected] http://codespeak.net/mailman/listinfo/cython-dev
