pure package:distribution-opensuse

Lift a value.
Return either a pure value if a condition is True, otherwise empty.
pureIf @Maybe True  5 == Just 5
pureIf @Maybe False 5 == Nothing
pureIf @[]    True  5 == [5]
pureIf @[]    False 5 == []