null package:lens

O(1). Determine if a Deque is empty.
>>> Control.Lens.Internal.Deque.null empty
True
>>> Control.Lens.Internal.Deque.null (singleton 1)
False
Returns True if this Fold or Traversal has no targets in the given container. Note: nullOf on a valid Iso, Lens or Getter should always return False.
nullnullOf folded
This may be rather inefficient compared to the null check of many containers.
>>> nullOf _1 (1,2)
False
>>> nullOf ignored ()
True
>>> nullOf traverse []
True
>>> nullOf (element 20) [1..10]
True
nullOf (folded . _1 . folded) :: (Foldable f, Foldable g) => f (g a, b) -> Bool
nullOf :: Getter s a     -> s -> Bool
nullOf :: Fold s a       -> s -> Bool
nullOf :: Iso' s a       -> s -> Bool
nullOf :: Lens' s a      -> s -> Bool
nullOf :: Traversal' s a -> s -> Bool
Returns True if this Fold or Traversal has any targets in the given container. A more "conversational" alias for this combinator is has. Note: notNullOf on a valid Iso, Lens or Getter should always return True.
not . nullnotNullOf folded
This may be rather inefficient compared to the not . null check of many containers.
>>> notNullOf _1 (1,2)
True
>>> notNullOf traverse [1..10]
True
>>> notNullOf folded []
False
>>> notNullOf (element 20) [1..10]
False
notNullOf (folded . _1 . folded) :: (Foldable f, Foldable g) => f (g a, b) -> Bool
notNullOf :: Getter s a     -> s -> Bool
notNullOf :: Fold s a       -> s -> Bool
notNullOf :: Iso' s a       -> s -> Bool
notNullOf :: Lens' s a      -> s -> Bool
notNullOf :: Traversal' s a -> s -> Bool