diff options
author | Simon Peyton Jones <simonpj@microsoft.com> | 2021-11-19 18:34:11 +0000 |
---|---|---|
committer | Marge Bot <ben+marge-bot@smart-cactus.org> | 2021-11-22 11:53:02 -0500 |
commit | f0bac29baea62e7e1cd1a2659107cc7c029c9165 (patch) | |
tree | 30ddad5e022910bcc8140ed0b4b953b9eda90a37 /libraries/base/GHC/Arr.hs | |
parent | f748988bbea1442b898ba107653216543a293b4d (diff) | |
download | haskell-f0bac29baea62e7e1cd1a2659107cc7c029c9165.tar.gz |
Make INLINE/NOINLINE pragmas a bgi less constraining
We can inline a bit earlier than the previous pragmas said. I think
they dated from an era in which the InitialPhase did no inlining.
I don't think this patch will have much effect, but it's
a bit cleaner.
Diffstat (limited to 'libraries/base/GHC/Arr.hs')
-rw-r--r-- | libraries/base/GHC/Arr.hs | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/libraries/base/GHC/Arr.hs b/libraries/base/GHC/Arr.hs index 06951d3851..63d79237c5 100644 --- a/libraries/base/GHC/Arr.hs +++ b/libraries/base/GHC/Arr.hs @@ -497,7 +497,8 @@ eqArray arr1@(Array l1 u1 n1 _) arr2@(Array l2 u2 n2 _) = l1 == l2 && u1 == u2 && and [unsafeAt arr1 i == unsafeAt arr2 i | i <- [0 .. n1 - 1]] -{-# INLINE [1] cmpArray #-} +{-# INLINE [2] cmpArray #-} +-- See Note [Allow time for type-specialisation rules to fire] in GHC.Real cmpArray :: (Ix i, Ord e) => Array i e -> Array i e -> Ordering cmpArray arr1 arr2 = compare (assocs arr1) (assocs arr2) |