From 48c845476cc42825442ada0c1bddd5347283be80 Mon Sep 17 00:00:00 2001 From: Dominik Schrempf <dominik.schrempf@gmail.com> Date: Sat, 8 Jul 2023 17:24:49 +0200 Subject: [PATCH] integer documentation: minor corrections --- libraries/ghc-bignum/src/GHC/Num/Integer.hs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/libraries/ghc-bignum/src/GHC/Num/Integer.hs b/libraries/ghc-bignum/src/GHC/Num/Integer.hs index 9e651f02bc76..761468e89f63 100644 --- a/libraries/ghc-bignum/src/GHC/Num/Integer.hs +++ b/libraries/ghc-bignum/src/GHC/Num/Integer.hs @@ -167,11 +167,11 @@ default () -- Integers are stored in a kind of sign-magnitude form, hence do not expect -- two's complement form when using bit operations. -- --- If the value is small (fit into an 'Int'), 'IS' constructor is used. --- Otherwise 'IP' and 'IN' constructors are used to store a 'BigNat' --- representing respectively the positive or the negative value magnitude. +-- If the value is small (i.e., fits into an 'Int'), the 'IS' constructor is +-- used. Otherwise 'IP' and 'IN' constructors are used to store a 'BigNat' +-- representing the positive or the negative value magnitude, respectively. -- --- Invariant: 'IP' and 'IN' are used iff value doesn't fit in 'IS' +-- Invariant: 'IP' and 'IN' are used iff the value does not fit in 'IS'. data Integer = IS !Int# -- ^ iff value in @[minBound::'Int', maxBound::'Int']@ range | IP !BigNat# -- ^ iff value in @]maxBound::'Int', +inf[@ range -- GitLab