TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

Interesting languages and their selling points

6 pointsby overlistedalmost 3 years ago

1 comment

Laaasalmost 3 years ago
One thing the author fails to mention, is that monads can&#x27;t _annotate_ the terms. They can not replace effects in the type system, since something `putStrLn` doesn&#x27;t _cause_ an effect, it _returns_ it. In a strict language, even if you have something like `putStrLn :: String -&gt; IO ()`, you can not do `let _ = putStrLn &quot;d&quot; in x` and have it not print it, unless `IO` wraps the computation in a lambda, which is quite suboptimal.<p>Hence, monads are not a replacement for effects, even if people are making things like <a href="https:&#x2F;&#x2F;github.com&#x2F;haskell-effectful&#x2F;effectful&#x2F;" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;haskell-effectful&#x2F;effectful&#x2F;</a>.