src/HOL/Library/README.html
author blanchet
Wed, 24 Sep 2014 15:45:55 +0200
changeset 58425 246985c6b20b
parent 57412 b441f330078b
permissions -rw-r--r--
simpler proof

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">

<html>

<head>
  <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
  <title>HOL-Library/README</title>
</head>

<body>

<h1>HOL-Library: supplemental theories for main Isabelle/HOL</h1>

This is a collection of generic theories that may be used together
with main Isabelle/HOL.

<p>

Addition of new theories should be done with some care, as the
``module system'' of Isabelle is rather simplistic.  The following
guidelines may be helpful to achieve maximum re-usability and minimum
clashes with existing developments.

<dl>

<dt><strong>Examples</strong>

<dd>Theories should be as ``generic'' as is sensible.  Unused (or
rather unusable?) theories should be avoided; common applications
should actually refer to the present theory.  Small example uses may
be included in the library as well, but should be put in a separate
theory, such as <tt>Foobar</tt> accompanied by
<tt>Foobar_Examples</tt>.

<dt><strong>Theory names</strong>

<dd>The theory loader name space is <em>flat</em>, so use sufficiently
long and descriptive names to reduce the danger of clashes with the
user's own theories.  The convention for theory names is as follows:
<tt>Foobar_Doobar</tt> (this looks best in LaTeX output).

<dt><strong>Names of logical items</strong>

<dd>There are separate hierarchically structured name spaces for
types, constants, theorems etc.  Nevertheless, some care should be
taken, as the name spaces are always ``open''.  Use adequate names;
avoid unreadable abbreviations.  The general naming convention is to
separate word constituents by underscores, as in <tt>foo_bar</tt> or
<tt>Foo_Bar</tt> (this looks best in LaTeX output).

<dt><strong>Global context declarations</strong>

<dd>Only items introduced in the present theory should be declared
globally (e.g. as Simplifier rules).  Note that adding and deleting
rules from parent theories may result in strange behavior later,
depending on the user's arrangement of import lists.

<dt><strong>Spacing</strong>

<dd>Isabelle is able to produce a high-quality LaTeX document from the
theory sources, provided some minor issues are taken care of.  In
particular, spacing and line breaks are directly taken from source
text.  Incidentally, output looks very good if common type-setting
conventions are observed: put a single space <em>after</em> each
punctuation character ("<tt>,</tt>", "<tt>.</tt>", etc.), but none
before it; do not extra spaces inside of parentheses; do not attempt
to simulate table markup with spaces, avoid ``hanging'' indentations.

</dl>

</body>
</html>