Skip to content

Instantly share code, notes, and snippets.

@justjoheinz
Created September 8, 2015 13:49
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save justjoheinz/045dfc1c36c762ea6387 to your computer and use it in GitHub Desktop.
Save justjoheinz/045dfc1c36c762ea6387 to your computer and use it in GitHub Desktop.
import shapeless._
import ops._
import coproduct._
object coproducttest {
type U = Int :+: String :+: CNil
type V = Double :+: List[Int] :+: CNil
type W = Prepend[U,V]#Out
val i : Int = 1
// could not find implicit value for parameter inj: shapeless.ops.coproduct.Inject[coproducttest.W,Int]
val z = Coproduct[W](i)
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment