[PATCH] D85532: Correctly set CompilingPCH in PrecompilePreambleAction.

Adam Czachorowski via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Aug 10 07:46:53 PDT 2020


adamcz added inline comments.


================
Comment at: clang/unittests/Frontend/ASTUnitTest.cpp:146
+  auto File = AU->getFileManager().getFileRef("Textual.h", false, false);
+  assert(File);
+  // Verify that we do not crash here.
----------------
adamcz wrote:
> kadircet wrote:
> > ASSERT_TRUE again
> You can 't ASSERT_TRUE() on llvm::Expected, since operator bool() is not const. No idea why, but that's why it's assert()
Nevermind, I do know why - because it changes the "checked" status, that makes sense. I guess we could make that mutable, but that seems out of scope for this change.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D85532



More information about the cfe-commits mailing list