3 ms·
in which of these languages can you have types depending on values ? :=)
by jcelerier 7y ago
in which of these languages can you have types depending on values ? :=)
- pkolaczk 7y agoIn Scala and Idris. Haskell has no direct support, but I believe you can get quite close with rank-2 types. Also, typing is not the end of all the things. Most languages I listed have much stronger metaprogramming capabilities than C++. Scala, Rust, Template Haskell macro systems are superior to C++ templates.