ilya-biryukov added inline comments.
================
Comment at: clangd/index/Background.cpp:517
+        // well.
+        CurDependencyPath = Dependencies[CurrentDependency].Path;
+      }
----------------
We should avoid modifying the container we're iterating over instead.
I suggest we separate the queue and the return value into two separate vectors.

We would `pop()` from the queue and `push()` to the result vector, therefore 
making bugs like this impossible.


Repository:
  rCTE Clang Tools Extra

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D56656/new/

https://reviews.llvm.org/D56656



_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to