Convenience aliases for creating attribute values, reducing need for type annotations compared to using the underlying untagged-union function

Intended for qualified import e.g. import Tracing.Attributes as Attributes.


string :: String -> Attribute

A String attribute


atom :: Atom -> Attribute

An Atom attribute


boolean :: Boolean -> Attribute

A Boolean attribute, which is to say a restricted sort of atom.


int :: Int -> Attribute

An Int attribute


number :: Number -> Attribute

A Number attribute.


list :: List (Union |$| String |+| Atom |+| Int |+| Number |+| Nil) -> Attribute

A list attribute. The members of the list should be constructed using the untagged-union inj directly

Attributes.list (inj "abc" : inj 42 : nil)