@@ -358,10 +358,10 @@ moduleToCpp otherOpts env (Module _ mn imps _ foreigns decls) = do
358358 valueToCpp (Var (_, _, _, Just IsNewtype) ident) = return $ varToCpp ident
359359 valueToCpp (Var (_, _, _, Just (IsConstructor _ [])) ident) = return $ CppApp (varToCpp ident) []
360360 valueToCpp (Var (_, _, Just ty, _) ident@(Qualified (Just _) _))
361− | arity ty > 0 = return . curriedName' $ varToCpp ident
361+ | arity ty > 0 = return . curriedVar $ varToCpp ident
362362 valueToCpp (Var (_, _, Nothing, _) ident@(Qualified (Just _) _))
363363 | Just (ty, _, _) <- M.lookup ident (E.names env)
364− , arity ty > 0 = return . curriedName' $ varToCpp ident
364+ , arity ty > 0 = return . curriedVar $ varToCpp ident
365365 valueToCpp (Var _ ident) = return $ varToCpp ident
366366 valueToCpp (Literal _ (NumericLiteral n)) = return (CppNumericLiteral n)
367367 valueToCpp (Literal _ (StringLiteral s)) = return (CppStringLiteral s)
@@ -410,7 +410,7 @@ moduleToCpp otherOpts env (Module _ mn imps _ foreigns decls) = do
410410 zip
411411 (CppSymbol . mkString <$> (sort $ superClassDictionaryNames constraints) ++ (fst <$> fns))
412412 args'
413− Var _ (Qualified (Just _) _) -> applied f args' curriedName'
413+ Var _ (Qualified (Just _) _) -> applied f args' curriedVar
414414 _ -> applied f args' id
415415 where
416416 applied f args g = flip (foldl (\fn a -> CppApp (g fn) [a])) args <$> valueToCpp f
@@ -745,20 +745,11 @@ optIndexers classes = everywhereOnCpp dictIndexerToEnum
745745 dictIndexerToEnum cpp = cpp
746746
747747---------------------------------------------------------------------------------------------------
748−curriedName :: Text -> Text
748+curriedVar :: Cpp -> Cpp
749749---------------------------------------------------------------------------------------------------
750−curriedName name
751− | Text.null name = name
752−curriedName name
753− | Text.head name == '*' = name
754− | otherwise = '*' `Text.cons` name
755−
756−---------------------------------------------------------------------------------------------------
757−curriedName' :: Cpp -> Cpp
758−---------------------------------------------------------------------------------------------------
759−curriedName' (CppVar name) = CppVar (curriedName name)
760−curriedName' (CppAccessor a b) = CppAccessor (curriedName' a) b
761−curriedName' cpp = cpp
750+curriedVar (CppVar name) = CppVar (curriedName name)
751+curriedVar (CppAccessor a b) = CppAccessor (curriedVar a) b
752+curriedVar cpp = cpp
762753
763754---------------------------------------------------------------------------------------------------
764755primFn :: T.Type -> ([CppType], Maybe CppType)