Draft! This page is a draft - a work in progress!

Scala cheatsheet Subscribe Pub


sealed trait Color // exhaustiveness checking from compiler on case/match
final case object Red extends Color
final case object Green extends Color

Was this useful?    

By: Razie | 2017-06-02 | Tags: post

See more in: Cool Scala Subscribe

Viewed 520 times ( | Print ) this page.

You need to log in to post a comment!