4 ms·
Haskell has exceptions. So does Rust. People just prefer to use Either / Result (with good reason).
by Jweb_Guru 10y ago
Haskell has exceptions. So does Rust. People just prefer to use Either / Result (with good reason).
- soulbadguy 10y agoException in Haskell ?
- Jweb_Guru 10y agoYeah. Try grabbing the head of an empty list, for instance. People for the most part don't like exceptions in Haskell, but that's not the same as the language not having them.
- dbaupp 10y agoThe `error` function is approximately `throw`. Catchable with: https://hackage.haskell.org/package/base-4.9.1.0/docs/Control-Exception.html#g:5 https://hackage.haskell.org/package/base-4.9.1.0/docs/Contro...