(.using
  [library
   [lux {"-" nat int rev list type or and}
    ["$" documentation {"+" documentation:}]
    [data
     [text
      ["%" format {"+" format}]]]
    [macro
     ["[0]" template]]]]
  [\\library
   ["[0]" /]])

(documentation: /.left
  "The left side of a pair.")

(documentation: /.right
  "The right side of a pair.")

(documentation: /.curried
  "Converts a 2-argument function into nested single-argument functions."
  [(curried f)])

(documentation: /.uncurried
  "Converts nested single-argument functions into a 2-argument function."
  [(uncurried f)])

(documentation: /.swapped
  ""
  [(swapped [left right])])

(documentation: /.then
  "Apply functions to both sides of a pair."
  [(then f g)])

(documentation: /.forked
  "Yields a pair by applying both functions to a single value."
  [(forked f g)])

(.def: .public documentation
  (.List $.Module)
  ($.module /._
            "Functionality for working with tuples (particularly 2-tuples/pairs)."
            [..left
             ..right
             ..curried
             ..uncurried
             ..swapped
             ..then
             ..forked
             ($.default /.equivalence)
             ($.default /.hash)]
            []))
