This is an archive of the discontinued LLVM Phabricator instance.

[clangd] Fix crash when CompilerInvocation can't be created.
ClosedPublic

Authored by ilya-biryukov on Feb 9 2018, 5:19 AM.

Diff Detail

Repository
rL LLVM

Event Timeline

ilya-biryukov created this revision.Feb 9 2018, 5:19 AM
sammccall accepted this revision.Feb 9 2018, 5:25 AM

just nits

clangd/ClangdUnit.cpp
417 ↗(On Diff #133590)

remove?

unittests/clangd/ClangdTests.cpp
47 ↗(On Diff #133590)

doc that this consumes Expected<T>

48 ↗(On Diff #133590)

This helper should go in Matchers.h I think

52 ↗(On Diff #133590)

More context:

<< " from " << #expectedValue << " but got " << ::testing::PrintToString(*ComputedValue)

(please check the error message works!)

This revision is now accepted and ready to land.Feb 9 2018, 5:25 AM
ilya-biryukov marked 4 inline comments as done.
  • Removed assert that is now redundant
  • Moved EXPECT_ERROR to Matchers.h
  • Added more context into EXPECT_ERROR's error message
This revision was automatically updated to reflect the committed changes.