begin
string (10) fn ten lit
result = "fives"
end
string (10) fn ten var
string(7) seven = "four"
result = seven
end
string (255) fn big lit
result = "a longer string"
end
string (255) fn big
string (15) medium
medium = "a longer string"
result = medium
end
string (3) short
string (50) medium
string (255) huge
routinespec do63(string (63) S)
routinespec do255(string (255) S)
routine do15(string (15) S)
do63(S) if 0=1
do255(S) if 0=1
end
routine do63(string (63) S)
do15(S)
do255(S) if 0=1
end
routine do255(string (255) S)
do15(S)
do63(S)
end
do15(ten lit)
do15(ten var)
do15(big lit)
do15(big)
do15(short)
do15(medium)
do15(huge)
do15("123")
! This line *could* have been faulted by Imp77 pass1 but wasn't, however C caught it...
! (on the plus side, my code will catch it at runtime)
do15("a lot longer than fifteen characters I think")
do63(short)
do63(medium)
do63(huge)
do63("123")
do63("a lot longer than fifteen characters I think")
do255(short)
do255(medium)
do255(huge)
do255(ten lit)
do255(ten var)
do255(big lit)
do255(big)
do255("123")
do255("a lot longer than fifteen characters I think")
huge = "123"
huge = big
huge = big lit
huge = ten var
huge = ten lit
medium = "123"
medium = big
medium = big lit
medium = ten var
medium = ten lit
short = "123"
! These should cause errors...
short = big
short = big lit
short = ten var
short = ten lit
endofprogram