summaryrefslogtreecommitdiffstats
path: root/Tests/CMakeTests/WhileTest.cmake.in
blob: cc22978ce8efb0a7486736adc7e64f6979ce009a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
set(NUMBERS "")
set(COUNT 0)

while(COUNT LESS 200)
    set(NUMBERS "${NUMBERS} ${COUNT}")
    set(COUNT "2${COUNT}")

    set(NCOUNT 3)
    while(NCOUNT LESS 31)
        set(NUMBERS "${NUMBERS} ${NCOUNT}")
        set(NCOUNT "${NCOUNT}0")
    endwhile()
endwhile()

if(NOT NUMBERS STREQUAL " 0 3 30 20 3 30")
    message(SEND_ERROR "while loop nesting error, result: '${NUMBERS}'")
endif()