[cfe-commits] r74205 - in /cfe/trunk: include/clang/Basic/DiagnosticSemaKinds.td lib/Sema/Sema.h lib/Sema/SemaDeclCXX.cpp lib/Sema/SemaExpr.cpp

Fariborz Jahanian fjahanian at apple.com
Tue Jun 30 09:39:24 PDT 2009


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


>



More information about the cfe-commits mailing list