RFR: 8289397: Fix warnings: Possible accidental assignment in place of a comparison. A condition expression should not be reduced to an assignment
Kevin Rushforth
kcr at openjdk.org
Tue Jul 26 22:27:26 UTC 2022
On Tue, 26 Jul 2022 21:14:58 GMT, Andy Goryachev <angorya at openjdk.org> wrote:
> - replaced with exact functional equivalent (in the presence of exceptions, for example)
I didn't see Phil's comments before I reviewed. To answer them:
> I don't see the difference between
> if (valid = res.validate(fctx)) {
> and
> if ((valid = res.validate(fctx)) == true) {
I would read the latter as being intentional, since there is otherwise no good reason for the `== true`. Having said that, perhaps that points out the need for a comment?
-------------
PR: https://git.openjdk.org/jfx/pull/851
More information about the openjfx-dev
mailing list