background preloader

Tools & ref

Facebook Twitter

Structure of a Haskell project. The intention behind this page is to flesh out some semi-standard for the directory structure, and the tool-setup for medium to large-sized Haskell projects. It is intended to make it easier for newcomers to start up projects, and for everybody to navigate others projects. Newcomers should also read How to write a Haskell program for more detailed instructions on setting up a new project.

Especially I hope some focus can be made on how to make the different tools play well together, and giving the project structure that allows scaling. Hopefully someone more qualified than I (the initiator of this page) will be summoned and write their advices, change the faults, add missing bits and discuss differences in opinions. And perhaps a sample project (in the spirit of HNop, but with broader ambitions) should be made, so that can be used as a template. 1 Tools It is recommended to make use of the following tool chain: 2 Directory Structure. The Haskell Road to Logic, Maths and Programming. Sample from the book (table of contents plus first chapter): compressed postscript Addendum to Chapter 9 of the Book: Direct Computation of Polynomial Representations for Sequences: Errata A list of errata is here.

The Haskell Road to Logic, Maths and Programming

Software. Home Page. (like github for darcs) Highest Voted 'haskell' C9 Lectures: Dr. Erik Meijer - Functional Programming Fundamentals, Chapter 1 of 13. Welcome to a new technical series on Channel 9 folded into a different kind of 9 format: C9 Lectures.

C9 Lectures: Dr. Erik Meijer - Functional Programming Fundamentals, Chapter 1 of 13

These are what you think they are, lectures. They are not conversational in nature (like most of what you're used to on 9), but rather these pieces are entirely focused on education, coming to you in the form of a series of high quality technical lectures (1 or more per topic) on a single topic. We kick off C9 Lectures with a journey into the world of Functional Programming with functional language purist and high priest of the lambda calculus, Dr. Erik Meijer (you can thank Erik for many of the functional constructs that have shown up in languages like C# and VB.NET. When you use LINQ, thank Erik in addition to Anders). Lecture Context: Over the past two years, you've learned a fair amount about the functional programming paradigm's foray into general purpose imperative progamming languages (LINQ, Lambda's, etc in C# and VB.NET).

Real World Haskell. Learn You a Haskell for Great Good! Hierarchical Libraries. Hoogle - st lib. Hoogle is a Haskell API search engine, which allows you to search many standard Haskell libraries by either function name, or by approximate type signature.

Hoogle - st lib

Example searches: map (a -> b) -> [a] -> [b] Ord a => [a] -> [a] Data.Map.insert Enter your own search at the top of the page. The Hoogle manual contains more details, including further details on search queries, how to install Hoogle as a command line application and how to integrate Hoogle with Firefox/Emacs/Vim etc. I am very interested in any feedback you may have. Haskell Platform from Source on Unix-Like. 4.12. Using shared libraries. On some platforms GHC supports building Haskell code into shared libraries.

4.12. Using shared libraries

Shared libraries are also sometimes known as dynamic libraries, in particular on Windows they are referred to as dynamic link libraries (DLLs). Shared libraries allow a single instance of some pre-compiled code to be shared between several programs. In contrast, with static linking the code is copied into each program. Using shared libraries can thus save disk space. They also allow a single copy of code to be shared in memory between several programs that use it. In GHC version 6.12 building shared libraries is supported for Linux on x86 and x86-64 architectures and there is partial support on Windows (see Section 11.6, “Building and using Win32 DLLs ”). Building and using shared libraries is slightly more complicated than building and using static libraries.

The Haskell 98 Language Report - Contains Prelude. Simon Peyton Jones [editor], Microsoft Research, Cambridge Lennart Augustsson, Sandburst Corporation Dave Barton, Intermetrics Brian Boutel, Victoria University of Wellington Warren Burton, Simon Fraser University Joseph Fasel, Los Alamos National Laboratory Kevin Hammond, University of St.

The Haskell 98 Language Report - Contains Prelude

Andrews Ralf Hinze, University of Bonn Paul Hudak, Yale University John Hughes, Chalmers University of Technology Thomas Johnsson, Chalmers University of Technology Mark Jones, Oregon Graduate Institute John Launchbury, Oregon Graduate Institute Erik Meijer, Microsoft Corporation John Peterson, Yale University Alastair Reid, University of Utah Colin Runciman, York University Philip Wadler, Avaya Labs Copyright (c) Simon Peyton Jones. The authors intend this Report to belong to the entire Haskell community, and so we grant permission to copy and distribute it for any purpose, provided that it is reproduced in its entirety, including this Notice.

Hayoo! - hackage search. Hayoo!

Hayoo! - hackage search

Will search all packages from Hackage, including all function and type definitions. Here are some example queries: map searches for everything that contains a word starting with "map" (case insensitive) in the function name, module name or description. Neil Mitchell - HLint. HLint (formerly Dr. Haskell) reads Haskell programs and suggests changes that hopefully make them easier to read. HLint also makes it easy to disable unwanted suggestions, and to add your own custom suggestions. Running the tool over the darcs source code, we can generate an interactive report with --report, or view the results in the console: $ hlint darcs-2.1.2 CommandLine.lhs:49:1: Warning, eta reduce Found: quotedArg ftable = between (char '"') (char '"') $ quoteContent ftable Why not: quotedArg = between (char '"') (char '"') . quoteContent CommandLine.lhs:94:1: Error, use concatMap Found: concat $ map escapeC s Why not: concatMap escapeC s Ssh.hs:155:17: Error, use isPrefixOf Found: take 1 path == "~" Why not: "~" `isPrefixOf` path ... many other suggestions ...

HLint can only be compiled by GHC 6.10.1 or above (it makes use of view patterns), but does not require any copy of GHC to run. Related work. Installing leksah, gtk, gtk2hs, and glade on Ubuntu 10.04 LTS -the Lucid Lynx. Mode for Emacs. There are many Emacs packages and modules for Haskell.

mode for Emacs

The most prominent ones are haskell-mode, ghc-mod and Scion. 1 Newbie guide Emacs is an extensible texteditor which can be extended with so-called "modes" and makes great use of keystrokes. Modes are written in Emacs Lisp (.el) programming language and provide additional commands and keystrokes.