----- Mail original ----- > De: "serge Guelton" <serge.guelton@xxxxxxxxxxxxxxxx> > À: pythran@xxxxxxxxxxxxx > Envoyé: Vendredi 22 Novembre 2013 11:51:55 > Objet: [pythran] Re: What are you implementing? > > On Fri, Nov 22, 2013 at 10:34:45AM +0100, Pierrick Brunet wrote: > > > > > > ----- Mail original ----- > > > De: "serge Guelton" <serge.guelton@xxxxxxxxxxxxxxxx> > > > À: pythran@xxxxxxxxxxxxx > > > Envoyé: Vendredi 22 Novembre 2013 10:12:16 > > > Objet: [pythran] Re: What are you implementing? > > > > > > On Thu, Nov 21, 2013 at 09:34:23PM +0100, Pierrick Brunet wrote: > > > > Pierrick : Nothing for now :-) I was on Import and now I will : > > > > pass new benchmark and/or remove useless stmt pass > > > > > > Pass new benchmarks (the one I sent on the mliste during SC) > > > seems > > > more > > > important to me. You also have to polish (and benchmark!) your > > > lazy > > > branch ;-) > > > > > > > About remove useless stmt pass, it is mainly function and > > > > import. > > > > - Import because it may avoid a crash if user import a module > > > > we > > > > don't know but which is not use. > > > > - Function because useless function may use unknown module and > > > > cause crash. It may happen more often with imported module. > > > > > > Both are False, because you cannot decide if the import function > > > is > > > useless if you don't know it (e;g. it can print something on the > > > screen) > > > > #pythran export foo() > > > > import baba > > > > def bar(): > > baba.lala() > > > > def foo(): > > print a > > > > > > I am sure in this case that import baba is useless AND bar function > > too. > > Only because of the export. But export are not taken into account at > compilation time (we would loose all the meta-programming beauty). > Remember one can translate a .py into .cpp to be used from another > .cpp... > > It is just a matter of name forwarding :). If we don't care about typing, we keep the meta-programming beauty :)