On Wed, 20 Jul 2022 15:13:05 GMT, Andrew Haley <a...@openjdk.org> wrote:
> > I think having `PRAGMA_ALLOW_LOSSY_CONVERSIONS` in the file also sends a > > much clearer message that: warnings in this file have not been looked > > at/fixed yet, which I don't think `checked_cast` does. > > It kinda would, because such casts would have to be considered. But OK. What I mean is that `checked_cast` can also be used intentionally. So, looking at a particular `checked_cast` it might be hard to tell if this use case should still be address/fixed. or if it has already been addressed and the solution was to use `checked_cast`. > > The approach I've taken preserves the current behavior of the code, but it > > also allows for fixing these warnings on a per-file basis (besides enabling > > the warning for the 800 or so files that don't have warnings right now). > > This seems to me like an easier and safer way to make progress. > > OK, so this is hopefully a temporary fix. Yes, this is not meant to be a long term solution. Just a way of allowing for more incremental progress, as well as a stop gap for files that are good today. ------------- PR: https://git.openjdk.org/jdk/pull/9516