Created
January 31, 2023 09:51
-
-
Save gvolpe/088f6d1a1a8071304b6ae2db444d687c to your computer and use it in GitHub Desktop.
The "-Wvalue-discard" flag doesn't seem to work with the `IO` monad
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//> using scala "3.3.0-RC1" | |
//> using lib "org.typelevel::cats-effect:3.4.5" | |
//> using plugin "com.github.ghik:::zerowaste:0.2.3" | |
//> using options "-Wunused:imports" | |
//> using options "-Werror" | |
//> using options "-Wvalue-discard" | |
import cats.effect.* | |
object Main extends IOApp.Simple: | |
def run: IO[Unit] = | |
IO.pure("discarded") | |
IO.println("foo") *> IO.println("bar") |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
As @BalmungSan pointed out here, you're searching for
nonunit-statements