Hacker News new | past | comments | ask | show | jobs | submit login

Every type is inhabited in most type systems for general-purpose programming languages. For example, to inhabit a type T in Haskell syntax (the same approach works in basically any language):

    f :: () -> T
    f x = f x
    
    myT = f ()
What this shows is that Haskell types are not sound as a logic, but that doesn't mean they aren't a fine type system.



Consider applying for YC's Summer 2025 batch! Applications are open till May 13

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: