mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-28 07:14:30 +02:00
8289274: Cleanup unnecessary null comparison before instanceof check in security modules
Reviewed-by: mullan
This commit is contained in:
parent
81ee7d28f8
commit
87aa3ce03e
14 changed files with 54 additions and 94 deletions
|
@ -1,5 +1,5 @@
|
|||
/*
|
||||
* Copyright (c) 2003, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2003, 2022, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
|
@ -87,10 +87,9 @@ public final class AccessDescription {
|
|||
}
|
||||
|
||||
public boolean equals(Object obj) {
|
||||
if (obj == null || (!(obj instanceof AccessDescription))) {
|
||||
if (!(obj instanceof AccessDescription that)) {
|
||||
return false;
|
||||
}
|
||||
AccessDescription that = (AccessDescription)obj;
|
||||
|
||||
if (this == that) {
|
||||
return true;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue