[project @ 1997-09-03 23:45:01 by sof]
[ghc-hetmet.git] / ghc / RELEASE
index 3977e1f..4a11ba1 100644 (file)
-This is the pre-mangled text of the 2.02-specific part of the 
-GHC release notes.
+This is the release notes for GHC-2.04, describing what's new since the
+previous release:
 
-======================================================================
-Release~2.02 is the first release of Glasgow Haskell for Haskell~1.4.
+GHC 2.04 is a minor upgrade of GHC 2.02 (and the bugfix release,
+2.03), representing work done through May '97. This new release
+adds the following:
 
-The announcement for this release is distributed as \tr{ANNOUNCE-2.02}
-in the top-level directory.  It contains very important caveats about
-2.02, which we do not repeat here!
+* Data constructors can now have polymorphic fields, and ordinary
+  functions can have polymorphic arguments.  Details on
 
-Information about ``what's ported to which machine'' is in the
-Installation Guide.  Since 2.01, we've added support for Win32
-(Windows NT and Windows 95).
-
-%************************************************************************
-%*                                                                      *
-\subsection[2-02-config]{New configuration things in 2.02}
-%*                                                                      *
-%************************************************************************
-
-%************************************************************************
-%*                                                                      *
-\subsection[2-02-user-visible]{User-visible changes in 2.02, including incompatibilities}
-%*                                                                      *
-%************************************************************************
-
-GHC~2.02 is a compiler for Haskell~1.4 and, as such, introduces a
-bunch of user-visible changes.  The GHC user's guide has a section to
-help you upgrade your programs to Haskell~1.4 from 1.2; all
-user-visible changes are described there (and not repeated here).
-
-%************************************************************************
-%*                                                                      *
-\subsection[2-02-options]{New or changed GHC command-line options}
-%*                                                                      *
-%************************************************************************
-
-\begin{itemize}
-\item GHC now warns of possibly-incomplete patterns in case expressions
-and function bindings.  You can suppress these warnings with @-fno-warn-incomplete-patterns@.
-
-GHC also warns of completely overlapped patterns.  You can't switch this off.
-
-\item GHC can warn of shadowed names, though it does not do so by default.  
-Just occasionally this shows up 
-an otherwise hard-to-find bug.  To warn of shadowed names use @-fwarn-name-shadowing@
-
-\item You can now generate `make' dependencies via the compiler
-driver, use the option @-M@ together with the list source files to compute
-the dependencies for. By default, the dependencies will be appended to
-the file \tr{Makefile} in the current directory.
-
-\item For hackers, the flag @-dshow-rn-trace@ shows what the renamer is up to.
-Sit back and marvel.
-
-\end{itemize}
-
-
-%************************************************************************
-%*                                                                      *
-\subsection[2-02-new-in-compiler]{New in the compiler proper}
-%*                                                                      *
-%************************************************************************
-
-\begin{itemize}
-\item
-Completely new ``make-world'' system, properly documented (at last) in the
-installation guide.  No Jmakefiles; but you *need* Gnu make
-(gmake). The more recent the better (v 3.70+).
-
-\item
-The ``renamer''---the part of the compiler that implements
-the Haskell module system---has been completely rewritten, again.
-
-The format of interface files has changed significantly.  Interface files
-generated by 2.01 will not work with 2.02.
-
-\item
-Even less special pleading for the Prelude than in 2.01.  If you wanted
-to write your own Prelude and drop it in, you would have
-a really good chance now.
-\end{itemize}
-
-
-%************************************************************************
-%*                                                                      *
-\subsection[2-02-new-in-libraries]{In the libraries}
-%*                                                                      *
-%************************************************************************
-
-The libraries have been completely reorganised.  There's a description in
-\sectionref{syslibs}.
-
-
-%************************************************************************
-%*                                                                      *
-\subsection[2-02-new-in-syslibs]{In ``hslibs'' libraries}
-%*                                                                      *
-%************************************************************************
-
-
-%************************************************************************
-%*                                                                      *
-\subsection[2-02-new-in-rts]{In the runtime system}
-%*                                                                      *
-%************************************************************************
-
-\begin{itemize}
-\item @ForeignObjs@ are properly deallocated when execution halts, as well
-as when the garbage collector spots the @ForeignObj@ as being unreferenced.
-This is important if you are using a @ForeignObj@ to refer to
-a @COM@ object or other remote resource. You want that resource to be relased
-when the program terminates.
-
-\item Files handles in the IO prelude are implemented using
-@ForeignObjs@, and closed when the file handle is unreferenced.  This
-means that if you open zillions of files then just letting go of the
-file handle is enough to close it. 
-\end{itemize}
-
-%************************************************************************
-%*                                                                      *
-\subsection[2-02-new-elsewhere]{Other new stuff}
-%*                                                                      *
-%************************************************************************
-
-2.02 is released together with Green Card, a foreign-language
-interface generator for Haskell. More details elsewhere...
-
-
-%************************************************************************
-%*                                                                      *
-\subsection[2-02-troublespots]{Known troublespots}
-%*                                                                      *
-%************************************************************************
-
-The 2.02 compiler has the following known deficiencies:
-
-\begin{description}
-\item[native code generator, x86:]
-
-The native code generator for x86 platforms is by default switched
-off, as the code the compiler produces with it enabled was discovered
-just before releaseing to be wonky. Rather than delay the release
-further, GHC on x86 platforms rely on \tr{GCC} as their
-backend for now. Hopefully fixed soon.
-
-\item[Simplifier looping:]
-
-The simplifier(Glasgow-speak for optimiser) has been observed to get
-into a loop in one or two cases. If you should observe this, please
-report it as a bug - the work around is to turn off optimisation.
-
-\item[Undefined @*_vap_info@ symbols:]
-
-If the linker complains about some undefined @*_vap_info@ symbols when
-linking 2.02 compiled programs (very unlikely) - fix this by compiling
-the module where the references are coming from with
-@-fno-lambda-lifting@.
-
-\end{description}
+    http://www.cse.ogi.edu/~simonpj/quantification.html
+
+  Existential types coming, but not done yet.
+
+* Pattern guards implemented, see
+       
+   http://www.cse.ogi.edu/~simonpj/guards.html
+
+* Compiler can now compile itself.
+
+* INLINE pragmas honoured (caveat: not yet
+   working on instance-decl methods) 
+
+* Simplifier improvements and better inlining gives
+   better code; not sure how *much* better.
+
+* -dshow-rn-stats print out amusing statistics about what
+  the renamer does.
+
+* When compiling without -O, the renamer (the pass responsible for
+  slurping in interface file and making sure everything is in scope
+  etc.) is now more careful about what it will bring in (especially
+  data constructors and instance declarations). The upshot of this
+  change is that a lot of the (unnecessary) work this pass did in
+  2.02/2.03 is now avoided.
+
+  -fno-prune-tydecls and -fno-prune-instdecls switch off these
+  renamer optimisations. You can try the effect with the renamer
+  statistics. War stories welcome.
+
+* The Heroic Efforts of \tr{Andr\'e Santos <alms@di.ufpe.br>} have
+  been included, AIX/RS6000 is now a supported \tr{ghc}
+  platform! Bug reports concerning this port to (as always)
+  glasgow-haskell-bugs@dcs.gla.ac.uk
+
+* A lot of the bugs that were present in versions 2.02/2.03
+  have been fixed (thanks to everyone that reported bugs!).
+  A list of the reported problems with 2.02/2.03 can be found at
+
+    http://www.dcs.gla.ac.uk/fp/software/ghc/ghc-bugs.html
+
+    No doubt entries for 2.04 will be added here as well :-)
+
+* This release is available in source format only. To build it you'll
+  need to have either a copy of GHC~0.29 or GHC~2.02/3 installed.
+  For people either doing porting work or work on a (supported) 
+  platform for which there is no GHC binary bundles available, the
+  necessary intermediate files are also available (.hc and .hi files).
+
+  Consult the installation guide for more information on how
+  to build or bootstrap. The guide is included in the distribution
+  (in the fptools/docs directory), and an on-line version of the
+  document can be found at
+
+    http://www.dcs.gla.ac.uk/fp/software/ghc/ghc-doc/install-guide.html
+
+
+In addition to the above, we've made the following minor changes to
+the GHC libraries/our implementation of the Haskell standard prelude:
+
+* `isPrefixOf' and `isSuffixOf' has been added to `List'
+* The empty type `Void' is now exported from the prelude.
+* `GlaExts' exports the `Lift' data type:
+
+    data Lift a = Lift a
+
+  you might need it someday...
+
+* The `Foreign' interface now also exports the representations
+  for `Word' and `Addr'
+
+* The low-level file handle interface in the POSIX system
+  library has been reworked a bit, most notably is the renaming of
+  `Channel' to `Fd' and the introduction of operations for converting
+  to and from `Handle' and `Fd' values. The changes are:
+
+   --Renamed functions (old name in square brackets)
+   openFd :: FilePath       
+          -> OpenMode 
+          -> Maybe FileMode 
+          -> OpenFileFlags 
+          -> IO Fd
+    -- [openChannel]
+   fdSeek  :: Fd -> SeekMode -> FileOffset -> IO FileOffset 
+    --[seekChannel]
+   fdRead  :: Fd -> ByteCount -> IO (String, ByteCount)     
+    --[readChannel]
+   fdWrite :: Fd -> String -> IO ByteCount                  
+    --[writeChannel]
+   fdClose :: Fd -> IO ()          
+    --[closeChannel]
+   setFdOption :: Fd -> FdOption -> Bool -> IO ()
+    --[setChannelOption]
+   queryFdOption :: Fd -> FdOption -> IO Bool
+    --[queryChannelOption]
+   dup :: Fd -> IO Fd
+    --[dupChannel]
+   dupTo :: Fd -> Fd -> IO ()
+    --[dupChannelTo]
+
+   data FdOption = AppendOnWrite | CloseOnExec | NonBlockingRead
+    --[ChannelOption]
+   getFdStatus :: Fd -> IO FileStatus
+    --[getChannelStatus]
+
+   -- New data structure collecting together misc flags passed to openFd
+   data OpenFileFlags =
+    OpenFileFlags {
+      append    :: Bool,
+      exclusive :: Bool,
+      noctty    :: Bool,
+      nonBlock  :: Bool,
+      trunc     :: Bool
+    }
+
+   --New ops for converting between Fd and Handle:
+   fdToHandle :: Fd -> IO Handle
+   handleToFd :: Handle -> IO Fd
+   intToFd    :: Int -> Fd -- use with care.