Action calls and commands

One or more action calls (separated by ;), or a single interpreter command, may be entered in response to the query prompt. Remember the action calls are deterministic and so an entered action call sequence will give exactly one answer binding for its variables, or produce an exception.
| ?? do_parse2("the fat lady sings!", PT).

Word list: ["the", "fat", "lady", "sings"]
All words in dictionary
PT = s(np("the", ne("fat", n("lady"))), v("sings")) : parse_tree
success

The first two lines of output are produced by the action call. The last two lines are produced by the interpreter.

We can't call functions directly but we can turn them into a relational query by using an = query as below.

| ?? X = curry(+).

X = curry(+) : term_naming(fun(int) -> fun(int) -> int &&
fun(num) -> fun(num) -> num &&
fun(nat) -> fun(nat) -> nat)

| ?? X = curry(+)(2).

X = curry(+)(2) : term_naming(fun(int) -> int &&
fun(num) -> num &&
fun(nat) -> nat)

| ?? X = curry(+)(2)(3).

X = 5 : digit

Note the types in the first two examples. The answer terms are terms that name functions and the type of each of these functions are intersection types - i.e. can can be used in multiple situations.