summaryrefslogtreecommitdiff
path: root/compiler/coreSyn
diff options
context:
space:
mode:
authorRichard Eisenberg <eir@cis.upenn.edu>2015-09-19 23:59:22 -0400
committerRichard Eisenberg <eir@cis.upenn.edu>2015-09-21 12:01:59 -0400
commitcd2840a784f4136a8cfdb704124e892430ad9ead (patch)
tree8218de79fad91382faccf2be8b2464ef0fb3a9c5 /compiler/coreSyn
parent8e8b9ed9849ba21e454e6204b368f8e993feaf7b (diff)
downloadhaskell-cd2840a784f4136a8cfdb704124e892430ad9ead.tar.gz
Refactor BranchLists.
Now we use Array to store branches. This makes sense because we often have to do random access (once inference is done). This also vastly simplifies the awkward BranchList type. This fixes #10837 and updates submodule utils/haddock.
Diffstat (limited to 'compiler/coreSyn')
-rw-r--r--compiler/coreSyn/CoreLint.hs2
1 files changed, 1 insertions, 1 deletions
diff --git a/compiler/coreSyn/CoreLint.hs b/compiler/coreSyn/CoreLint.hs
index 2b1118e69b..0b72ff4db2 100644
--- a/compiler/coreSyn/CoreLint.hs
+++ b/compiler/coreSyn/CoreLint.hs
@@ -1336,7 +1336,7 @@ lintCoercion (InstCo co arg_ty)
_ -> failWithL (ptext (sLit "Bad argument of inst")) }
lintCoercion co@(AxiomInstCo con ind cos)
- = do { unless (0 <= ind && ind < brListLength (coAxiomBranches con))
+ = do { unless (0 <= ind && ind < numBranches (coAxiomBranches con))
(bad_ax (ptext (sLit "index out of range")))
-- See Note [Kind instantiation in coercions]
; let CoAxBranch { cab_tvs = ktvs