The Genesis of F#
F# began in 2002, when Don Syme and others at Microsoft Research decided to ensure that the ML approach to pragmatic but theoretically based language design found a high-quality expression for the. NET platform. The project was closely associated with the design and implementation of Generics for the. NET Common Language Runtime. The first stabilized, supported version of F# is F# 2.0, and this is the version of the language described in this book and is also the version included with Visual Studio 2010. F# shares a core language with the programming language OCaml, and in some ways it can be considered an OCaml for. NET. F# wouldn’t exist without OCaml, which in turn comes from the ML family of programming languages, which dates back to 1974. F# also draws from Haskell, particularly with regard to two advanced language features: sequence expressions and workflows. Strong connections still exist between the designers of these languages, and their user communities overlap.
Despite the similarities to OCaml and Haskell, programming with F# is quite different. In particular, the F# approach to type inference, OO programming, and dynamic language techniques is substantially different from all other mainstream functional languages. Programming in F# tends to be more object-oriented than in other functional languages. Programming also tends to be more flexible. F# embraces. NET techniques such as dynamic loading, dynamic typing, and reflection, and it adds techniques such as expression quotation and active patterns. We cover these topics in this book and use them in many application areas. F# also owes a lot to the designers of. NET, whose vision of language interoperability between C++, Visual Basic, and the language that eventually became C# is still rocking the computer industry. Today, F# draws much from the broader community around the Common Language Infrastructure (CLI).
This standard is implemented by the Microsoft. NET Framework, Mono, and Microsoft’s client-side execution environment Silverlight. F# is able to leverage libraries and techniques developed by Microsoft, the broader. NET community, the highly active open source community centered around Mono, and open source and cross-platform implementation of the ECMA CLI standard that works well on Windows, Mac, and Linux environments. These include hundreds of important libraries and major implementation stacks such as language-integrated queries using Microsoft’s LINQ.
The Genesis of F#