|
|   |
|
|   |
functional, non-strict, modular
|
|   |
1998
|
|   |
strong, static
|
|   |
|
|   |
--
|
|   |
GHC , Hugs , NHC , JHC
|
|   |
Miranda , ML , Gofer
|
is a standardized
Pure Functional Programming Language with
Non-strict Semantics , named after the logician
Haskell Curry . It was created by a committee formed in
1987 for the express purpose of defining such a language. The direct predecessor of Haskell was
Miranda , devised in
1985 .
The latest official language standard outside the standardization organizations is , intended to specify a minimal, portable version of the language for teaching and as a base for future extensions.
The language continues to evolve rapidly, with
Hugs and
GHC (see below) representing the current
''de Facto'' Standard .
Characterizing syntax features in Haskell include
Pattern Matching ,
Currying ,
List Comprehension s,
Guard s, and definable
Operator s. The language also supports
Recursive functions and
Algebraic Data Type s, as well as
Lazy Evaluation . Unique concepts include
Monad s, and
Type Class es.
The combination of such features can make
Functions which would be difficult to write in a procedural programming language almost trivial to implement in Haskell.
The language is, as of and
Mondrian .
There is also a Haskell-like language that offers a new method of support for
GUI development called
Concurrent Clean . Its biggest deviation from Haskell is in the use of
Uniqueness Type s for input instead of
Monads .
Although Haskell has a comparatively small user community, its strengths have been well applied to a few projects.
Audrey Tang 's
Pugs is an implementation for the forthcoming Perl 6 language with an interpreter and compilers that proved useful already after just a few months of its writing.
Darcs is a revision control system, with several innovative features.
A simple example that is often used to demonstrate the syntax of
Functional Language s is the
Factorial function, shown in Haskell:
fac :: Integer -> Integer
fac 0 = 1
|   |
1 fac n n > 0 = n fac (n-1) }
|
|   |
0 : 1 : a+b a <- fibs b <- tail fibs
|
|   |
(foldl () id -> xk k <- [1n ]) 1</nowiki>
|
|   |
=y = x : xs#ys
|
|   |
x : xs#yys
|
|   |
y : xxs#ys
|