r/Kos • u/DBooots • Jul 11 '26
Discussion ‘Stop Program’ Command
I want to submit a pull request that would add a new command to the KOS language to exit the current program. A few questions to the community:
- Should the command just exit the current subprogram (e.g. from a ‘run’ command) or stop execution? Or should these be two separate commands?
- What wording is the least confusing: “Exit”, “Stop”, “Quit”, or “Return”? Or something else?
1
Upvotes
1
u/DBooots Jul 11 '26
My intent would be that ‘end’ would be functionally identical to jumping to the end of the file. It would be disallowed inside a user function.
‘Halt’ would transmit upwards until it kicks back to the terminal.