While this particular example seems like a no-brainer, what if we instead had:
f (Proxy @t) x =
case x of
Proxy @($(doSomeStuff)) = Proxy @t
In this context, should my code really break when an update to doSomeStuff
calls the name it generates t
instead of s
?
I guess if we’re fully committed to not having hygiene, the answer is “yes, and doSomeStuff
should really only bind gensyms”.
Edit
I’ve now had my morning tea, and I just realized that your question was really “should splices be able to bind type variables at all?”. It seems to me that the answer should be identical to “should splices be able to bind term variables?”. Sorry for the distraction.