Files
cmake/Tests/RunCMake/CMP0219/AllNEW-Forward.cmake
T
Alex Reinking 9d2e85373a macro: Add policy to preserve backslashes in arguments
Preserve backslashes in arguments passed to macros by re-escaping
them before substituting in the macro body, where they will be
parsed again.

Fixes: #19281, #22157, #23641, #25803, #27645, #20891
2026-05-31 14:36:15 -04:00

18 lines
400 B
CMake

cmake_policy(SET CMP0219 NEW)
include("${CMAKE_CURRENT_LIST_DIR}/CMP0219-helpers.cmake")
macro(cmp0219_inner)
set(cmp0219_inner_argn "${ARGN}")
endmacro()
macro(cmp0219_middle)
cmp0219_inner(${ARGN})
endmacro()
macro(cmp0219_outer)
cmp0219_middle(${ARGN})
endmacro()
cmp0219_outer(HINTS "${cmp0219_path_native}")
cmp0219_assert_equal("${cmp0219_inner_argn}" "HINTS;${cmp0219_path_native}")