blob: 17b29212689e6a0ae25811569518addf4e443cea (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
|
list(PREPEND test)
if(test)
message(FATAL_ERROR "failed")
endif()
list(PREPEND test satu)
if(NOT test STREQUAL "satu")
message(FATAL_ERROR "failed")
endif()
list(PREPEND test dua)
if(NOT test STREQUAL "dua;satu")
message(FATAL_ERROR "failed")
endif()
list(PREPEND test tiga)
if(NOT test STREQUAL "tiga;dua;satu")
message(FATAL_ERROR "failed")
endif()
# Scope test
function(foo)
list(PREPEND test empat)
if(NOT test STREQUAL "empat;tiga;dua;satu")
message(FATAL_ERROR "failed")
endif()
endfunction()
foo()
if(NOT test STREQUAL "tiga;dua;satu")
message(FATAL_ERROR "failed")
endif()
|