parseCommand

fun parseCommand(onSuccess: (List<A_Phrase>, (() -> Unit) -> Unit) -> Unit, afterFail: () -> Unit)

Parse a command, compiling it into the current module, from the token list.

Parameters

onSuccess

What to do after compilation succeeds. This continuation is invoked with a list of phrases that represent the possible solutions of compiling the command and a continuation that cleans up this compiler and its module (and then continues with a post-cleanup continuation).

afterFail

What to do after compilation fails.