Don't walk the list of documents while already doing it.
There should be no need to walk all documents in an inner loop while already doing it in the outer loop. The O(n^2) performance complexity is probably negligible, but what I'm actually trying to fix here is problems when compiling with -Wshadow (the problem here being the various |document| variables). Bug: 294205 Change-Id: Ide1ab566e3b9ddb53d4b4f44c9c03633c90348a1 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2460745Reviewed-by:Andrey Kosyakov <caseq@chromium.org> Commit-Queue: Morten Stenshorne <mstensho@chromium.org> Cr-Commit-Position: refs/heads/master@{#816260}
Showing
Please register or sign in to comment