Skip to content

Instantly share code, notes, and snippets.

@erangaeb
Last active January 31, 2016 11:24
Show Gist options
  • Save erangaeb/2aebb6bfc2a78b13f124 to your computer and use it in GitHub Desktop.
Save erangaeb/2aebb6bfc2a78b13f124 to your computer and use it in GitHub Desktop.
Traits vs Abstract classes scala
// this won't compile
trait Language(name: String)
// Use abstract class when needs to have constrctor arguments
abstract class Language(name: String)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment