commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Simon Spero <>
Subject [CLI] Please review CLI-277
Date Wed, 14 Jun 2017 12:46:43 GMT
On Jun 14, 2017 4:28 AM, "Benedikt Ritter" <> wrote:

I’d like to have feedback for CLI-277 [1], especially whether it will
affect BC. Clirr is happy with this changes, to I suppose it is fine to
merge this?

[1] <>

The changes look like they ought to be ok, but I need to  check on
something that isn't a tablet.

In general, going from raw to generic  is easy, since the type erasure are
the same, but changing things once they are generic gets harder. As des
Rivers et. al. (2007,2017) note:

But, also bear in mind that there are severe constraints on how a type or
method that already is generic can be compatibly evolved with respect to
its type parameters (see the tables above). So if you plan to generify an
API, remember that you only get one chance (release), to get it right. In
particular, if you change a type in an API signature from the raw type "List"
to "List<?>" or "List<Object>", you will be locked into that decision. The
moral is that generifying an existing API is something that should be
considered from the perspective of the API as a whole rather than piecemeal
on a method-by-method or class-by-class basis.

These guidelines are one of the best reference sources for information on
compatibility. Definitely more comprehensible than the JLS.

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message