From c4b131133e4cee35d2140eedfcf3b4e573a43a8a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?H=C3=A9cate=20Moonlight?= <hecate@glitchbra.in> Date: Tue, 5 Mar 2024 15:23:09 +0100 Subject: [PATCH] Use "module" instead of "library" when applicable in base haddocks --- libraries/base/src/Control/Concurrent.hs | 6 +++--- libraries/base/src/Control/Monad.hs | 2 +- libraries/base/src/Control/Monad/ST.hs | 2 +- libraries/base/src/Control/Monad/ST/Safe.hs | 2 +- libraries/base/src/Control/Monad/ST/Unsafe.hs | 2 +- libraries/base/src/Data/Version.hs | 2 +- libraries/base/src/GHC/IO/Encoding/UTF16.hs | 2 +- libraries/base/src/GHC/TypeNats.hs | 2 +- libraries/base/src/System/Console/GetOpt.hs | 2 +- libraries/base/src/System/IO.hs | 2 +- libraries/base/src/System/Mem/Weak.hs | 4 ++-- libraries/base/src/System/Posix/Internals.hs | 2 +- libraries/base/src/Text/ParserCombinators/ReadP.hs | 4 ++-- libraries/base/src/Text/ParserCombinators/ReadPrec.hs | 4 ++-- libraries/base/src/Text/Read.hs | 2 +- 15 files changed, 20 insertions(+), 20 deletions(-) diff --git a/libraries/base/src/Control/Concurrent.hs b/libraries/base/src/Control/Concurrent.hs index f6a58e70238f..ac4b53fc847b 100644 --- a/libraries/base/src/Control/Concurrent.hs +++ b/libraries/base/src/Control/Concurrent.hs @@ -147,7 +147,7 @@ by using 'forkOS' instead of 'forkIO'. Haskell threads can communicate via 'MVar's, a kind of synchronised mutable variable (see "Control.Concurrent.MVar"). Several common concurrency abstractions can be built from 'MVar's, and these are -provided by the "Control.Concurrent" library. +provided by the "Control.Concurrent" module. In GHC, threads may also communicate via exceptions. -} @@ -384,7 +384,7 @@ foreign import ccall safe "fdReady" multiple Haskell threads can be involved in external calls simultaneously. - The "System.IO" library manages multiplexing in its own way. On + The "System.IO" module manages multiplexing in its own way. On Windows systems it uses @safe@ foreign calls to ensure that threads doing I\/O operations don't block the whole runtime, whereas on Unix systems all the currently blocked I\/O requests @@ -401,7 +401,7 @@ foreign import ccall safe "fdReady" If you don't use the @-threaded@ option, then the runtime does not make use of multiple OS threads. Foreign calls will block all other running Haskell threads until the call returns. The - "System.IO" library still does multiplexing, so there can be multiple + "System.IO" module still does multiplexing, so there can be multiple threads doing I\/O, and this is handled internally by the runtime using @select@. -} diff --git a/libraries/base/src/Control/Monad.hs b/libraries/base/src/Control/Monad.hs index 6e2bd72db8cf..a5a0e1c6057f 100644 --- a/libraries/base/src/Control/Monad.hs +++ b/libraries/base/src/Control/Monad.hs @@ -65,7 +65,7 @@ import GHC.Internal.Control.Monad {- $naming -The functions in this library use the following naming conventions: +The functions in this module use the following naming conventions: * A postfix \'@M@\' always stands for a function in the Kleisli category: The monad type constructor @m@ is added to function results diff --git a/libraries/base/src/Control/Monad/ST.hs b/libraries/base/src/Control/Monad/ST.hs index 33fb34d9986e..fee7f7e91c91 100644 --- a/libraries/base/src/Control/Monad/ST.hs +++ b/libraries/base/src/Control/Monad/ST.hs @@ -10,7 +10,7 @@ -- Stability : stable -- Portability : non-portable (requires universal quantification for runST) -- --- This library provides support for /strict/ state threads, as +-- This module provides support for /strict/ state threads, as -- described in the PLDI \'94 paper by John Launchbury and Simon Peyton -- Jones /Lazy Functional State Threads/. -- diff --git a/libraries/base/src/Control/Monad/ST/Safe.hs b/libraries/base/src/Control/Monad/ST/Safe.hs index fedc7244ce31..2d10f97ab843 100644 --- a/libraries/base/src/Control/Monad/ST/Safe.hs +++ b/libraries/base/src/Control/Monad/ST/Safe.hs @@ -10,7 +10,7 @@ -- Stability : stable -- Portability : non-portable (requires universal quantification for runST) -- --- This library provides support for /strict/ state threads, as +-- This module provides support for /strict/ state threads, as -- described in the PLDI \'94 paper by John Launchbury and Simon Peyton -- Jones /Lazy Functional State Threads/. -- diff --git a/libraries/base/src/Control/Monad/ST/Unsafe.hs b/libraries/base/src/Control/Monad/ST/Unsafe.hs index 398944aba517..d04caedf8379 100644 --- a/libraries/base/src/Control/Monad/ST/Unsafe.hs +++ b/libraries/base/src/Control/Monad/ST/Unsafe.hs @@ -10,7 +10,7 @@ -- Stability : stable -- Portability : non-portable (requires universal quantification for runST) -- --- This library provides support for /strict/ state threads, as +-- This module provides support for /strict/ state threads, as -- described in the PLDI \'94 paper by John Launchbury and Simon Peyton -- Jones /Lazy Functional State Threads/. -- diff --git a/libraries/base/src/Data/Version.hs b/libraries/base/src/Data/Version.hs index f251984f07e5..581005a9fe5d 100644 --- a/libraries/base/src/Data/Version.hs +++ b/libraries/base/src/Data/Version.hs @@ -9,7 +9,7 @@ -- Stability : stable -- Portability : non-portable (local universal quantification in ReadP) -- --- A general library for representation and manipulation of versions. +-- A general API for representation and manipulation of versions. -- -- Versioning schemes are many and varied, so the version -- representation provided by this library is intended to be a diff --git a/libraries/base/src/GHC/IO/Encoding/UTF16.hs b/libraries/base/src/GHC/IO/Encoding/UTF16.hs index 2f0eddd78a0b..c7c65dff6a4d 100644 --- a/libraries/base/src/GHC/IO/Encoding/UTF16.hs +++ b/libraries/base/src/GHC/IO/Encoding/UTF16.hs @@ -32,4 +32,4 @@ module GHC.IO.Encoding.UTF16 utf16le_encode ) where -import GHC.Internal.IO.Encoding.UTF16 \ No newline at end of file +import GHC.Internal.IO.Encoding.UTF16 diff --git a/libraries/base/src/GHC/TypeNats.hs b/libraries/base/src/GHC/TypeNats.hs index 70da2c443a65..d16d6fc954d7 100644 --- a/libraries/base/src/GHC/TypeNats.hs +++ b/libraries/base/src/GHC/TypeNats.hs @@ -7,7 +7,7 @@ -- | -- This module is an internal GHC module. It declares the constants used -- in the implementation of type-level natural numbers. The programmer interface --- for working with type-level naturals should be defined in a separate library. +-- for working with type-level naturals should be defined in a separate module. -- -- @since 4.10.0.0 -- diff --git a/libraries/base/src/System/Console/GetOpt.hs b/libraries/base/src/System/Console/GetOpt.hs index ee4b634bc084..f633ed3590d8 100644 --- a/libraries/base/src/System/Console/GetOpt.hs +++ b/libraries/base/src/System/Console/GetOpt.hs @@ -10,7 +10,7 @@ -- Stability : stable -- Portability : portable -- --- This library provides facilities for parsing the command-line options +-- This module provides facilities for parsing the command-line options -- in a standalone program. It is essentially a Haskell port of the GNU -- @getopt@ library. -- diff --git a/libraries/base/src/System/IO.hs b/libraries/base/src/System/IO.hs index 3ff460a76443..c4b7d2bbaba4 100644 --- a/libraries/base/src/System/IO.hs +++ b/libraries/base/src/System/IO.hs @@ -10,7 +10,7 @@ -- Stability : stable -- Portability : portable -- --- The standard IO library. +-- The standard IO API. -- module System.IO diff --git a/libraries/base/src/System/Mem/Weak.hs b/libraries/base/src/System/Mem/Weak.hs index 012414ef6ed4..464298b49651 100644 --- a/libraries/base/src/System/Mem/Weak.hs +++ b/libraries/base/src/System/Mem/Weak.hs @@ -32,7 +32,7 @@ -- alive for ever. One way to solve this is to purge the table -- occasionally, by deleting entries whose keys have died. -- --- The weak pointers in this library +-- The weak pointers in this module -- support another approach, called /finalization/. -- When the key referred to by a weak pointer dies, the storage manager -- arranges to run a programmer-specified finalizer. In the case of memo @@ -43,7 +43,7 @@ -- key\/value pair might itself contain a pointer to the key. -- So the memo table keeps the value alive, which keeps the key alive, -- even though there may be no other references to the key so both should --- die. The weak pointers in this library provide a slight +-- die. The weak pointers in this module provide a slight -- generalisation of the basic weak-pointer idea, in which each -- weak pointer actually contains both a key and a value. -- diff --git a/libraries/base/src/System/Posix/Internals.hs b/libraries/base/src/System/Posix/Internals.hs index 9323bcb829e4..a685bfc1dffa 100644 --- a/libraries/base/src/System/Posix/Internals.hs +++ b/libraries/base/src/System/Posix/Internals.hs @@ -17,7 +17,7 @@ -- bound, e.g., @base < 4.X@ rather than @base < 5@, because the interface can -- change rapidly without much warning. -- --- This library is built on *every* platform, including Win32. +-- This module is built on *every* platform, including Win32. -- -- Non-POSIX compliant in order to support the following features: -- * S_ISSOCK (no sockets in POSIX) diff --git a/libraries/base/src/Text/ParserCombinators/ReadP.hs b/libraries/base/src/Text/ParserCombinators/ReadP.hs index 022a6c51523e..a0e1e16eb185 100644 --- a/libraries/base/src/Text/ParserCombinators/ReadP.hs +++ b/libraries/base/src/Text/ParserCombinators/ReadP.hs @@ -10,7 +10,7 @@ -- Stability : provisional -- Portability : non-portable (local universal quantification) -- --- This is a library of parser combinators, originally written by Koen Claessen. +-- This is a module of parser combinators, originally written by Koen Claessen. -- It parses all alternatives in parallel, so it never keeps hold of -- the beginning of the input string, a common source of space leaks with -- other parsers. The @('+++')@ choice combinator is genuinely commutative; @@ -60,4 +60,4 @@ module Text.ParserCombinators.ReadP -- $properties ) where -import GHC.Internal.Text.ParserCombinators.ReadP \ No newline at end of file +import GHC.Internal.Text.ParserCombinators.ReadP diff --git a/libraries/base/src/Text/ParserCombinators/ReadPrec.hs b/libraries/base/src/Text/ParserCombinators/ReadPrec.hs index b75c95b464b9..3abc5c115978 100644 --- a/libraries/base/src/Text/ParserCombinators/ReadPrec.hs +++ b/libraries/base/src/Text/ParserCombinators/ReadPrec.hs @@ -10,7 +10,7 @@ -- Stability : provisional -- Portability : non-portable (uses Text.ParserCombinators.ReadP) -- --- This library defines parser combinators for precedence parsing. +-- This module defines parser combinators for precedence parsing. module Text.ParserCombinators.ReadPrec (ReadPrec, @@ -37,4 +37,4 @@ module Text.ParserCombinators.ReadPrec readS_to_Prec ) where -import GHC.Internal.Text.ParserCombinators.ReadPrec \ No newline at end of file +import GHC.Internal.Text.ParserCombinators.ReadPrec diff --git a/libraries/base/src/Text/Read.hs b/libraries/base/src/Text/Read.hs index 056883d4bce1..9f4f9dccadb0 100644 --- a/libraries/base/src/Text/Read.hs +++ b/libraries/base/src/Text/Read.hs @@ -12,7 +12,7 @@ -- -- Converting strings to values. -- --- The "Text.Read" library is the canonical library to import for +-- The "Text.Read" module is the canonical place to import for -- 'Read'-class facilities. For GHC only, it offers an extended and much -- improved 'Read' class, which constitutes a proposed alternative to the -- Haskell 2010 'Read'. In particular, writing parsers is easier, and -- GitLab