Accessing class tree from its field's tree
Asked Answered
C

0

6

I'd like to write a macro which enriches case classes. When I declare my case class like this:

case class User(int id, @tagged name)

I want to be able to inject some stuff into the Tree of this class having only annottees. So far I was only able to reach the Symbol of the enclosing class, but looks like it's not enough (see Eugene's answer here). I also don't want to use deprecated api of c.enclosingClass. Is there any way to reach parent ClassDef in paradise 2.1.0 (Scala 2.11)?

Cirilo answered 22/3, 2016 at 20:45 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.