Guard
Produces a sequence containing either a single void value, or an empty sequence, depending on whether the condition evaluates to true or false. Can be used to filter out items from a sequence.
Syntax
Sequence.Guard
ยท [condition]
Parameters
- condition
- An expression that evaluates to true or false.
Return Value
A sequence containing a single void value if the condition was true, or an empty sequence otherwise.