1 <sect1 id="release-6-0">
2 <title>Release notes for version 6.0</title>
5 <title>User-visible compiler changes</title>
8 <para>Template Haskell, a new feature for compile-time
9 metaprogramming has been introduced. See <xref
10 linkend="template-haskell">.</para>
13 <para>INLINE pragmas on methods in class or instance
14 declarations now work properly.</para>
17 <para>Recursive do-notation (aka <literal>mdo</literal>) is
18 now supported. See <xref linkend="mdo-notation">.</para>
21 <para>There is now a native code generator for PowerPC
25 <para>Profiling: the <option>-xt</option> RTS option enables
26 inclusion of thread stacks in a heap profile. See <xref
27 linkend="rts-options-heap-prof">.</para>
30 <para>Non-blocking I/O is now supported on Windows.</para>
33 <para>The <ulink url="../base/Data.Dynamic.html#Typeable"><literal>Typeable</literal></ulink> class can now be
34 derived, and the implementation of <literal>Typeable</literal>
35 is now more efficient.</para>
41 <title>User-visible interpreter (GHCi) changes</title>
44 <para>Loading a <literal>Main</literal> module that does not
45 define <literal>main</literal> is no longer an error, although
46 GHCi will still emit a warning in this case.</para>
52 <title>User-visible library changes</title>
55 <para>Hierarchical libraries are now available without needing
56 to specify an explicit <option>-package</option> flag. There
57 are some exceptions to this rule (see <xref
58 linkend="using-packages">), but if you stick to GHCi and
59 <option>--make</option> mode then there will normally be no
60 need to specify <option>-package</option> options at
63 <para>Non-hierarchical libraries
64 (i.e. <literal>hslibs</literal> libraries) still need to be
65 explicitly requested with <option>-package</option>
70 <para>The <literal>Posix</literal> library has been rewritten.
71 It is now a hierarchical library rooted at
72 <literal>System.Posix</literal>, and has some additions aimed
73 at supporting the latest revision of the POSIX standard (IEEE
74 Std 1003.1-2001). See the <ulink
75 url="../unix/index.html"><literal>unix</literal>
76 package</ulink> for details.</para>
78 <para>The old <literal>posix</literal> package is still
79 available for backwards compatibility, but is deprecated and
80 will be removed in a future release.</para>
84 <para><ulink url="../base/Data.IORef.html"><literal>Data.IORef</literal></ulink>: Added <literal>atomicModifyIORef</literal>.</para>
88 <para><ulink url="../base/System.Cmd.html"><literal>System.Cmd</literal></ulink>: Added <literal>rawSystem</literal>.</para>
93 url="../base/System.Environment.html"><literal>System.Environment</literal></ulink>:
94 Added <literal>withArgs</literal> and <literal>withProgName</literal>.</para>
99 url="../base/Network.Socket.html"><literal>Network.Socket</literal></ulink>:
100 Added <literal>sendFd</literal> and <literal>recvFd</literal>.</para>
104 <para>The <literal>Readline</literal> library has moved to
106 url="../readline/System.Console.Readline.html"><literal>System.Console.Readline</literal></ulink>,
107 and is in a package of its own
108 (<literal>readline</literal>).</para>
112 <para>The non-hierarchical versions of the FFI libraries are
113 now all available without needing to specify <literal>-package
114 lang</literal> (they are actually now in the
115 <literal>haskell98</literal> package, which is available by
121 url="../network/Network.BSD.html"><literal>Network.BSD</literal></ulink>:
122 <literal>symlink</literal> and <literal>readline</literal> are
124 <literal>System.Posix.createSymbolicLink</literal> and
125 <literal>System.Posix.readSymbolicLink</literal>
131 url="../base/Control.Exception.html"><literal>Control.Exception</literal></ulink>:
132 Added <literal>mapException</literal>.</para>
137 url="../base/Data.Dynamic.html"><literal>Data.Dynamic</literal></ulink>:
138 various changes to make the implementation of
139 <literal>Typeable</literal> more efficient. This entails some
140 changes to the interface, and affects how instances of
141 <literal>Typeable</literal> are defined.</para>
146 url="../base/Data.Tree.html"><literal>Data.Tree</literal></ulink>
147 is a new library for trees.</para>
152 url="../base/Data.Graph.html"><literal>Data.Graph</literal></ulink>
153 is a new library for graphs.</para>
158 url="../base/System.IO.html"><literal>System.IO</literal></ulink>:
159 Removed <literal>bracket</literal> and
160 <literal>bracket_</literal> (use the versions from
161 <literal>Control.Exception</literal> instead).</para>
166 url="../base/System.IO.html"><literal>System.IO</literal></ulink>:
167 The <literal>IOError</literal> type is now a synonym for
168 <literal>IOException</literal>, whereas previously it was a
169 synonym for <literal>Exception</literal>. This has various
170 consequences, one of which is that the types of
171 <literal>System.IO.catch</literal> and
172 <literal>Control.Exception.catch</literal> are now different
173 (useful, because they do different things).</para>
178 url="../base/System.IO.Error.html"><literal>System.IO.Error</literal></ulink>:
179 added <literal>annotateIOError</literal>,
180 <literal>modifyIOError</literal>, and <literal>ioeSet{ErrorType,ErrorString,Handle,FileName}</literal>.</para>
185 url="../base/Text.ParserCombinators.ReadP.html"><literal>Text.ParserCombinators.ReadP</literal></ulink>:
186 lots of updates.</para>
190 <para><literal>Control.Monad.Monoid</literal> is now <ulink url="../base/Data.Monoid.html"><literal>Data.Monoid</literal></ulink>.</para>
195 url="../base/Data.PackedString.html"><literal>Data.PackedString</literal></ulink>:
196 added <literal>joinPS</literal>, <literal>unwordsPS</literal>
197 and <literal>unlinesPS</literal>.</para>
202 url="../base/Data.HashTable.html"><literal>Data.HashTable</literal></ulink>
203 is a new dynamic hash-table implementation.</para>
208 url="../unix/System.Sendfile.html"><literal>System.Sendfile</literal></ulink>.</para>
213 url="../base/Foreign.Marshal.Pool.html"><literal>Foreign.Marshal.Pool</literal></ulink>.</para>
218 url="../base/Data.Bits.html"><literal>Data.Bits</literal></ulink>:
219 <literal>shiftL</literal>, <literal>shiftR</literal>,
220 <literal>rotateL</literal>, and <literal>rotateR</literal> are
221 now methods of the <literal>Bite</literal> class.</para>
225 <para>The FFI libraries now conform to the latest version of
230 url="../base/Foreign.ForeignPtr.html#mallocForeignPtr"><literal>Foreign.ForeignPtr.mallocForeignPtr</literal></ulink>
234 <para>Finalizers added to a <literal>ForeignPtr</literal>
235 with <literal>addForeignPtrFinalizer</literal> are now run
236 in strict order; namely the reverse of the order they were
240 <para><literal>Foreign.C.TypesISO</literal> has been
242 url="../base/Foreign.C.Types.html"><literal>Foreign.C.Types</literal></ulink>.</para>
250 <title>Experimental features</title>
253 <para>The <literal>Data</literal> class provides for generic
254 data traversals and folds; see <ulink
255 url="../base/Data.Generics.html"><literal>Data.Generics</literal></ulink>.
256 <literal>Data</literal> can be derived for arbitrary
257 datatypes. The <literal>Data</literal> class is still
258 experimental, so its contents may change in the future.</para>
261 <para>Several bugs have been fixed in the threaded RTS, and it
262 should now be rather more robust (it should still be
263 considered experimental, however).</para>
269 <title>Internal changes</title>
272 <para>Sweeping changes to the compiler and runtime system to
273 change the evaluation model from <quote>push/enter</quote> to
274 <quote>eval/apply</quote>. The bottom line is that the
275 compiler is now more portable and some of the complexity is
276 now more centralised, while performance and binary sizes
277 remain about the same.</para>
279 <para>A paper describing these changes can be found <ulink
280 url="http://research.microsoft.com/~simonpj/papers/eval-apply">here</ulink>.</para>
283 <para>The test suite is now driven by a Python script and is
284 rather more flexible and robust. It now supports building
285 tests several different "ways", and as a result we now run
286 each test with optimisation, profiling, native code
287 generation, and GHCi in addition to the vanilla way.</para>
290 <para>The build system now supports bootstrapping the compiler
291 in a single build tree. By default, typing
292 <literal>make</literal> at the top level will bootstrap the
293 compiler once to create a stage-2 compiler. See the Building
294 Guide for more details.</para>
297 <para>The RTS debugging flags are no longer represented by a
298 bitfield and now have single-character names. For example, to
299 turn on scheduler debugging output, use <literal>-Ds</literal>
300 rather than <literal>-D1</literal>.</para>
303 <para>The compiler no longer requires any packages from
304 <literal>hslibs</literal> to bootstrap. It is enough to
305 compile <literal>fptools/libraries</literal> before building
306 the stage 2 compiler.</para>
314 ;;; Local Variables: ***
316 ;;; sgml-parent-document: ("users_guide.sgml" "book" "chapter" "sect1") ***