Is static metaprogramming possible in Java?

前端 未结 11 1138
無奈伤痛
無奈伤痛 2020-12-14 00:56

I am a fan of static metaprogramming in C++. I know Java now has generics. Does this mean that static metaprogramming (i.e., compile-time program execution) is possible in

11条回答
  •  离开以前
    2020-12-14 01:07

    Lombok offers a weak form of compile time metaprogramming. However, the technique they use is completely general.

    See Java code transform at compile time for a related discussion

提交回复
热议问题