From 72f413f1dbf20c8278ddc7301fd406fdf9349b62 Mon Sep 17 00:00:00 2001
From: Simon Peyton Jones <simonpj@microsoft.com>
Date: Tue, 2 Oct 2001 09:09:27 +0000
Subject: [PATCH] October release

---
 haskell98-bugs.html    | 77 +++++++++++++++++++++++++++++++-----------
 libraries/README       |  2 +-
 libraries/html.config  |  2 +-
 libraries/index.html   |  2 +-
 libraries/library.verb |  4 +--
 report/basic.verb      |  7 ++--
 report/haskell.verb    |  4 +--
 report/html.config     |  2 +-
 report/index.html      |  2 +-
 report/lexemes.verb    |  7 ++--
 report/modules.verb    |  4 +--
 report/preface-13.verb |  4 +--
 report/syntax-iso.verb | 10 ++++--
 13 files changed, 86 insertions(+), 41 deletions(-)

diff --git a/haskell98-bugs.html b/haskell98-bugs.html
index a7673bb..e8c49a2 100644
--- a/haskell98-bugs.html
+++ b/haskell98-bugs.html
@@ -96,6 +96,23 @@ to the end of Section 2.4.  (These paragraphs deal with lexical matters, which d
 <p><li> <strong>Page 9, Section 2.6, Character and String Literals.</strong>
 In the production for "cntrl" replace "ASClarge" by "ascLarge".
 
+<p><li> [Oct 2001]  <strong>Page 9, Section 2.6, Characters and String Literals; and 
+Page 73, Section 6.1.2, Characters and strings</strong>
+<ul>
+<li> In Section 2.6, delete the last sentence of the third paragraph "Numeric escapes
+that are out of range...".
+<p>
+<li> In Section 6.1.2, replace the first sentence of the section by
+<p>
+"The character type <tt>Char</tt>
+is an enumeration whose values represent Unicode characters [10]."
+</ul>
+<p>
+This change removes the commitment to 16-bit Unicode.  The result is that the Report
+is even vaguer than before about the range of Unicode that a compiler is obliged to
+accept, but this confusion is in large part Unicode's fault, and is not readily fixed 
+in a revision of this nature.
+
 <p><li> <strong>Page 10, Section 2.7, Layout.</strong>
 In the middle of the third paragraph, just before the sentence beginning
 "A close brace is also inserted...", add the following sentence:
@@ -135,7 +152,7 @@ the section, after "indistinguishable" add "by a Haskell program".
 Remove the paragraph starting "Qualified names may only ...", and the following example, and the
 concluding paragraph starting "incorrectly uses a qualifier". (This is all covered in 2.4 and 5.5.1.)
 
-<p><li> [Late Sept 2001] <strong>Page 18, Section 3.7, Lists.</strong>
+<p><li> [Oct 2001] <strong>Page 18, Section 3.7, Lists.</strong>
 After the sentence starting "The constructor ":" is reserved solely for list construction...", 
 add the new sentence:
 <p>
@@ -207,7 +224,7 @@ In clause (r) replace "e0" by "v" throughout.
 First paragraph, last sentence.  After "infix type constructors are not allowed",
 add "(other than <tt>(->)</tt>)".
 
-<p><li> [Late Sept 2001] <strong>Page 38, Section 4.1.2, Algebraic Datatype Declarations.</strong>
+<p><li> [Oct 2001] <strong>Page 38, Section 4.1.2, Algebraic Datatype Declarations.</strong>
 Replace the sentence
 "Although the tuple, list, and function types have special syntax, they
 are not different from user-defined types with equivalent
@@ -317,20 +334,37 @@ is affected by module boundaries."
 <p>
 This footnote qualifies the otherwise over-strong statement.
 
-<p><li> [Aug 2001] <strong>Page 64, Section 5.2, Export declarations, numbered item 5.</strong>
-Replace the first paragrah of this item with:
+<p><li> [Oct 2001] <strong>Page 64, Section 5.2, Export declarations, numbered items 5 and 6.</strong>
+Replace both items with the following:
 <p>
-"The form "<tt>module</tt> M" abbreviates the set of all entities whose
-names are brought into scope by one or more <em>unqualified</em> <tt>import</tt> declarations
-of the form "<tt>import</tt> M [impspec]" or "<tt>import</tt> A <tt>as</tt> M [impspec]".  This set may be empty.
-For example:"
+"The form `<tt>module M</tt>' abbreviates the set of all entities whose
+<em>unqualified</em> name, <em>e</em>, is in scope, and for which the <em>qualified</em> name
+<em>M.e</em> is also in scope and refers to the same entity as <em>e</em>.  This set
+may be empty.
+For example:
+<pre>
+  module Queue( module Stack, enqueue, dequeue ) where
+      import Stack
+      ...
+</pre>
+"Here the module <tt>Queue</tt> uses the module name <tt>Stack</tt> in its export
+list to abbreviate all the entities imported from <tt>Stack</tt>.  
+<P>
+"A module can name its own local definitions in its export
+list using its own name in the `<tt>module M</tt>'' syntax, because a local
+declaration brings into scope both a qualified and unqualified name. 
+For example:
+<pre>
+  module Mod1( module Mod1, module Mod2 ) where
+  import Mod2
+  import Mod3
+</pre>
+"Here module <tt>Mod1</tt> exports all local definitions as well as those
+imported from <tt>Mod2</tt> but not those imported from <tt>Mod3</tt>."
 
-<p><li> [Aug 2001] <strong>Page 64, Section 5.2, Export declarations.</strong>
-After the numbered items, add:
-<p>
-"It is an error to use "<tt>module</tt> M" in an export list unless M is the
-module bearing the export list, or M is imported
-by at least one <tt>import</tt> declaration (qualified or unqualified)."
+It is an error to use <tt>module M</tt> in an export list unless <tt>M</tt> is 
+the module bearing the export list, or <tt>M</tt> is imported by at 
+least one import declaration (qualified or unqualified).
 
 <p><li> [July 2001] <strong>Page 65, Section 5.2, Export declarations.</strong>
 Replace the two paragraphs and code fragment that the numbered list with the following:
@@ -339,7 +373,7 @@ Replace the two paragraphs and code fragment that the numbered list with the fol
 exported.  For example, a field name <tt>f</tt> from data type <tt>T</tt> may be exported individually
 (<tt>f</tt>, item (1) above); or as an explicitly-named member of its data type (<tt>T(f)</tt>, item (2));
 or as an implicitly-named member (<tt>T(..)</tt> item(2)); or by exporting an entire
-module (<tt>module M</tt>, item (5) or (6)).  
+module (<tt>module M</tt>, item (5)).  
 <p>
 Exports lists are cumulative: the set of entities exported by an export
 list is the union of the entities exported by the individual items of the list.
@@ -364,7 +398,7 @@ be imported...".
 Delete the two sentences "The hiding clause only applies to unqualified
 names...  A hiding clause has no effect....".
 
-<p><li> [Late Sept 2001] <strong>Page 66, Section 5.3, Import Declarations, numbered item 2.</strong>
+<p><li> [Oct 2001] <strong>Page 66, Section 5.3, Import Declarations, numbered item 2.</strong>
 Add "It is an error to hide an entity that is not, in fact, exported by
 the imported module."
 
@@ -530,7 +564,7 @@ After the above signature for <tt>userError</tt>, add the following:
     fail s = ioError (userError s)
 </pre>"
 
-<p><li> [Late Sept 2001] <strong>Page 93, Appendix A, Standard Prelude.</strong>
+<p><li> [Oct 2001] <strong>Page 93, Appendix A, Standard Prelude.</strong>
 Replace the fixity declaration for <tt>(:)</tt> by the following comments:
 <pre>
 -- The (:) operator is built-in syntax, and cannot legally be given
@@ -639,11 +673,16 @@ Replace the instances for <tt>Show Int</tt> and <tt>Read Int</tt> with
 </pre>
 The previous definitions (which are simply specifications, remember) failed on minInt.
 
+<p><li> [Oct 2001]  <strong>Page 123, Appendix B.3, Layout</strong>. 
+In the first line of the definition of L, replace "if parse-error(t)" by
+"if m /= 0 and parse-error(t)".  This checks that the implicitly-added close
+brace matches an implicit open brace.
+
 <p><li> [Aug 2001]  <strong>Page 124, Appendix B.3, Layout</strong>. 
 Near the end of the sub-section, delete from "Another place where..." to the end of the 
 sub-section.  (Note 5 covers the top-level case.)
 
-<p><li> [Late Sept 2001]  <strong>Page 130, Appendix C, Literate comments</strong>. 
+<p><li> [Oct 2001]  <strong>Page 130, Appendix C, Literate comments</strong>. 
 In paragraph 2, replace 
 "The program text is recovered
 by taking only those lines beginning with "<tt>&gt;</tt>", 
@@ -783,7 +822,7 @@ Add the following equation to the laws listed just before Section 5.1:
 </pre>
 This documents an invariant that was previously only implicit.
 
-<p><li> [Late Sept 2001] <strong>Page 17, Section 5, Indexing operations</strong>.
+<p><li> [Oct 2001] <strong>Page 17, Section 5, Indexing operations</strong>.
 This significant item makes <tt>rangeSize</tt> into a method of
 <tt>Ix</tt> rather than a free-standing declaration.  Though this
 change is visible to the programmer, all existing Haskell 98
diff --git a/libraries/README b/libraries/README
index ec348d0..c1fbc7a 100644
--- a/libraries/README
+++ b/libraries/README
@@ -13,7 +13,7 @@ To generate the html library report you need Hugs 1.4 (probably any Haskell
 1.4 compiler will do).
 
 To chage the date on the report, you must change:
-	* haskell.verb (line 415-ish)
+	* library.verb (line 415-ish)
 	* index.html (line 8-ish)
 	* html.config (~foot item)
 	
diff --git a/libraries/html.config b/libraries/html.config
index 4652974..db3f057 100644
--- a/libraries/html.config
+++ b/libraries/html.config
@@ -33,7 +33,7 @@ style=article
 ~back=<a href="~prev.html">back</a>
 ~nxt=<a href="~next.html">next</a>
 ~contents=<a href="libindex.html">contents</a>
-~foot=<br><font size=2>September 2001</font>
+~foot=<br><font size=2>October 2001</font>
 ~footer=<hr>~id~top | ~back | ~nxt | ~contents ~foot
 ~sfooter=<hr>~id~top | back | ~nxt | ~contents ~foot
 ~efooter=<hr>~id~top | ~back | next | ~contents ~foot
diff --git a/libraries/index.html b/libraries/index.html
index 3a99b22..f1b26c7 100644
--- a/libraries/index.html
+++ b/libraries/index.html
@@ -7,7 +7,7 @@
 <img src="h98-libs.gif" alt="Haskell 98 Libraries">
 
 <h3 align="center">Standard Libraries for Haskell 98</h3>
-<h3 align="center">Revised: September 2001</h3>
+<h3 align="center">Revised: October 2001</h3>
 </div>
 <hr>
 <h3>Table of Contents</h3>
diff --git a/libraries/library.verb b/libraries/library.verb
index f945db9..0c0560e 100644
--- a/libraries/library.verb
+++ b/libraries/library.verb
@@ -1,5 +1,5 @@
 %
-% $Header: /home/cvs/root/haskell-report/libraries/library.verb,v 1.10 2001/09/24 14:40:47 simonpj Exp $
+% $Header: /home/cvs/root/haskell-report/libraries/library.verb,v 1.11 2001/10/02 09:09:26 simonpj Exp $
 %
 % NOTE:--------------------------------------------------------------
 % The formatting of this report and the ``new font selection scheme''
@@ -412,7 +412,7 @@
 {\Large\bf for the} \\[.1in]
 {\huge\bf Haskell 98} \\[.3in]
 {\LARGE\bf Programming Language} \\[.3in]
-{\large\bf Revised: September 2001}
+{\large\bf Revised: October 2001}
 \end{center}
 
 \vspace{.15in}
diff --git a/report/basic.verb b/report/basic.verb
index 05fe777..25d28dd 100644
--- a/report/basic.verb
+++ b/report/basic.verb
@@ -1,5 +1,5 @@
 %
-% $Header: /home/cvs/root/haskell-report/report/basic.verb,v 1.8 2001/08/20 07:57:52 simonpj Exp $
+% $Header: /home/cvs/root/haskell-report/report/basic.verb,v 1.9 2001/10/02 09:09:26 simonpj Exp $
 %
 %**<title>The Haskell 98 Report: Basic Types and Classes</title>
 %*section 6
@@ -51,8 +51,9 @@ more readable.
 \index{character}\index{string}
 
 The character type @Char@\indextycon{Char}
-is an enumeration and consists of 16 bit values, conforming to
-the Unicode standard~\cite{unicode}.
+is an enumeration whose values represent Unicode characters~\cite{unicode}.
+% and consists of 16 bit values, conforming to
+% the Unicode standard~\cite{unicode}.
 % of which the first 128
 % are the ASCII\index{ASCII character set} character set.  
 The lexical syntax for
diff --git a/report/haskell.verb b/report/haskell.verb
index 430c3b4..99617f7 100644
--- a/report/haskell.verb
+++ b/report/haskell.verb
@@ -1,5 +1,5 @@
 %
-% $Header: /home/cvs/root/haskell-report/report/haskell.verb,v 1.10 2001/09/24 14:40:47 simonpj Exp $
+% $Header: /home/cvs/root/haskell-report/report/haskell.verb,v 1.11 2001/10/02 09:09:26 simonpj Exp $
 %
 
 % NOTE:--------------------------------------------------------------
@@ -426,7 +426,7 @@
 {\LARGE\bf Programming Language} \\[.3in]
 {\huge\bf Haskell 98} \\[.3in]
 {\Large\bf A Non-strict, Purely Functional Language} \\[.3in]
-{\large\bf Revised: September 2001}
+{\large\bf Revised: October 2001}
 \end{center}
 \vspace{.15in}
 \begin{center} \large
diff --git a/report/html.config b/report/html.config
index 638a139..2b649cd 100644
--- a/report/html.config
+++ b/report/html.config
@@ -26,7 +26,7 @@ style=article
 ~nxt=<a href="~next.html">next</a>
 ~funct=<a href="prelude-index.html">function index</a>
 ~contents=<a href="index98.html">contents</a>
-~foot=<br><font size=2>September 2001</font>
+~foot=<br><font size=2>October 2001</font>
 ~footer=<hr>~id~top | ~back | ~nxt | ~contents | ~funct ~foot
 ~sfooter=<hr>~id~top | back | ~nxt | ~contents | ~funct ~foot
 ~efooter=<hr>~id~top | ~back | next | ~contents | ~funct ~foot
diff --git a/report/index.html b/report/index.html
index d7e2b0d..7308a48 100644
--- a/report/index.html
+++ b/report/index.html
@@ -5,7 +5,7 @@
 <img src="h98.gif" alt="Haskell 98">
 
 <h3>Haskell 98: A Non-strict, Purely Functional Language</h3>
-<h3 align="center">Revised: September 2001</h3>
+<h3 align="center">Revised: October 2001</h3>
 </div>
 <hr>
 <h3>Brief Table of Contents</h3>
diff --git a/report/lexemes.verb b/report/lexemes.verb
index 145d336..2e008dd 100644
--- a/report/lexemes.verb
+++ b/report/lexemes.verb
@@ -1,5 +1,5 @@
 %
-% $Header: /home/cvs/root/haskell-report/report/lexemes.verb,v 1.7 2001/09/11 13:04:27 simonpj Exp $
+% $Header: /home/cvs/root/haskell-report/report/lexemes.verb,v 1.8 2001/10/02 09:09:26 simonpj Exp $
 %
 %*section 2
 %**<title>Haskell 98 Lexical Structure</title>
@@ -341,8 +341,9 @@ control characters such as @\^X@, are also provided.
 Numeric escapes such as @\137@ are used to designate the character
 with decimal representation 137; octal
 (e.g.~@\o137@) and hexadecimal (e.g.~@\x37@) representations are also
-allowed.  Numeric escapes that are out-of-range of the Unicode standard
-(16 bits) are an error.
+allowed.  
+% Numeric escapes that are out-of-range of the Unicode standard
+% (16 bits) are an error.
 
 Consistent with the ``maximal munch'' rule,
 \index{maximal munch rule}
diff --git a/report/modules.verb b/report/modules.verb
index 6bae426..53aabd5 100644
--- a/report/modules.verb
+++ b/report/modules.verb
@@ -1,5 +1,5 @@
 %
-% $Header: /home/cvs/root/haskell-report/report/modules.verb,v 1.12 2001/09/24 14:40:48 simonpj Exp $
+% $Header: /home/cvs/root/haskell-report/report/modules.verb,v 1.13 2001/10/02 09:09:26 simonpj Exp $
 %
 %**<title>The Haskell 98 Report: Modules</title>
 %*section 5
@@ -235,7 +235,7 @@ It makes no difference to an importing module how an entity was
 exported.  For example, a field name @f@ from data type @T@ may be exported individually
 (@f@, item (1) above); or as an explicitly-named member of its data type (@T(f)@, item (2));
 or as an implicitly-named member (@T(..)@, item(2)); or by exporting an entire
-module (@module M@, item (5) or (6)).  
+module (@module M@, item (5)).  
 
 The {\em unqualified} names of the entities exported by a module must all be distinct
 (within their respective namespace).  For example
diff --git a/report/preface-13.verb b/report/preface-13.verb
index 39d2f3a..22b0cc8 100644
--- a/report/preface-13.verb
+++ b/report/preface-13.verb
@@ -1,5 +1,5 @@
 %
-% $Header: /home/cvs/root/haskell-report/report/preface-13.verb,v 1.7 2001/09/10 08:31:58 simonpj Exp $
+% $Header: /home/cvs/root/haskell-report/report/preface-13.verb,v 1.8 2001/10/02 09:09:26 simonpj Exp $
 %
 %**<title>The Haskell 98 Report: Preface</title>
 %*section
@@ -71,7 +71,7 @@ features.
 
 \subsection{Haskell 98}
 
-Haskell has evolved continuously since its orignal publication.
+Haskell has evolved continuously since its original publication.
 By the middle of 1997, there had been four versions of the language
 (the latest at that point being Haskell 1.4).  At the 1997 Haskell Workshop 
 in Amsterdam, it was decided that a stable variant of Haskell was needed;
diff --git a/report/syntax-iso.verb b/report/syntax-iso.verb
index 4a38b40..b828fa1 100644
--- a/report/syntax-iso.verb
+++ b/report/syntax-iso.verb
@@ -1,5 +1,5 @@
 %
-% $Header: /home/cvs/root/haskell-report/report/syntax-iso.verb,v 1.4 2001/08/20 07:57:53 simonpj Exp $
+% $Header: /home/cvs/root/haskell-report/report/syntax-iso.verb,v 1.5 2001/10/02 09:09:27 simonpj Exp $
 %
 %**<title>Haskell 98 Syntax</title>
 %*section B
@@ -195,7 +195,8 @@ The definition of "L" is as follows, where we use ``":"'' as a stream
 construction operator, and ``"\emptystr"'' for the empty stream.
 \begin{center}
 \[\ba{lcll}
-     L~ (t:ts)~ (m:ms)       & = & @}@ ~:~ (L~ (t:ts)~ ms)           & \mbox{if}~ \mbox{parse-error}(t)~ (Note~ 1) \\
+     L~ (t:ts)~ (m:ms)       & = & @}@ ~:~ (L~ (t:ts)~ ms)           & \mbox{if}~ m /= 0 ~\mbox{and}~ \mbox{parse-error}(t) \\
+			    &&& (Note~ 1) \\
   \\
      L~ (<n>:ts)~ (m:ms)   & = & @;@ ~:~ (L~ ts~(m:ms))           &\mbox{if}~ m = n \\
                            & = & @}@ ~:~ (L~ (<n>:ts)~ ms)       & \mbox{if}~ n < m \\
@@ -217,9 +218,12 @@ construction operator, and ``"\emptystr"'' for the empty stream.
 \item[Note 1.] The side condition "\mbox{parse-error}(t)" is to be interpreted as follows: 
 if the tokens generated so far by "L" together with the next token "t" 
 represent an invalid prefix of the Haskell grammar, and the 
-tokens generated so far by "L" followed by the token @}@ 
+tokens generated so far by "L" followed by the token ``@}@''
 represent a valid prefix of the Haskell grammar, then "\mbox{parse-error}(t)" is true. 
 
+The test $m /= 0$ checks that an implicitly-added closing brace would match
+an implicit open brace.
+
 \item[Note 2.] By matching against 0 for the current layout context, 
 we ensure that an explicit close brace can only match an explicit open brace. 
 
-- 
GitLab