module Unison.Codebase.Metadata
( Star,
Value,
insert,
delete,
)
where
import Unison.Reference (TermReference)
import Unison.Util.Star2 (Star2)
import Unison.Util.Star2 qualified as Star2
type Value = TermReference
type Star a n = Star2 a n Value
insert :: (Ord a, Ord n) => (a, Value) -> Star a n -> Star a n
insert :: forall a n. (Ord a, Ord n) => (a, Value) -> Star a n -> Star a n
insert (a
a, Value
v) = (a, Value) -> Star2 a n Value -> Star2 a n Value
forall fact d2 d1.
(Ord fact, Ord d2) =>
(fact, d2) -> Star2 fact d1 d2 -> Star2 fact d1 d2
Star2.insertD2 (a
a, Value
v)
delete :: (Ord a, Ord n) => (a, Value) -> Star a n -> Star a n
delete :: forall a n. (Ord a, Ord n) => (a, Value) -> Star a n -> Star a n
delete (a
a, Value
v) Star a n
s = (a, Value) -> Star a n -> Star a n
forall fact d1 d2.
(Ord fact, Ord d1, Ord d2) =>
(fact, d2) -> Star2 fact d1 d2 -> Star2 fact d1 d2
Star2.deleteD2 (a
a, Value
v) Star a n
s