|
@@ -46,52 +46,23 @@ if (NOT output STREQUAL listvar)
|
|
|
list (APPEND errors "returns bad value: ${output}")
|
|
|
endif()
|
|
|
|
|
|
-block(SCOPE_FOR POLICIES)
|
|
|
- cmake_policy(SET CMP0007 NEW)
|
|
|
-
|
|
|
- set(listvar "0;1;2;3;4")
|
|
|
- list(INSERT listvar 1 "")
|
|
|
- set (output "$<LIST:INSERT,0;1;2;3;4,1,>")
|
|
|
- if (NOT output STREQUAL listvar)
|
|
|
- list (APPEND errors "returns bad value: ${output}")
|
|
|
- endif()
|
|
|
-
|
|
|
- list(INSERT listvar 4 ";")
|
|
|
- set (output "$<LIST:INSERT,0;;1;2;3;4,4,;>")
|
|
|
- if (NOT output STREQUAL listvar)
|
|
|
- list (APPEND errors "returns bad value: ${output}")
|
|
|
- endif()
|
|
|
-
|
|
|
- list(INSERT listvar 0 "x")
|
|
|
- set (output "$<LIST:INSERT,0;;1;2;;;3;4,0,x>")
|
|
|
- if (NOT output STREQUAL listvar)
|
|
|
- list (APPEND errors "returns bad value: ${output}")
|
|
|
- endif()
|
|
|
-endblock()
|
|
|
-block(SCOPE_FOR POLICIES)
|
|
|
- set(CMAKE_WARN_DEPRECATED OFF CACHE BOOL "")
|
|
|
- cmake_policy(SET CMP0007 OLD)
|
|
|
-
|
|
|
- set(listvar "0;1;2;3;4")
|
|
|
- list(INSERT listvar 1 "")
|
|
|
- set (output "$<LIST:INSERT,0;1;2;3;4,1,>")
|
|
|
- if (NOT output STREQUAL listvar)
|
|
|
- list (APPEND errors "returns bad value: ${output}")
|
|
|
- endif()
|
|
|
-
|
|
|
- list(INSERT listvar 4 ";")
|
|
|
- set (output "$<LIST:INSERT,0;1;2;3;4,4,;>")
|
|
|
- if (NOT output STREQUAL listvar)
|
|
|
- list (APPEND errors "returns bad value: ${output}")
|
|
|
- endif()
|
|
|
+set(listvar "0;1;2;3;4")
|
|
|
+list(INSERT listvar 1 "")
|
|
|
+set (output "$<LIST:INSERT,0;1;2;3;4,1,>")
|
|
|
+if (NOT output STREQUAL listvar)
|
|
|
+ list (APPEND errors "returns bad value: ${output}")
|
|
|
+endif()
|
|
|
|
|
|
- list(INSERT listvar 0 "x")
|
|
|
- set (output "$<LIST:INSERT,0;1;2;3;4,0,x>")
|
|
|
- if (NOT output STREQUAL listvar)
|
|
|
- list (APPEND errors "returns bad value: ${output}")
|
|
|
- endif()
|
|
|
+list(INSERT listvar 4 ";")
|
|
|
+set (output "$<LIST:INSERT,0;;1;2;3;4,4,;>")
|
|
|
+if (NOT output STREQUAL listvar)
|
|
|
+ list (APPEND errors "returns bad value: ${output}")
|
|
|
+endif()
|
|
|
|
|
|
- unset(CMAKE_WARN_DEPRECATED CACHE)
|
|
|
-endblock()
|
|
|
+list(INSERT listvar 0 "x")
|
|
|
+set (output "$<LIST:INSERT,0;;1;2;;;3;4,0,x>")
|
|
|
+if (NOT output STREQUAL listvar)
|
|
|
+ list (APPEND errors "returns bad value: ${output}")
|
|
|
+endif()
|
|
|
|
|
|
check_errors("LIST:INSERT..." ${errors})
|