[clang] [llvm] [Clang] Match MSVC handling of duplicate header search paths in Microsoft compatibility modes. (PR #105738)
Tom Honermann via llvm-commits
llvm-commits at lists.llvm.org
Mon Oct 21 11:10:38 PDT 2024
tahonermann wrote:
@zygoloid,
> On the fourth hand, IIRC the choice of whether header search for a relative path looks in the directory of includers as well as the directory of the current file already depends on `-fms-compatibility`, and this seems sort of similar.
I confirmed the search of the include stack directories is controlled by `-fms-compatibility`. The relevant code is https://github.com/llvm/llvm-project/blob/f58ce1152703ca753794b8cef36da30bd2668d0f/clang/lib/Lex/PPDirectives.cpp#L1003-L1013.
> So yeah, I dunno what we should do; it doesn't seem clear to me.
Yup. My intuition has been to follow the existing precedent unless/until motivation to do otherwise becomes apparent.
https://github.com/llvm/llvm-project/pull/105738
More information about the llvm-commits
mailing list