#COMPILE EXE "heap_strings.exe"
#DIM ALL

GLOBAL gs AS STRING

FUNCTION MakeText() AS STRING
    LOCAL s AS STRING
    s = "alpha"
    s = s + " beta gamma delta epsilon zeta eta theta iota kappa lambda"
    FUNCTION = s
END FUNCTION

SUB Touch(BYREF x AS STRING)
    x = x + "!"
END SUB

FUNCTION PBMAIN() AS LONG
    LOCAL a AS STRING
    LOCAL b AS STRING * 8
    a = MakeText()
    CALL Touch(a)
    gs = a
    b = gs
    PBMAIN = LEN(a) + LEN(b) + LEN(gs)
END FUNCTION
