summaryrefslogtreecommitdiff
path: root/manual/src/library/core.etex
blob: 0cc59eeb0087191ca7fb21e6c2296ab6f052343d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
\chapter{The core library} \label{c:corelib}\cutname{core.html}

This chapter describes the OCaml core library, which is
 composed of declarations for built-in types and exceptions, plus
the module "Stdlib" that provides basic operations on these
 built-in types.  The "Stdlib" module is special in two
ways:
\begin{itemize}
\item It is automatically linked with the user's object code files by
the "ocamlc" command (chapter~\ref{c:camlc}).

\item It is automatically ``opened'' when a compilation starts, or
when the toplevel system is launched. Hence, it is possible to use
unqualified identifiers to refer to the functions provided by the
"Stdlib" module, without adding a "open Stdlib" directive.
\end{itemize}

\begin{latexonly}
\section*{s:core-conventions}{Conventions}

The declarations of the built-in types and the components of module
"Stdlib" are printed one by one in typewriter font, followed by a
short comment.  All library modules and the components they provide are
indexed at the end of this report.
\end{latexonly}

\input{builtin.tex}
\ifouthtml
\section{s:stdlib-module}{Module {\tt Stdlib}: the initially opened module}
\fi
\begin{linklist}
\libdocitem{Stdlib}{the initially opened module}
\end{linklist}