For below types
type HFunc = (Int :: String :: HNil) => Int
type Func = (Int, String) => Int
I try to convert Func
to HFunc
val funExpr: Tree = ???
val hlistType = ???
val hfuncName = c.freshName("hfunc")
q"""
def $hfuncName(t: $hlistType) = {
${funExpr}(..) //how to extract hlist elements as params ?
}
"""
How Can I extract the HList
elements and pass it to the Func
?