From a1ba51db4b4721ceafbdc13338f339bedbecb78d Mon Sep 17 00:00:00 2001 From: David Waern Date: Fri, 11 Sep 2009 11:25:40 +0000 Subject: Add reference output for CrossPackageDocs --- tests/tests/CrossPackageDocs.html.ref | 745 ++++++++++++++++++++++++++++++++++ 1 file changed, 745 insertions(+) create mode 100644 tests/tests/CrossPackageDocs.html.ref (limited to 'tests') diff --git a/tests/tests/CrossPackageDocs.html.ref b/tests/tests/CrossPackageDocs.html.ref new file mode 100644 index 00000000..fd6c0c2e --- /dev/null +++ b/tests/tests/CrossPackageDocs.html.ref @@ -0,0 +1,745 @@ + + +CrossPackageDocs
 ContentsIndex
CrossPackageDocs
Synopsis
map :: (a -> b) -> [a] -> [b]
class Monad m where
(>>=) :: m a -> (a -> m b) -> m b
(>>) :: m a -> m b -> m b
return :: a -> m a
fail :: String -> m a
runInteractiveProcess :: FilePath -> [String] -> Maybe FilePath -> Maybe [(String, String)] -> IO (Handle, Handle, Handle, ProcessHandle)
data MVar a = MVar (MVar# RealWorld a)
newEmptyMVar :: IO (MVar a)
Documentation
map :: (a -> b) -> [a] -> [b]

map f xs is the list obtained by applying f to each element + of xs, i.e., +

map f [x1, x2, ..., xn] == [f x1, f x2, ..., f xn] + map f [x1, x2, ...] == [f x1, f x2, ...] +
class Monad m where

The Monad class defines the basic operations over a monad, +a concept from a branch of mathematics known as category theory. +From the perspective of a Haskell programmer, however, it is best to +think of a monad as an abstract datatype of actions. +Haskell's do expressions provide a convenient syntax for writing +monadic expressions. +

Minimal complete definition: >>= and return. +

Instances of Monad should satisfy the following laws: +

return a >>= k == k a + m >>= return == m + m >>= (\x -> k x >>= h) == (m >>= k) >>= h +

Instances of both Monad and Functor should additionally satisfy the law: +

fmap f xs == xs >>= return . f +

The instances of Monad for lists, Data.Maybe.Maybe and System.IO.IO +defined in the Prelude satisfy these laws. +

Methods
(>>=) :: m a -> (a -> m b) -> m b
Sequentially compose two actions, passing any value produced + by the first as an argument to the second. +
(>>) :: m a -> m b -> m b
Sequentially compose two actions, discarding any value produced + by the first, like sequencing operators (such as the semicolon) + in imperative languages. +
return :: a -> m a
Inject a value into the monadic type. +
fail :: String -> m a
Fail with a message. This operation is not part of the + mathematical definition of a monad, but is invoked on pattern-match + failure in a do expression. +
show/hide Instances
runInteractiveProcess
:: FilePathFilename of the executable +
-> [String]Arguments to pass to the executable +
-> Maybe FilePathOptional path to the working directory +
-> Maybe [(String, String)]Optional environment (otherwise inherit) +
-> IO (Handle, Handle, Handle, ProcessHandle)

Runs a raw command, and returns Handles that may be used to communicate + with the process via its stdin, stdout and stderr respectively. +

For example, to start a process and feed a string to its stdin: +

(inp,out,err,pid) <- runInteractiveProcess "..." + forkIO (hPutStr inp str) +

The Handles are initially in binary mode; if you need them to be + in text mode then use hSetBinaryMode. +

data MVar a
An MVar (pronounced "em-var") is a synchronising variable, used +for communication between concurrent threads. It can be thought of +as a a box, which may be empty or full. +
Constructors
MVar (MVar# RealWorld a)
show/hide Instances
newEmptyMVar :: IO (MVar a)
Create an MVar which is initially empty. +

Bugs: +

  • [] a +
  • No instances list +
  • No docs on function arguments +
Produced by Haddock version 2.5.0
-- cgit v1.2.3