Skip to content
Commit 26c695b7 authored by Chris Bieneman's avatar Chris Bieneman
Browse files

Support macro deprecation #pragma clang deprecated

This patch adds `#pragma clang deprecated` to enable deprecation of
preprocessor macros.

The macro must be defined before `#pragma clang deprecated`. When
deprecating a macro a custom message may be optionally provided.

Warnings are emitted at the use site of a deprecated macro, and can be
controlled via the `-Wdeprecated` warning group.

This patch takes some rough inspiration and a few lines of code from
https://reviews.llvm.org/D67935.

Reviewed By: aaron.ballman

Differential Revision: https://reviews.llvm.org/D106732
parent ee7c9b8f
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment