mirror of
https://github.com/reactos/CMake.git
synced 2024-11-24 03:59:58 +00:00
Genex: Accept arbitrary content in *_CASE and MAKE_C_IDENTIFIER.
This commit is contained in:
parent
d36b489401
commit
f4d9466130
@ -201,6 +201,8 @@ static const struct LowerCaseNode : public cmGeneratorExpressionNode
|
||||
{
|
||||
LowerCaseNode() {}
|
||||
|
||||
bool AcceptsArbitraryContentParameter() const { return true; }
|
||||
|
||||
std::string Evaluate(const std::vector<std::string> ¶meters,
|
||||
cmGeneratorExpressionContext *,
|
||||
const GeneratorExpressionContent *,
|
||||
@ -215,6 +217,8 @@ static const struct UpperCaseNode : public cmGeneratorExpressionNode
|
||||
{
|
||||
UpperCaseNode() {}
|
||||
|
||||
bool AcceptsArbitraryContentParameter() const { return true; }
|
||||
|
||||
std::string Evaluate(const std::vector<std::string> ¶meters,
|
||||
cmGeneratorExpressionContext *,
|
||||
const GeneratorExpressionContent *,
|
||||
@ -229,6 +233,8 @@ static const struct MakeCIdentifierNode : public cmGeneratorExpressionNode
|
||||
{
|
||||
MakeCIdentifierNode() {}
|
||||
|
||||
bool AcceptsArbitraryContentParameter() const { return true; }
|
||||
|
||||
std::string Evaluate(const std::vector<std::string> ¶meters,
|
||||
cmGeneratorExpressionContext *,
|
||||
const GeneratorExpressionContent *,
|
||||
|
@ -193,9 +193,9 @@ add_custom_target(check-part3 ALL
|
||||
-Dtest_platform_id_Linux=$<PLATFORM_ID:Linux>
|
||||
-Dtest_platform_id_Windows=$<PLATFORM_ID:Windows>
|
||||
-Dtest_platform_id_Darwin=$<PLATFORM_ID:Darwin>
|
||||
-Dlower_case=$<LOWER_CASE:MiXeD>
|
||||
-Dupper_case=$<UPPER_CASE:MiXeD>
|
||||
-Dmake_c_identifier=$<MAKE_C_IDENTIFIER:4foo:+bar-$>
|
||||
-Dlower_case=$<LOWER_CASE:Mi,XeD>
|
||||
-Dupper_case=$<UPPER_CASE:MiX,eD>
|
||||
-Dmake_c_identifier=$<MAKE_C_IDENTIFIER:4f,oo:+bar-$>
|
||||
-P ${CMAKE_CURRENT_SOURCE_DIR}/check-part3.cmake
|
||||
COMMAND ${CMAKE_COMMAND} -E echo "check done (part 3 of 3)"
|
||||
VERBATIM
|
||||
|
@ -34,6 +34,6 @@ foreach(system Linux Windows Darwin)
|
||||
check(test_platform_id_${system} 0)
|
||||
endif()
|
||||
endforeach()
|
||||
check(lower_case "mixed")
|
||||
check(upper_case "MIXED")
|
||||
check(make_c_identifier "_4foo__bar__")
|
||||
check(lower_case "mi,xed")
|
||||
check(upper_case "MIX,ED")
|
||||
check(make_c_identifier "_4f_oo__bar__")
|
||||
|
Loading…
Reference in New Issue
Block a user