fix types indexes in some cases

This commit is contained in:
Ilya Rezvov
2018-02-25 09:19:54 -08:00
parent 1366c63bf3
commit c7ecb055d4
+1 -1
View File
@@ -1313,7 +1313,7 @@ desugarize fields =
extract extractor = reverse . foldl' extractor []
findWithIndex :: (a -> Bool) -> [a] -> Maybe (a, Int)
findWithIndex pred l = find (pred . fst) $ zip l [1..]
findWithIndex pred l = find (pred . fst) $ zip l [0..]
-- types
synTypeDefToStruct :: TypeDef -> S.FuncType