-
Notifications
You must be signed in to change notification settings - Fork 1.1k
TASTY: no way to access variance of parameters of a TypeParamRef
type constructor
#16734
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
@nicolasstucki @Kordyjan it seems the underlying internal compiler API changed ( |
@neko-kai to make sure we support the use-cases of needed in
To make the |
Related to scala#16734
Related to scala#16734
Related to scala#16734
This is a follow-up to #8520
As per @smarter's suggestion in #8520 (comment) there is now a method
.typeMembers
that can extract symbols for type parameters of a trait/class.However, there's no exposed way to extract variance information of a type parameter, that is extract variance of parameters of
F
intrait K[F[+_, +_]]
. @smarter describes a way to get this information in his post above:Right now I implemented the above procedure by accessing hidden methods
TypeParamRef#underlying
andHKTypeLambda#declaredVariances
using Java reflection. (current usage)But it would be great if
Quotes
interface exposed these methods non-reflectively, so that I could drop these workarounds. Thanks!The text was updated successfully, but these errors were encountered: