Elm Exactly

Rule 26s-ty-unit

Type ExpressionsC⊢ty⇒τ\jdg{C}{\ty}{\tau}
C⊢()⇒()\frac{\begin{array}{c}\end{array}}{\begin{array}{c}\jdg{C}{\kw{()}}{\tunit}\end{array}}
(26)
Read it in its chapter·Permanent address: /standard/rules/s-ty-unit
TeX source
\defnrule[r:s-ty-unit]
  {}
  {\jdg{C}{\kw{()}}{\tunit}}

Tests (2)

  • elm / MinimalUnitTest
    The unit expression has the unit type and value.
  • elm / RecordRowsTest
    Record expressions, record types and record patterns are rows of fields.

Discussions

Discuss this rule·Search the discussions on GitHub

Discussions are on GitHub; one about this rule has [r:s-ty-unit] in its title.

A Standard Definition of Elm? (Draft version 0.4) © Rupert Smith. The text is licensed under CC BY 4.0: share and adapt it freely, with credit and a link to the licence.