@@ -453,7 +453,11 @@ unifyAtom context name otherContent =
453453 merge context otherContent
454454
455455 else
456− mismatch context Nothing
456+ mismatch context $
457+ if isIntFloat name otherName || isIntFloat otherName name then
458+ Just Error.IntFloat
459+ else
460+ Nothing
457461
458462 Alias _ _ realVar ->
459463 subUnify context (_first context) realVar
@@ -462,9 +466,14 @@ unifyAtom context name otherContent =
462466 mismatch context Nothing
463467
464468
469+isIntFloat :: Var.Canonical -> Var.Canonical -> Bool
470+isIntFloat name otherName =
471+ Var.isPrim "Int" name && Var.isPrim "Float" otherName
472+
465473
466474-- UNIFY ALIASES
467475
476+
468477unifyAlias :: Context -> Var.Canonical -> [(String, Variable)] -> Variable -> Content -> Unify ()
469478unifyAlias context name args realVar otherContent =
470479 case otherContent of