linear-base-0.4.0: Standard library for linear types.
Safe HaskellSafe-Inferred
LanguageHaskell2010

Data.Set.Mutable.Linear

Contents

Description

This module defines linear mutable sets.

The underlying implementation uses Linear, so it inherits the time and memory characteristics of it.

Please import this module qualified to avoid name clashes.

Synopsis

Mutable Sets

data Set a Source #

Instances

Instances details
Semigroup (Set a) Source # 
Instance details

Defined in Data.Set.Mutable.Linear.Internal

Methods

(<>) :: Set a -> Set a -> Set a #

sconcat :: NonEmpty (Set a) -> Set a #

stimes :: Integral b => b -> Set a -> Set a #

Keyed a => Semigroup (Set a) Source # 
Instance details

Defined in Data.Set.Mutable.Linear.Internal

Methods

(<>) :: Set a %1 -> Set a %1 -> Set a Source #

Consumable (Set a) Source # 
Instance details

Defined in Data.Set.Mutable.Linear.Internal

Methods

consume :: Set a %1 -> () Source #

Dupable (Set a) Source # 
Instance details

Defined in Data.Set.Mutable.Linear.Internal

Methods

dupR :: Set a %1 -> Replicator (Set a) Source #

dup2 :: Set a %1 -> (Set a, Set a) Source #

empty :: Keyed a => Int -> (Set a %1 -> Ur b) %1 -> Ur b Source #

insert :: Keyed a => a -> Set a %1 -> Set a Source #

delete :: Keyed a => a -> Set a %1 -> Set a Source #

union :: Keyed a => Set a %1 -> Set a %1 -> Set a Source #

intersection :: Keyed a => Set a %1 -> Set a %1 -> Set a Source #

size :: Keyed a => Set a %1 -> (Ur Int, Set a) Source #

member :: Keyed a => a -> Set a %1 -> (Ur Bool, Set a) Source #

fromList :: Keyed a => [a] -> (Set a %1 -> Ur b) %1 -> Ur b Source #

toList :: Keyed a => Set a %1 -> Ur [a] Source #

type Keyed a = Keyed a Source #