Test 007: Test PASSED VARIABLES.
Ve now call a tag and pass variable X. The tag will print X (and its length, which should be 31):
BEBUG:VARIABLES:x = ''; x = x'This is the value of variable X'; stem. = ''; stem. = stem.'STEM.':We now try limited stem passing (5 values of stem., the first 5 squares):
BEBUG:VARIABLES:x = ''; x = x'Now X has changed its value...'; stem.1 = ''; stem.1 = stem.1'1'; stem.2 = ''; stem.2 = stem.2'4'; stem.3 = ''; stem.3 = stem.3'9'; stem.4 = ''; stem.4 = stem.4'16'; stem.5 = ''; stem.5 = stem.5'25'; stem.0 = ''; stem.0 = stem.0'5':We now try a large variable (600 chars, > maxStringLength in most implementations):
BEBUG:VARIABLES:x = ''; x = x'01234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789'; x = x'01234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789'; x = x'01234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789'; stem. = ''; stem. = stem.'STEM.':We now try the same with stems (stem.1 is a 900 char variable):
BEBUG:VARIABLES:x = ''; x = x''; stem.1 = ''; stem.1 = stem.1'01234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789'; stem.1 = stem.1'01234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789'; stem.1 = stem.1'01234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789'; stem.1 = stem.1'01234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789'; stem.1 = stem.1'0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789'; stem.0 = ''; stem.0 = stem.0'1':