@@ -355,9 +355,6 @@ argsToValue opts multiCons (RecC conName ts) = case (unwrapUnaryRecords opts, no
356 (maybes, rest) = partition isMaybe argCons
356 (maybes, rest) = partition isMaybe argCons
358− isMaybe (_, (_, _, AppT (ConT t) _)) = t == ''Maybe
361 maybeToPair (arg, (field, _, _)) =
358 maybeToPair (arg, (field, _, _)) =
362 infixApp (infixE (Just $ toFieldName field)
359 infixApp (infixE (Just $ toFieldName field)
@@ -408,6 +405,10 @@ argsToValue opts multiCons (InfixC _ conName _) = do
408argsToValue opts multiCons (ForallC _ _ con) =
405argsToValue opts multiCons (ForallC _ _ con) =
409 argsToValue opts multiCons con
406 argsToValue opts multiCons con
408+isMaybe :: (a, (b, c, Type)) -> Bool
409+isMaybe (_, (_, _, AppT (ConT t) _)) = t == ''Maybe
411(<^>) :: ExpQ -> ExpQ -> ExpQ
412(<^>) :: ExpQ -> ExpQ -> ExpQ
412(<^>) a b = infixApp a [|(<>)|] b
413(<^>) a b = infixApp a [|(<>)|] b
413infixr 6 <^>
414infixr 6 <^>
@@ -489,9 +490,6 @@ argsToEncoding opts multiCons (RecC conName ts) = case (unwrapUnaryRecords opts,
490 (maybes, rest) = partition isMaybe argCons
491 (maybes, rest) = partition isMaybe argCons
492− isMaybe (_, (_, _, AppT (ConT t) _)) = t == ''Maybe
495 maybeToPair (arg, (field, _, _)) =
493 maybeToPair (arg, (field, _, _)) =
496 infixApp (infixE (Just $ toFieldName field)
494 infixApp (infixE (Just $ toFieldName field)