[all-commits] [llvm/llvm-project] aafad2: [Clang] Warn on deprecated specializations used in...
cor3ntin via All-commits
all-commits at lists.llvm.org
Fri Nov 17 09:16:48 PST 2023
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: aafad2d214246bae4d53ce3178b11486ebc83890
https://github.com/llvm/llvm-project/commit/aafad2d214246bae4d53ce3178b11486ebc83890
Author: cor3ntin <corentinjabot at gmail.com>
Date: 2023-11-17 (Fri, 17 Nov 2023)
Changed paths:
M clang/docs/ReleaseNotes.rst
M clang/include/clang/Sema/Sema.h
M clang/lib/Sema/SemaAvailability.cpp
M clang/lib/Sema/SemaTemplate.cpp
A clang/test/SemaCXX/warn-deprecated-specializations-in-system-headers.cpp
Log Message:
-----------
[Clang] Warn on deprecated specializations used in system headers. (#70353)
When the top of the instantiation stack is in user code.
The goal of this PR is to allow deprecation of some char_traits
specializations in libc++ as done in https://reviews.llvm.org/D157058
which was later reverted by
https://github.com/llvm/llvm-project/pull/66153#issuecomment-1719578384
as Clang never emitted the libc++ warnings.
Because Clang likes to eagerly instantiate, we can look for the location
of the top of the instantiation stack, and emit a warning if that
location is in user code.
The warning emission is forced by temporarily instructing the diag
engine not to silence warning in system headers.
More information about the All-commits
mailing list