Difference between Haskell and Idris: Reflection of Runtime/Compiletime in the type universes

Yes, you’re right to observe that the types versus values distinction in Idris does not align with the compiletime-only versus runtime-and-compiletime distinction. That’s a good thing. It is useful to have values which exist only at compiletime, just as in program logics we have “ghost variables” used only in specifications. It is useful also to … Read more

Datatype promotion for dependently challenged

There are at least two examples in the paper itself: “1. Introduction” says: “for example, we might be able to ensure [at compile time] that an alleged red-black tree really has the red-black property”. “2.1 Promoting datatypes” discusses length-indexed vectors (that is, vectors with compile-time “index out of bounds” errors). You can also take a … Read more

What is Haskell missing for totality checking?

Liquid Haskell has totality checking: https://github.com/ucsd-progsys/liquidhaskell#termination-check By default a termination check is performed on all recursive functions. Use the no-termination option to disable the check liquid –no-termination test.hs In recursive functions the first algebraic or integer argument should be decreasing. The default decreasing measure for lists is length and Integers its value. (I included screenshot … Read more

Why do we need containers?

To my mind, the value of containers (as in container theory) is their uniformity. That uniformity gives considerable scope to use container representations as the basis for executable specifications, and perhaps even machine-assisted program derivation. Containers: a theoretical tool, not a good run-time data representation strategy I would not recommend fixpoints of (normalized) containers as … Read more

Practical examples of Idris

Edwin Brady has a repo full of demos at https://github.com/edwinb/idris-demos. Among other things, it has a playable space invaders game, written using SDL bindings, Effects, and the !-effect syntax (basically an alternate syntax to do-notation / >>=). Also, we attempt to maintain a listing of some available libraries on the wiki: https://github.com/idris-lang/Idris-dev/wiki/Libraries

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)