yvvan added inline comments.
================ Comment at: include/clang/Sema/CodeCompleteConsumer.h:565 + /// \brief For this completion result correction is required. + Optional<std::string> Corr = None; + ---------------- ilya-biryukov wrote: > Having a string replacement without an actual range to replace still moves a > lot of responsibility onto the clients. We should probably model corrections > after the fix-its for diagnostics: > - replacements need to provide a range to be replaced, alongside with a text > for the replacement, > - we should provide a list of edits to allow corrections that touch two > separate pieces of code. > > For the fix-its in the diagnostics, see > [[https://reviews.llvm.org/source/clang/browse/cfe/trunk/tools/libclang/CXLoadedDiagnostic.h;327861$84 > | CXLoadedDiagnostic.h]] for an interface exported via libclang and > [[https://reviews.llvm.org/source/clang/browse/cfe/trunk/include/clang/Basic/Diagnostic.h;327861$947|Diagnostic.h]] > for an interface exported in C++ API. > WDYT? I thought that fixits always exist separately from diagnostics. I will check this out, thanks. https://reviews.llvm.org/D41537 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits