true's type, nullary procedure, nullary procedure
Source: /avail/Avail/Foundation/Early Conditionals
Categories: Conditionals
Define the two-branch conditional evaluation method for a true condition.
Position | Name | Type | Description | |
---|---|---|---|---|
Parameters | ||||
1 | predicate | true's type | The boolean value, which is true for this method definition. | |
2 | trueFunction | nullary procedure | What to invoke if the predicate is true, which it is. | |
3 | falseFunction | nullary procedure | What to invoke if the predicate is false, which it is not. | |
Returns | ⊤ |
boolean, nullary procedure, nullary procedure
Source: /avail/Avail/Foundation/Early Conditionals
Categories: Conditionals
Declare the default two-branch conditional evaluation method. This one runs the false function, so there must be an override for the true case. Note that the semantic restrictions are defined in a downstream module, so until that point, the conditional method will be top-valued and can only be used as a statement.
Position | Name | Type | Description | |
---|---|---|---|---|
Parameters | ||||
1 | predicate | boolean | The boolean value, which is false for this method definition, assuming the true case is handled in an override. | |
2 | trueFunction | nullary procedure | What to invoke if the predicate is true, which it isn't. | |
3 | falseFunction | nullary procedure | What to invoke if the predicate is false, which it is. | |
Returns | ⊤ |