On Jun 29, 2009, at 11:00 PM, Chris Lattner wrote: > > You've been learning from Doug very well I see :). The problem with > this loop is that it evaluates ClassDecl->bases_end() every time > through the loop. In cases where the end iterator isn't changing > (the container isn't being mutated by the loop), it is better to > compute it once and refer to the pre-computed value. Something like > this:
I did not learn this from Doug. I cut-and-pasted from his code :). Done in: http://llvm.org/viewvc/llvm-project?view=rev&revision=74533 - Fariborz > _______________________________________________ cfe-commits mailing list [email protected] http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits
