aganea added inline comments.

================
Comment at: clang-tools-extra/clangd/FormattedString.cpp:110
+    // Separate from next block.
+    *WritePtr++ = ' ';
+  }
----------------
There's an issue at this line, the iterator might go past the end of the string 
(if running the `Document.Separators` test). This fails when running a Debug 
build with VS 2019. The code fails with this assert (in `xstring`):
```
_STL_VERIFY(_Unfancy(_Ptr) < _Mycont->_Myptr() + _Mycont->_Mysize, "cannot 
increment string iterator past end");
```
I changed the code such as: {F11108172}
(sorry, Phabricator throws an exception when uploading this patch as a 
differential)

I can commit it if you're fine with the change.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D71248



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

Reply via email to