Personal tools

Future of Haskell

From HaskellWiki

(Difference between revisions)
Jump to: navigation, search
m (Heading)
m (Variations of Haskell: corrected dead link to TH)
 
(16 intermediate revisions by 13 users not shown)
Line 1: Line 1:
 
==Haskell' is the next official version==
 
==Haskell' is the next official version==
   
Haskell 98 is complete. It is
+
The [http://www.haskell.org/onlinereport/haskell2010/ Haskell 2010] report was published in July 2010, and is the current definition of the Haskell language. Compilers will also continue to support the previous version of Haskell, [http://haskell.org/onlinereport/ Haskell 98] (via a special flag).
the current official definition of Haskell (modulo some minor fixes,
 
as detailed on the Haskell 98 bug page). We expect that this
 
language will be supported in the long term even as new extensions are
 
added to Haskell; compilers will continue to support Haskell 98 (via a
 
special flag).
 
   
The process of defining a successor to Haskell 98 has started. All
+
A new standard will be defined each year. All
 
information about this is on
 
information about this is on
 
<blockquote>
 
<blockquote>
Line 12: Line 12:
   
 
The language evolves and numerous extensions have been proposed and many of them have been implemented in some Haskell systems; for example
 
The language evolves and numerous extensions have been proposed and many of them have been implemented in some Haskell systems; for example
pattern guards, scoped type variables, multi-parameter type classes, local universal and existential quantification.
+
pattern guards (which is adopted in the Haskell 2010 standard), scoped type variables, multi-parameter type classes, local universal and existential quantification.
The [[Haskell mailing lists]]
+
The Haskell [[mailing lists]]
 
are a forum for discussing new language features.
 
are a forum for discussing new language features.
 
People proposing an additional language feature should implement the new feature or convince the developers of one of the Haskell systems to do so.
 
People proposing an additional language feature should implement the new feature or convince the developers of one of the Haskell systems to do so.
 
Then many people can test the practical usefulness of the extension.
 
Then many people can test the practical usefulness of the extension.
Finally, the people seriously interested in the new feature should define the new feature with respect to Haskell 98 in a document (a new mailing list can be set up for this purpose). This kind of addendum to the Haskell 98 report clearifies the details and can be used for adding the feature to other Haskell systems. The definition of the foreign function interface (FFI) for Haskell is a good example for this process.
+
Finally, the people seriously interested in the new feature should define the new feature with respect to the current Haskell standard in a document (a new mailing list can be set up for this purpose). This kind of addendum to the Haskell report clarifies the details and can be used for adding the feature to other Haskell systems. The definition of the foreign function interface (FFI) for Haskell is a good example for this process.
   
On a rather longer time schedule a committee lead by John Launchbury
+
On a rather longer time schedule, a committee led by John Launchbury
 
may develop Haskell II. Obviously well-tested and well-described extension
 
may develop Haskell II. Obviously well-tested and well-described extension
 
proposals will have a higher chance of being adopted.
 
proposals will have a higher chance of being adopted.
Line 26: Line 26:
 
== Extensions of Haskell ==
 
== Extensions of Haskell ==
   
<DL><DT><B>[http://haskell.org/hawiki/HaskellTwo A Wiki page]</B><DD>
+
<DL>
collects all kinds of extensions proposed for the language, libraries and specific implementations.
+
<DT><B>[[:Category:Proposals|Proposals]]</B>
  +
<DD> Collects all kinds of extensions proposed for the language, libraries and specific implementations. Note that the above page is automatically generated, so to add a new proposal you can instead type the title for your page into the address bar of your browser using underscores instead of spaces, then the wiki generates a new page (assuming there is not already a page with the same title) that you can edit. If you put <pre>[[Category:Proposals]]</pre> at the top of your page, it will be automatically linked to by the [http://www.haskell.org/haskellwiki/Category:Proposals Proposals page above]. (Sometimes the convention of ending the title of a proposal with the word <tt>proposal</tt> is followed, so that people browsing the wiki can clearly see that the page describes something different that is not yet part of the current Haskell language.)
  +
</DD>
  +
  +
<DT><B>
  +
[http://www.haskell.org/mailman/listinfo/libraries The libraries mailing list]
  +
</B>
  +
<DD>Discusses, amongst others, extensions to libraries.
  +
</DD>
  +
  +
<DT><B>[http://web.archive.org/web/20061011095312/http://haskell.org/hawiki/HaskellTwo HaskellTwo on the old wiki]</B> (in the web archive)
  +
<DD> This old hawiki page contains all kinds of extensions proposed for the language, libraries and specific implementations, before the new wiki came online.</DD>
  +
 
</DL>
 
</DL>
   
Line 33: Line 33:
 
Below we present some of the various extensions that have
 
Below we present some of the various extensions that have
 
been implemented or proposed.
 
been implemented or proposed.
See also the [[Haskell mailing lists]].
+
See also the Haskell [[mailing lists]].
   
 
<UL>
 
<UL>
Line 41: Line 41:
 
<li>A [http://www.haskell.org/development/views.html views proposal] has been submitted for consideration in
 
<li>A [http://www.haskell.org/development/views.html views proposal] has been submitted for consideration in
 
future Haskell reports. Implemented in hbc (?)</li>
 
future Haskell reports. Implemented in hbc (?)</li>
<li>See also HaWiki's [http://haskell.org/hawiki/Views Views]</li>
 
 
<li>[[Dependent type]]s provide a way for not-forgetful views: views who cannot lie.
 
<li>[[Dependent type]]s provide a way for not-forgetful views: views who cannot lie.
 
</ul>
 
</ul>
Line 53: Line 52:
 
<li>Mark Shields and Simon Peyton Jones: [http://research.microsoft.com/Users/simonpj/Papers/first-class-modules/ First-class Modules for Haskell] discusses a lot of extension proposals integrated in a coherent design. See also [[First-class module]] page.
 
<li>Mark Shields and Simon Peyton Jones: [http://research.microsoft.com/Users/simonpj/Papers/first-class-modules/ First-class Modules for Haskell] discusses a lot of extension proposals integrated in a coherent design. See also [[First-class module]] page.
 
<li>[[Extensible record]] page: problems where extensible records are useful, proposals, implementations etc.
 
<li>[[Extensible record]] page: problems where extensible records are useful, proposals, implementations etc.
  +
<li>An [[Accessible layout proposal]] which would allow you to make more use of the layout rule to eliminate many commas and parentheses (particularly interesting if you don't like manually deleting then re-inserting that comma that always ends up in the wrong place when you are re-ordering a list of things by cut and paste).
  +
<li> A [[Class system extension proposal]] page, to collect ideas for making the class system more powerful, some of which have been implemented in other languages similar to Haskell.
 
</UL>
 
</UL>
   
Line 64: Line 65:
 
The user can impose conditions on overloaded identifiers via CHRs.
 
The user can impose conditions on overloaded identifiers via CHRs.
   
<DT>[http://www.cse.ogi.edu/~mpj/goferarc/index.html Gofer]
+
<DT>[http://web.cecs.pdx.edu/~mpj/goferarc/index.html Gofer]
 
<DD>
 
<DD>
 
Gofer is a small interpreter by Mark Jones supporting a language based on the Haskell report version 1.2.
 
Gofer is a small interpreter by Mark Jones supporting a language based on the Haskell report version 1.2.
Line 88: Line 89:
 
hbc.
 
hbc.
   
<DT>[http://www.score.is.tsukuba.ac.jp/~chak/goffin/ Goffin]<DD>
+
<DT>[http://www.cse.unsw.edu.au/~chak/papers/ Goffin]<DD>
 
A Haskell extension for parallel and distributed
 
A Haskell extension for parallel and distributed
programming.
+
programming. Browse [http://www.cse.unsw.edu.au/~chak/ Manuel M T Chakravarty's] page for newer work on parallel extensions to GHC.
 
 
<dt>[http://www.mondrian-script.org/ Mondrian]<dd>
 
 
Mondrian is evolving from "just" an internet scripting language to a "functional language for OO environments". Mondrian is a non-strict
 
functional language with threads, exceptions and interlanguage
 
working - a Haskell "light" with extras.
 
 
   
 
<DT>[http://www.cs.chalmers.se/~patrikj/poly/polyp/ PolyP - a polytypic programming language]<DD>
 
<DT>[http://www.cs.chalmers.se/~patrikj/poly/polyp/ PolyP - a polytypic programming language]<DD>
Line 127: Line 128:
 
fields.
 
fields.
   
<dt>[http://www.haskell.org/th/ Template Haskell]
+
<dt>[[Template Haskell]]
 
<dd>Template Haskell is an extension to Haskell 98 that allows you to do
 
<dd>Template Haskell is an extension to Haskell 98 that allows you to do
 
type-safe compile-time meta-programming, with Haskell both as the
 
type-safe compile-time meta-programming, with Haskell both as the
 
manipulating language and the language being manipulated.
 
manipulating language and the language being manipulated.
   
<dt>Dependent types</dt>
+
<dt>[http://disciple.ouroborus.net Disciple]
  +
<dd>
  +
Disciple is a dialect of Haskell that uses strict evaluation as the default and supports destructive update of arbitrary data structures. Disciple includes region, effect and closure typing, and this extra information provides a handle on the operational behaviour of code that isn't available in other languages. Programs can be written in either a pure/functional or effecful/imperative style, and one of our goals is to provide both styles coherently in the same language.
  +
  +
<dt>[[Dependent types]]
 
<dd>
 
<dd>
[[Dependent type]] wikipage on
 
 
* concept of dependent types, its usefulness in the world of programming;
 
* concept of dependent types, its usefulness in the world of programming;
 
* dependently typed languages, possiblity of not-forgetful views;
 
* dependently typed languages, possiblity of not-forgetful views;
 
* simulating dependent types in Haskell, and extending Haskell to have them.
 
* simulating dependent types in Haskell, and extending Haskell to have them.
</dd>
+
   
 
</DL>
 
</DL>
   
 
[[Category:Proposals| ]]
 
[[Category:Proposals| ]]
  +
[[Category:Language| ]]

Latest revision as of 18:09, 25 December 2012

[edit] 1 Haskell' is the next official version

The Haskell 2010 report was published in July 2010, and is the current definition of the Haskell language. Compilers will also continue to support the previous version of Haskell, Haskell 98 (via a special flag).

A new standard will be defined each year. All information about this is on

The Haskell' Wiki

The language evolves and numerous extensions have been proposed and many of them have been implemented in some Haskell systems; for example pattern guards (which is adopted in the Haskell 2010 standard), scoped type variables, multi-parameter type classes, local universal and existential quantification. The Haskell mailing lists are a forum for discussing new language features. People proposing an additional language feature should implement the new feature or convince the developers of one of the Haskell systems to do so. Then many people can test the practical usefulness of the extension. Finally, the people seriously interested in the new feature should define the new feature with respect to the current Haskell standard in a document (a new mailing list can be set up for this purpose). This kind of addendum to the Haskell report clarifies the details and can be used for adding the feature to other Haskell systems. The definition of the foreign function interface (FFI) for Haskell is a good example for this process.

On a rather longer time schedule, a committee led by John Launchbury may develop Haskell II. Obviously well-tested and well-described extension proposals will have a higher chance of being adopted.


[edit] 2 Extensions of Haskell

Proposals

Collects all kinds of extensions proposed for the language, libraries and specific implementations. Note that the above page is automatically generated, so to add a new proposal you can instead type the title for your page into the address bar of your browser using underscores instead of spaces, then the wiki generates a new page (assuming there is not already a page with the same title) that you can edit. If you put
[[Category:Proposals]]
at the top of your page, it will be automatically linked to by the Proposals page above. (Sometimes the convention of ending the title of a proposal with the word proposal is followed, so that people browsing the wiki can clearly see that the page describes something different that is not yet part of the current Haskell language.)

</DD>

The libraries mailing list
Discusses, amongst others, extensions to libraries. </DD>

HaskellTwo on the old wiki (in the web archive)
This old hawiki page contains all kinds of extensions proposed for the language, libraries and specific implementations, before the new wiki came online.</DD>

Below we present some of the various extensions that have been implemented or proposed. See also the Haskell mailing lists.

  • Views allow multiple `logical' constructors to match against real constructors in patterns.
    • A views proposal has been submitted for consideration in future Haskell reports. Implemented in hbc (?)
    • Dependent types provide a way for not-forgetful views: views who cannot lie.
  • Pattern Guards by Simon Peyton-Jones is a proposal to generalize guards used in function definitions. See the proposal for further details. Implemented in GHC, proposed for Haskell 2.
  • Basic algebra proposal. In particular: Reformulating numeric classes, instance ruled type and domain conversion.
  • Haskell Proposal: Syntactic Sugar for Arrows
  • Mark Shields and Simon Peyton Jones: First-class Modules for Haskell discusses a lot of extension proposals integrated in a coherent design. See also First-class module page.
  • Extensible record page: problems where extensible records are useful, proposals, implementations etc.
  • An Accessible layout proposal which would allow you to make more use of the layout rule to eliminate many commas and parentheses (particularly interesting if you don't like manually deleting then re-inserting that comma that always ends up in the wrong place when you are re-ordering a list of things by cut and paste).
  • A Class system extension proposal page, to collect ideas for making the class system more powerful, some of which have been implemented in other languages similar to Haskell.

[edit] 3 Variations of Haskell

Chameleon
Chameleon is a Haskell-style language which provides a flexible overloading mechanism based on Constraint Handling Rules (CHRs). The user can impose conditions on overloaded identifiers via CHRs.

Gofer
Gofer is a small interpreter by Mark Jones supporting a language based on the Haskell report version 1.2. Gofer is intended as an experimental language, particularly where type classes are involved. Although Haskell has adopted a number of ideas from Gofer, the Gofer type class system is still more flexible than the Haskell one. Available for all Unix platforms including Linux, DOS, and Macs. Hugs is the successor to Gofer and Gofer is no longer supported.
Html-version of the Gofer manual

GPH, Glasgow Parallel Haskell
is an extension of Haskell for parallel programming. It adds just two new primitives to the language, namely, a form of parallel composition par, and sequential composition seq. With judicious use of par and seq it is possible to express how a program should be evaluated in parallel.

pH - a parallel Haskell
The pH language is is a parallel, eagerly-evaluated variant of Haskell with syntactic provisions for loops, barriers, and I- and M- structure storage. The eager evaluation model of pH is similar to that of Id; the current version of the pH compiler shares a back end with the Id compiler, producing code for the Monsoon dataflow machine. The front end of the pH compiler is a modification of hbc.

Goffin
A Haskell extension for parallel and distributed programming. Browse Manuel M T Chakravarty's page for newer work on parallel extensions to GHC.

PolyP - a polytypic programming language
PolyP extends a functional language (a subset of Haskell) with a construct for writing polytypic functions. A polytypic function is a function that is defined by induction on the structure of user-defined datatypes.

O'Haskell
O'Haskell is an object-oriented extension to Haskell developed at Chalmers. O'Haskell conservatively adds two major features to the Haskell core: a monad of concurrent, state-encapsulating reactive objects, and a type system with subtyping between records as well as datatypes. An implementation is available, O'Hugs, which is a derivative of Hugs 1.3b.

Eden
Eden is a parallel functional language that provides a new perspective on parallel programming. It gives programmers enough control to implement their parallel algorithms efficiently (including granularity issues) and at the same time frees them from the low level details of process management. Eden is explicit about processes and their incoming and outgoing data, but abstracts from the transfer of these data between processes and the necessary synchronisation. Eden extends the Haskell but overrules lazy evaluation whenever it is necessary to support parallelism.

Curry
Curry combines in a seamless way features from functional programming (nested expressions, higher-order functions, lazy evaluation), logic programming (logical variables, partial data structures, built-in search), and concurrent programming (concurrent evaluation of expressions with synchronization on logical variables). Many Haskell programs are also valid Curry programs.

Data Field Haskell
Data Field Haskell implements an instance of Data Fields, a generalization of arrays. The purpose is to support generic array- and data parallel programming on a very high level, for rapid prototyping of parallel algorithms. The most important language extension to Haskell is the forall-construct, which allows convenient definitions of data fields.

Template Haskell
Template Haskell is an extension to Haskell 98 that allows you to do type-safe compile-time meta-programming, with Haskell both as the manipulating language and the language being manipulated.

Disciple
Disciple is a dialect of Haskell that uses strict evaluation as the default and supports destructive update of arbitrary data structures. Disciple includes region, effect and closure typing, and this extra information provides a handle on the operational behaviour of code that isn't available in other languages. Programs can be written in either a pure/functional or effecful/imperative style, and one of our goals is to provide both styles coherently in the same language.

Dependent types

  • concept of dependent types, its usefulness in the world of programming;
  • dependently typed languages, possiblity of not-forgetful views;
  • simulating dependent types in Haskell, and extending Haskell to have them.