[all-commits] [llvm/llvm-project] cb5bb2: Revert "Revert "[clang][extract-api] Use relative ...

Zixu Wang via All-commits all-commits at lists.llvm.org
Wed May 4 14:53:14 PDT 2022

  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: cb5bb28511f2c7530806af7ef53696deed453ca1
  Author: Zixu Wang <zixu_wang at apple.com>
  Date:   2022-05-04 (Wed, 04 May 2022)

  Changed paths:
    M clang/include/clang/ExtractAPI/FrontendActions.h
    M clang/lib/ExtractAPI/ExtractAPIConsumer.cpp
    R clang/test/ExtractAPI/known_files_only_hmap.c
    A clang/test/ExtractAPI/relative_include.m

  Log Message:
  Revert "Revert "[clang][extract-api] Use relative includes""

Reapply the change after fixing sanitizer errors.
The original problem was that `StringRef`s in `Matches` are pointing to
temporary local `std::string`s created by `path::convert_to_slash` in
the regex match call. This patch does the conversion up front in
container `FilePath`.

This reverts commit 2966f0fa505266735dbc8324b8821b7f0aa901ff.

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

More information about the All-commits mailing list