@@ -875,7 +875,7 @@ primFn :: T.Type -> ([CppType], Maybe CppType)
875primFn = go []
875primFn = go []
877 go ps (T.TypeApp (T.TypeApp fn a) b) | fn == E.tyFunction,
877 go ps (T.TypeApp (T.TypeApp fn a) b) | fn == E.tyFunction,
878− Just a' <- numType a = go (a' : ps) b
878+ Just a' <- numType a = go (ps ++ [a']) b
879 go ps t | Just t' <- numType t = (ps , Just t')
879 go ps t | Just t' <- numType t = (ps , Just t')
880 go _ _ = ([], Nothing)
880 go _ _ = ([], Nothing)
881 numType t@(T.TypeConstructor {}) | t == E.tyInt = Just intType
881 numType t@(T.TypeConstructor {}) | t == E.tyInt = Just intType