JEP 119 / Implementation of javax.lang.model.util.Types
mail at florian-schoppmann.net
Tue May 26 02:57:14 UTC 2015
This Github repository of mine <https://github.com/fschopp/java-types>
provides an abstract skeletal implementation of the type-system related
methods of interface javax.lang.model.util.Types, plus a
concrete realization backed by the core Java Reflection API, akin to JEP
119 by Joe Darcy.
Obviously, there also exists an official JEP 119 implementation, so far
in proof-of-concept state:
In their current states, the two projects have slightly different goals:
E.g., CoreReflectionFactory.java in the official JEP 119
implementation does not yet implement all subtyping-related relations
like, e.g., JLS §4.5.1 "contains", whereas my project is so far only
concerned with subtyping but does not implement any
Element-subinterfaces except TypeElement). Moreover, JEP 119 is only
concerned with backing javax.lang.model by Core Reflection, whereas the
goal of my project is to allow arbitrary backing (say, e.g., by the
domain model of some DSL that needs to support the Java type system).
If there should be any interest in using my code or parts of it for the
JDK, I would be happy to help with any necessary adjustments.
PS: X-post to core-libs.devel and compiler.devel. Follow-up to core-libs
More information about the core-libs-dev