Skip to content

Instantly share code, notes, and snippets.

@gvolpe
Created October 5, 2021 19:09
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save gvolpe/eb85cb0a2632e9ec179ce3bd80a73cee to your computer and use it in GitHub Desktop.
Save gvolpe/eb85cb0a2632e9ec179ce3bd80a73cee to your computer and use it in GitHub Desktop.
import cats.Show
import cats.derived.semiauto.*
import cats.syntax.all.*
final case class User(name: String, age: Int) derives Show
object Demo:
@main def run =
println(User("Joe", 18).show) // outputs: User(name=Joe, age=18)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment