[all-commits] [llvm/llvm-project] 7aa249: [clang] Expand invalid PCM diagnostic (#69489)

Nuri Amari via All-commits all-commits at lists.llvm.org
Wed Oct 18 16:20:08 PDT 2023


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 7aa24915cb66c51bab7c15854877136930d3ed17
      https://github.com/llvm/llvm-project/commit/7aa24915cb66c51bab7c15854877136930d3ed17
  Author: Nuri Amari <nuriamari at meta.com>
  Date:   2023-10-18 (Wed, 18 Oct 2023)

  Changed paths:
    M clang/include/clang/Basic/DiagnosticSerializationKinds.td
    M clang/test/Modules/explicit-build.cpp

  Log Message:
  -----------
  [clang] Expand invalid PCM diagnostic (#69489)

Summary:

When a PCM file is loaded, it can go wrong in various ways. The current
diagnostic only produces the name of the malformed PCM, not why it is
malformed. Expand the diagnostic to display what went wrong!

There is only one call site for this diagnostic, and it already passes
the error message:


https://github.com/llvm/llvm-project/blob/main/clang/lib/Serialization/ASTReader.cpp#L4763-L4764

Test Plan:

The modified LIT test.

---------

Co-authored-by: Nuri Amari <nuriamari at fb.com>




More information about the All-commits mailing list