@@ -305,7 +305,7 @@ mismatchToReport localizer (MismatchInfo hint leftType rightType maybeReason) =
305305 ( cmpHint
306306 (Help.capitalize (funcName maybeName) ++ " is expecting the argument to be:")
307307 "But it is:"
308− []
308+ (functionHint maybeName)
309309 )
310310
311311 UnexpectedArg maybeName index _totalArgs region ->
@@ -319,7 +319,9 @@ mismatchToReport localizer (MismatchInfo hint leftType rightType maybeReason) =
319319 ++ Help.ordinalize index ++ " argument to be:"
320320 )
321321 "But it is:"
322− ( if index == 1 then
322+ ( functionHint maybeName
323+ ++
324+ if index == 1 then
323325 []
324326 else
325327 [ "I always figure out the type of arguments from left to right. If an argument\
@@ -515,6 +517,7 @@ comparisonHint localizer leftType rightType leftWords rightWords finalHints =
515517
516518-- BINOP HINTS
517519
520+
518521binopHint :: Var.Canonical -> Type.Canonical -> Type.Canonical -> [String]
519522binopHint op leftType rightType =
520523 let
@@ -540,6 +543,25 @@ binopHint op leftType rightType =
540543
541544
542545
546+-- FUNCTION HINTS
547+
548+
549+functionHint :: Maybe Var.Canonical -> [String]
550+functionHint maybeName =
551+ case maybeName of
552+ Nothing ->
553+ []
554+
555+ Just name ->
556+ if Var.inHtml ["Html","App"] "program" == name then
557+ [ "Does your program have flags? Maybe you want `programWithFlags` instead."
558+ ]
559+
560+ else
561+ []
562+
563+
564+
543565-- MISMATCH HELPERS
544566
545567