[all-commits] [llvm/llvm-project] 884832: [clangd] Avoid a code completion crash

Haojian Wu via All-commits all-commits at lists.llvm.org
Mon Jan 17 01:40:58 PST 2022


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 884832407e47579a28e8c363492a620901f2eab4
      https://github.com/llvm/llvm-project/commit/884832407e47579a28e8c363492a620901f2eab4
  Author: Haojian Wu <hokein.wu at gmail.com>
  Date:   2022-01-17 (Mon, 17 Jan 2022)

  Changed paths:
    M clang-tools-extra/clangd/ClangdServer.cpp
    M clang-tools-extra/clangd/unittests/CodeCompleteTests.cpp

  Log Message:
  -----------
  [clangd] Avoid a code completion crash

This is a workaround (adding a newline to the eof) in clangd to avoid the code
completion crash, see https://github.com/clangd/clangd/issues/332.

In principle, this is a clang bug, we should fix it in clang, but it is not
trivial.

Reviewed By: sammccall

Differential Revision: https://reviews.llvm.org/D117456




More information about the All-commits mailing list