Module
Data.Void
- Package
- purescript-prelude
- Repository
- purescript/purescript-prelude
#Void Source
newtype Void
An uninhabited data type. In other words, one can never create
a runtime value of type Void
because no such value exists.
Void
is useful to eliminate the possibility of a value being created.
For example, a value of type Either Void Boolean
can never have
a Left value created in PureScript.
This should not be confused with the keyword void
that commonly appears in
C-family languages, such as Java:
public class Foo {
void doSomething() { System.out.println("hello world!"); }
}
In PureScript, one often uses Unit
to achieve similar effects as
the void
of C-family languages above.
- Modules
- Control.
Applicative - Control.
Apply - Control.
Bind - Control.
Category - Control.
Monad - Control.
Semigroupoid - Data.
Boolean - Data.
BooleanAlgebra - Data.
Bounded - Data.
Bounded. Generic - Data.
CommutativeRing - Data.
DivisionRing - Data.
Eq - Data.
Eq. Generic - Data.
EuclideanRing - Data.
Field - Data.
Function - Data.
Functor - Data.
Generic. Rep - Data.
HeytingAlgebra - Data.
HeytingAlgebra. Generic - Data.
Monoid - Data.
Monoid. Additive - Data.
Monoid. Conj - Data.
Monoid. Disj - Data.
Monoid. Dual - Data.
Monoid. Endo - Data.
Monoid. Generic - Data.
Monoid. Multiplicative - Data.
NaturalTransformation - Data.
Ord - Data.
Ord. Generic - Data.
Ordering - Data.
Reflectable - Data.
Ring - Data.
Ring. Generic - Data.
Semigroup - Data.
Semigroup. First - Data.
Semigroup. Generic - Data.
Semigroup. Last - Data.
Semiring - Data.
Semiring. Generic - Data.
Show - Data.
Show. Generic - Data.
Symbol - Data.
Unit - Data.
Void - Prelude
- Record.
Unsafe - Type.
Proxy