If a program's flow causes it to use GOSUB without matching RETURN statements, eventually the stack's memory will be full and an error will occur. Similarly, if a program's flow causes it to use more RETURN than GOSUB statements, RETURN will attempt to access memory outside of that allocated to the stack, resulting in an error.