From b1ec2b36a8db86d3169ad5753a080d7cc14c3632 Mon Sep 17 00:00:00 2001 From: Peter Kokot Date: Sat, 9 Aug 2025 03:20:20 +0200 Subject: [PATCH] TestCXXAcceptsFlag: Sync documentation - Added intro code block showing how to use this module. - Renamed "macros" to "commands". --- Modules/TestCXXAcceptsFlag.cmake | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/Modules/TestCXXAcceptsFlag.cmake b/Modules/TestCXXAcceptsFlag.cmake index a39f8b3b63..69c7bc37d3 100644 --- a/Modules/TestCXXAcceptsFlag.cmake +++ b/Modules/TestCXXAcceptsFlag.cmake @@ -12,11 +12,19 @@ TestCXXAcceptsFlag :module:`CheckCompilerFlag` module is also available for checking flags across multiple languages. -This module provides a macro to test whether the C++ (CXX) compiler supports +This module provides a command to test whether the C++ (CXX) compiler supports specific flags. -Macros -^^^^^^ +Load this module in a CMake project with: + +.. code-block:: cmake + + include(TestCXXAcceptsFlag) + +Commands +^^^^^^^^ + +This module provides the following command: .. command:: check_cxx_accepts_flag