I do not see Alvaro's suggestion here, it's probably best. Also, I think code readability is much more important than optimization. This only does not hold in crucial parts of the code, like Youness said.
It is nice you found this difference though. I vote for Alvaro's suggestion to add a boolean parameter to the function. Duplicated source code should be avoided where ever possible. I'm sure that the 'if' statement required to test this boolean is negligible. JeeBee. On Sun, 2006-08-06 at 20:28 -0400, Benjamin wrote: > I tried profiling abook.tcl with etprof. > > Procname : ::abook::setContactData > Callnumber : 2736 times > Average time per call : 145 ms > > Procname : ::abook::setContactDataFast > Callnumber : 1693 times > Average time per call : 125 ms > > > --- > Benjamin > [EMAIL PROTECTED] > ------------------------------------------------------------------------- > Take Surveys. Earn Cash. Influence the Future of IT > Join SourceForge.net's Techsay panel and you'll get the chance to share your > opinions on IT & business topics through brief surveys -- and earn cash > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > _______________________________________________ Amsn-devel mailing list > [email protected] > https://lists.sourceforge.net/lists/listinfo/amsn-devel ------------------------------------------------------------------------- Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys -- and earn cash http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV _______________________________________________ Amsn-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/amsn-devel
