Created
October 24, 2017 18:35
-
-
Save thobson/1333ac606075b247027525d956de5fb7 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
trait VehicleLike[A] { | |
def drive(a: A): String | |
} | |
object Vehicles { | |
implicit val vehicleLikeCar = ... | |
implicit val vehicleLikeBus = ... | |
} | |
object Dealership { | |
def driveAndReturn[A](vehicle: A)(implicit vehicleLike: VehicleLike[A]): A = ... | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment