Commit f478c5a4 authored by simonmar's avatar simonmar
Browse files

[project @ 2002-04-26 12:48:16 by simonmar]

- Add proper module headers to these guys
- Remove \$Id\$
- Update copyrights
- Int.lhs and Word.lhs were just wrapped in \begin{code}..\end{code},
  so make them .hs files instead.
parent cf1acc88
% -----------------------------------------------------------------------------
% $Id: Arr.lhs,v 1.3 2002/04/01 09:19:18 simonpj Exp $
%
% (c) The University of Glasgow, 1994-2000
%
\section[GHC.Arr]{Module @GHC.Arr@}
Array implementation, @GHC.Arr@ exports the basic array
types and operations.
For byte-arrays see @GHC.ByteArr@.
\begin{code}
{-# OPTIONS -fno-implicit-prelude #-}
-----------------------------------------------------------------------------
-- |
-- Module : GHC.Arr
-- Copyright : (c) The University of Glasgow, 1994-2000
-- License : see libraries/base/LICENSE
--
-- Maintainer : cvs-ghc@haskell.org
-- Stability : internal
-- Portability : non-portable (GHC extensions)
--
-- GHC's array implementation.
--
-----------------------------------------------------------------------------
module GHC.Arr where
......
% -----------------------------------------------------------------------------
% $Id: Base.lhs,v 1.8 2002/04/24 16:10:21 simonmar Exp $
%
% (c) The University of Glasgow, 1992-2002
%
\section[GHC.Base]{Module @GHC.Base@}
The overall structure of the GHC Prelude is a bit tricky.
a) We want to avoid "orphan modules", i.e. ones with instance
......@@ -71,9 +65,21 @@ GHC.ByteArr Types: ByteArray, MutableByteArray
Other Prelude modules are much easier with fewer complex dependencies.
\begin{code}
{-# OPTIONS -fno-implicit-prelude #-}
-----------------------------------------------------------------------------
-- |
-- Module : GHC.Base
-- Copyright : (c) The University of Glasgow, 1992-2002
-- License : see libraries/base/LICENSE
--
-- Maintainer : cvs-ghc@haskell.org
-- Stability : internal
-- Portability : non-portable (GHC extensions)
--
-- Basic data types and classes.
--
-----------------------------------------------------------------------------
#include "MachDeps.h"
......
% -----------------------------------------------------------------------------
% $Id: Conc.lhs,v 1.4 2002/04/10 11:43:49 stolz Exp $
%
% (c) The University of Glasgow, 1994-2000
%
\section[GHC.Conc]{Module @GHC.Conc@}
Basic concurrency stuff
\begin{code}
{-# OPTIONS -fno-implicit-prelude #-}
-----------------------------------------------------------------------------
-- |
-- Module : GHC.Conc
-- Copyright : (c) The University of Glasgow, 1994-2002
-- License : see libraries/base/LICENSE
--
-- Maintainer : cvs-ghc@haskell.org
-- Stability : internal
-- Portability : non-portable (GHC extensions)
--
-- Basic concurrency stuff.
--
-----------------------------------------------------------------------------
module GHC.Conc
( ThreadId(..)
......
% -----------------------------------------------------------------------------
% $Id: Enum.lhs,v 1.7 2002/02/05 17:32:26 simonmar Exp $
%
% (c) The University of Glasgow, 1992-2000
%
\section[GHC.Bounded]{Module @GHC.Bounded@}
Instances of Bounded for various datatypes.
\begin{code}
{-# OPTIONS -fno-implicit-prelude #-}
-----------------------------------------------------------------------------
-- |
-- Module : GHC.Enum
-- Copyright : (c) The University of Glasgow, 1992-2002
-- License : see libraries/base/LICENSE
--
-- Maintainer : cvs-ghc@haskell.org
-- Stability : internal
-- Portability : non-portable (GHC extensions)
--
-- The 'Enum' and 'Bounded' classes.
--
-----------------------------------------------------------------------------
module GHC.Enum(
Bounded(..), Enum(..),
boundedEnumFrom, boundedEnumFromThen,
-- Instances for Bounded and Eum: (), Char, Int
-- Instances for Bounded and Enum: (), Char, Int
) where
......
% -----------------------------------------------------------------------------
% $Id: Err.lhs,v 1.4 2002/04/11 12:03:43 simonpj Exp $
%
% (c) The University of Glasgow, 1994-2000
%
\section[GHC.Err]{Module @GHC.Err@}
The GHC.Err module defines the code for the wired-in error functions,
which have a special type in the compiler (with "open tyvars").
We cannot define these functions in a module where they might be used
(e.g., GHC.Base), because the magical wired-in type will get confused
with what the typechecker figures out.
\begin{code}
{-# OPTIONS -fno-implicit-prelude #-}
-----------------------------------------------------------------------------
-- |
-- Module : GHC.Err
-- Copyright : (c) The University of Glasgow, 1994-2002
-- License : see libraries/base/LICENSE
--
-- Maintainer : cvs-ghc@haskell.org
-- Stability : internal
-- Portability : non-portable (GHC extensions)
--
-- The "GHC.Err" module defines the code for the wired-in error functions,
-- which have a special type in the compiler (with \"open tyvars\").
--
-- We cannot define these functions in a module where they might be used
-- (e.g., "GHC.Base"), because the magical wired-in type will get confused
-- with what the typechecker figures out.
--
-----------------------------------------------------------------------------
module GHC.Err
(
irrefutPatError
......
% ------------------------------------------------------------------------------
% $Id: Exception.lhs,v 1.3 2002/02/05 17:32:26 simonmar Exp $
%
% (c) The University of Glasgow, 1998-2000
%
Exceptions and exception-handling functions.
\begin{code}
{-# OPTIONS -fno-implicit-prelude #-}
-----------------------------------------------------------------------------
-- |
-- Module : GHC.Exception
-- Copyright : (c) The University of Glasgow, 1998-2002
-- License : see libraries/base/LICENSE
--
-- Maintainer : cvs-ghc@haskell.org
-- Stability : internal
-- Portability : non-portable (GHC extensions)
--
-- Exceptions and exception-handling functions.
--
-----------------------------------------------------------------------------
#ifndef __HUGS__
module GHC.Exception
......
-----------------------------------------------------------------------------
-- |
-- Module : GHC.Exts
-- Copyright : (c) The University of Glasgow 2001
-- License : BSD-style (see the file libraries/core/LICENSE)
-- Copyright : (c) The University of Glasgow 2002
-- License : see libraries/base/LICENSE
--
-- Maintainer : libraries@haskell.org
-- Stability : experimental
-- Portability : non-portable
--
-- $Id: Exts.hs,v 1.5 2002/04/24 16:31:45 simonmar Exp $
-- Maintainer : cvs-ghc@haskell.org
-- Stability : internal
-- Portability : non-portable (GHC Extensions)
--
-- GHC Extensions: this is the Approved Way to get at GHC-specific stuff.
--
......
% ------------------------------------------------------------------------------
% $Id: Float.lhs,v 1.5 2002/02/27 14:33:09 simonmar Exp $
%
% (c) The University of Glasgow, 1994-2000
%
\section[GHC.Num]{Module @GHC.Num@}
The types
Float
Double
and the classes
Floating
RealFloat
\begin{code}
{-# OPTIONS -fno-implicit-prelude #-}
-----------------------------------------------------------------------------
-- |
-- Module : GHC.Float
-- Copyright : (c) The University of Glasgow 1994-2002
-- License : see libraries/base/LICENSE
--
-- Maintainer : cvs-ghc@haskell.org
-- Stability : internal
-- Portability : non-portable (GHC Extensions)
--
-- The types 'Float' and 'Double', and the classes 'Floating' and 'RealFloat'.
--
-----------------------------------------------------------------------------
#include "ieee-flpt.h"
......
......@@ -3,12 +3,19 @@
#undef DEBUG_DUMP
#undef DEBUG
-- -----------------------------------------------------------------------------
-- $Id: Handle.hs,v 1.6 2002/03/26 17:06:32 simonmar Exp $
-----------------------------------------------------------------------------
-- |
-- Module : GHC.Handle
-- Copyright : (c) The University of Glasgow, 1994-2001
-- License : see libraries/base/LICENSE
--
-- Maintainer : libraries@haskell.org
-- Stability : internal
-- Portability : non-portable
--
-- (c) The University of Glasgow, 1994-2001
-- This module defines the basic operations on I\/O \"handles\".
--
-- This module defines the basic operations on I/O "handles".
-----------------------------------------------------------------------------
module GHC.Handle (
withHandle, withHandle', withHandle_,
......
......@@ -2,11 +2,19 @@
#undef DEBUG_DUMP
-- -----------------------------------------------------------------------------
-- $Id: IO.hs,v 1.6 2002/03/18 14:03:20 simonmar Exp $
-----------------------------------------------------------------------------
-- |
-- Module : GHC.IO
-- Copyright : (c) The University of Glasgow, 1992-2001
-- License : see libraries/base/LICENSE
--
-- Maintainer : libraries@haskell.org
-- Stability : internal
-- Portability : non-portable
--
-- (c) The University of Glasgow, 1992-2001
-- String I\/O functions
--
-----------------------------------------------------------------------------
module GHC.IO (
hWaitForInput, hGetChar, hGetLine, hGetContents, hPutChar, hPutStr,
......
% ------------------------------------------------------------------------------
% $Id: IOBase.lhs,v 1.8 2002/04/11 12:03:44 simonpj Exp $
%
% (c) The University of Glasgow, 1994-2001
%
% Definitions for the @IO@ monad and its friends. Everything is exported
% concretely; the @IO@ module itself exports abstractly.
\begin{code}
{-# OPTIONS -fno-implicit-prelude #-}
-----------------------------------------------------------------------------
-- |
-- Module : GHC.IOBase
-- Copyright : (c) The University of Glasgow 1994-2002
-- License : see libraries/base/LICENSE
--
-- Maintainer : cvs-ghc@haskell.org
-- Stability : internal
-- Portability : non-portable (GHC Extensions)
--
-- Definitions for the 'IO' monad and its friends.
--
-----------------------------------------------------------------------------
module GHC.IOBase where
......
%
% (c) The University of Glasgow, 1997-2001
%
\section[GHC.Int]{Module @GHC.Int@}
\begin{code}
{-# OPTIONS -fno-implicit-prelude #-}
-----------------------------------------------------------------------------
-- |
-- Module : GHC.Int
-- Copyright : (c) The University of Glasgow 1997-2002
-- License : see libraries/base/LICENSE
--
-- Maintainer : cvs-ghc@haskell.org
-- Stability : internal
-- Portability : non-portable (GHC Extensions)
--
-- The sized integral datatypes, 'Int8', 'Int16', 'Int32', and 'Int64'.
--
-----------------------------------------------------------------------------
#include "MachDeps.h"
......@@ -780,4 +787,3 @@ instance Ix Int64 where
unsafeIndex b@(m,_) i = fromIntegral (i - m)
inRange (m,n) i = m <= i && i <= n
unsafeRangeSize b@(_l,h) = unsafeIndex b h + 1
\end{code}
% ------------------------------------------------------------------------------
% $Id: List.lhs,v 1.6 2002/02/05 17:32:26 simonmar Exp $
%
% (c) The University of Glasgow, 1994-2000
%
\section[GHC.List]{Module @GHC.List@}
The List data type and its operations
\begin{code}
{-# OPTIONS -fno-implicit-prelude #-}
-----------------------------------------------------------------------------
-- |
-- Module : GHC.List
-- Copyright : (c) The University of Glasgow 1994-2002
-- License : see libraries/base/LICENSE
--
-- Maintainer : cvs-ghc@haskell.org
-- Stability : internal
-- Portability : non-portable (GHC Extensions)
--
-- The List data type and its operations
--
-----------------------------------------------------------------------------
module GHC.List (
[] (..),
......
% ------------------------------------------------------------------------------
% $Id: Num.lhs,v 1.4 2002/02/05 17:32:26 simonmar Exp $
%
% (c) The University of Glasgow, 1994-2000
%
\section[GHC.Num]{Module @GHC.Num@}
The class
Num
and the type
Integer
\begin{code}
{-# OPTIONS -fno-implicit-prelude #-}
-----------------------------------------------------------------------------
-- |
-- Module : GHC.Num
-- Copyright : (c) The University of Glasgow 1994-2002
-- License : see libraries/base/LICENSE
--
-- Maintainer : cvs-ghc@haskell.org
-- Stability : internal
-- Portability : non-portable (GHC Extensions)
--
-- The 'Num' class and the 'Integer' type.
--
-----------------------------------------------------------------------------
#include "MachDeps.h"
#if SIZEOF_HSWORD == 4
......
{-# OPTIONS -fparr #-}
-- $Id: PArr.hs,v 1.2 2002/02/12 10:50:37 simonmar Exp $
--
-- Copyright (c) [2001..2002] Manuel M T Chakravarty & Gabriele Keller
-----------------------------------------------------------------------------
-- |
-- Module : GHC.PArr
-- Copyright : (c) 2001-2002 Manuel M T Chakravarty & Gabriele Keller
-- License : see libraries/base/LICENSE
--
-- Maintainer : Manuel M. T. Chakravarty <chak@cse.unsw.edu.au>
-- Stability : internal
-- Portability : non-portable (GHC Extensions)
--
-- Basic implementation of Parallel Arrays.
--
--- DESCRIPTION ---------------------------------------------------------------
--
-- This module has two functions: (1) It defines the interface to the
-- parallel array extension of the Prelude and (2) it provides a vanilla
-- implementation of parallel arrays that does not require to flatten the
......
% ------------------------------------------------------------------------------
% $Id: Pack.lhs,v 1.2 2001/09/14 11:25:24 simonmar Exp $
%
% (c) The University of Glasgow, 1997-2000
%
\section[GHC.Pack]{Packing/unpacking bytes}
This module provides a small set of low-level functions for packing
and unpacking a chunk of bytes. Used by code emitted by the compiler
plus the prelude libraries.
The programmer level view of packed strings is provided by a GHC
system library PackedString.
\begin{code}
{-# OPTIONS -fno-implicit-prelude #-}
-----------------------------------------------------------------------------
-- |
-- Module : GHC.Pack
-- Copyright : (c) The University of Glasgow 1997-2002
-- License : see libraries/base/LICENSE
--
-- Maintainer : cvs-ghc@haskell.org
-- Stability : internal
-- Portability : non-portable (GHC Extensions)
--
-- This module provides a small set of low-level functions for packing
-- and unpacking a chunk of bytes. Used by code emitted by the compiler
-- plus the prelude libraries.
--
-- The programmer level view of packed strings is provided by a GHC
-- system library PackedString.
--
-----------------------------------------------------------------------------
module GHC.Pack
(
......
{-# OPTIONS -fno-implicit-prelude #-}
-- ---------------------------------------------------------------------------
-- $Id: Posix.hs,v 1.6 2002/03/26 10:53:03 simonmar Exp $
-----------------------------------------------------------------------------
-- |
-- Module : GHC.Posix
-- Copyright : (c) The University of Glasgow, 1992-2002
-- License : see libraries/base/LICENSE
--
-- Maintainer : cvs-ghc@haskell.org
-- Stability : internal
-- Portability : non-portable
--
-- POSIX support layer for the standard libraries
--
-- Non-posix compliant in order to support the following features:
-- * S_ISSOCK (no sockets in POSIX)
--
-----------------------------------------------------------------------------
module GHC.Posix where
......
\begin{code}
{-# OPTIONS -fno-implicit-prelude #-}
-----------------------------------------------------------------------------
-- $Id: Ptr.lhs,v 1.3 2002/04/24 16:31:45 simonmar Exp $
--
-- (c) The FFI Task Force, 2000
-- |
-- Module GHC.Ptr
-- Module : GHC.Ptr
-- Copyright : (c) The FFI Task Force, 2000-2002
-- License : see libraries/base/LICENSE
--
-- Maintainer : ffi@haskell.org
-- Stability : internal
-- Portability : non-portable (GHC Extensions)
--
-- The 'Ptr' and 'FunPtr' types and operations.
--
-----------------------------------------------------------------------------
\begin{code}
{-# OPTIONS -fno-implicit-prelude #-}
module GHC.Ptr where
import GHC.Base
......
% ------------------------------------------------------------------------------
% $Id: Read.lhs,v 1.6 2002/04/13 14:59:06 panne Exp $
%
% (c) The University of Glasgow, 1994-2000
%
\section[GHC.Read]{Module @GHC.Read@}
Instances of the Read class.
\begin{code}
{-# OPTIONS -fno-implicit-prelude #-}
-----------------------------------------------------------------------------
-- |
-- Module : GHC.Read
-- Copyright : (c) The FFI Task Force, 1994-2002
-- License : see libraries/base/LICENSE
--
-- Maintainer : cvs-ghc@haskell.org
-- Stability : internal
-- Portability : non-portable (GHC Extensions)
--
-- The 'Read' class and instances for basic data types.
--
-----------------------------------------------------------------------------
module GHC.Read
( Read(..) -- class
......
% ------------------------------------------------------------------------------
% $Id: Real.lhs,v 1.3 2002/02/12 15:51:26 simonmar Exp $
%
% (c) The University of Glasgow, 1994-2000
%
\section[GHC.Real]{Module @GHC.Real@}
The types
Ratio, Rational
and the classes
Real
Integral
Fractional
RealFrac
\begin{code}
{-# OPTIONS -fno-implicit-prelude #-}
-----------------------------------------------------------------------------
-- |
-- Module : GHC.Real
-- Copyright : (c) The FFI Task Force, 1994-2002
-- License : see libraries/base/LICENSE
--
-- Maintainer : cvs-ghc@haskell.org
-- Stability : internal
-- Portability : non-portable (GHC Extensions)
--
-- The types 'Ratio' and 'Rational', and the classes 'Real', 'Fractional',
-- 'Integral', and 'RealFrac'.
--
-----------------------------------------------------------------------------
module GHC.Real where
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment