Kernel is Elixir’s default environment.
It mainly consists of:
- basic language primitives, such as arithmetic operators, spawning of processes, data type handling, and others
- macros for control-flow and defining new functionality (modules, functions, and the like)
- guard checks for augmenting pattern matching
You can invoke Kernel
functions and macros anywhere in Elixir code without the use of the Kernel.
prefix since they have all been automatically imported.
Functions of the Kernel module: