Unless|unless_then_else_

Definitions:

boolean, []→⊤, []→⊤
Source: /avail/Avail/Foundation/Control Structures
Categories: Control Structures, Conditionals
Given a predicate value and two functions, invoke one of them and answer its result.
Position Name Type Description
Parameters
1 predicate boolean A predicate value.
2 falseFunction []→⊤ The function to invoke if predicate is false.
3 trueFunction []→⊤ The function to invoke if trueFunction is true.
Returns If predicate is false, then the value produced by invoking falseFunction; otherwise, the value produced by invoking trueFunction.

Semantic restrictions:

true's type's type, []→⊤'s type, []→⊤'s type
Source: /avail/Avail/Foundation/Control Structures
Strengthen the static return type to that of the function to invoke when the predicate is true (which it is).
Type Description
Parameter Types
true's type's type
[]→⊤'s type
[]→⊤'s type
false's type's type, []→⊤'s type, []→⊤'s type
Source: /avail/Avail/Foundation/Control Structures
Strengthen the static return type to that of the function to invoke when the predicate is false (which it is).
Type Description
Parameter Types
false's type's type
[]→⊤'s type
[]→⊤'s type
boolean's type, []→⊤'s type, []→⊤'s type
Source: /avail/Avail/Foundation/Control Structures
Establish a conditional expression whose static return type is the type union of its two possible functions' return types.
Type Description
Parameter Types
boolean's type
[]→⊤'s type
[]→⊤'s type