mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-27 23:04:50 +02:00
8310890: Normalize identifier names
Reviewed-by: naoto, rriggs
This commit is contained in:
parent
58bb6555e7
commit
f6133edb08
10 changed files with 184 additions and 184 deletions
|
@ -1,5 +1,5 @@
|
|||
/*
|
||||
* Copyright (c) 2003, 2022, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2003, 2023, 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
|
||||
|
@ -608,10 +608,10 @@ public class EnumMap<K extends Enum<K>, V> extends AbstractMap<K, V>
|
|||
return false;
|
||||
|
||||
V ourValue = unmaskNull(vals[index]);
|
||||
Object hisValue = e.getValue();
|
||||
Object otherValue = e.getValue();
|
||||
return (e.getKey() == keyUniverse[index] &&
|
||||
(ourValue == hisValue ||
|
||||
(ourValue != null && ourValue.equals(hisValue))));
|
||||
(ourValue == otherValue ||
|
||||
(ourValue != null && ourValue.equals(otherValue))));
|
||||
}
|
||||
|
||||
public int hashCode() {
|
||||
|
@ -685,9 +685,9 @@ public class EnumMap<K extends Enum<K>, V> extends AbstractMap<K, V>
|
|||
// Key types match, compare each value
|
||||
for (int i = 0; i < keyUniverse.length; i++) {
|
||||
Object ourValue = vals[i];
|
||||
Object hisValue = em.vals[i];
|
||||
if (hisValue != ourValue &&
|
||||
(hisValue == null || !hisValue.equals(ourValue)))
|
||||
Object otherValue = em.vals[i];
|
||||
if (otherValue != ourValue &&
|
||||
(otherValue == null || !otherValue.equals(ourValue)))
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
/*
|
||||
* Copyright (c) 2003, 2022, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2003, 2023, 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
|
||||
|
@ -383,20 +383,20 @@ class AnnotationInvocationHandler implements InvocationHandler, Serializable {
|
|||
continue;
|
||||
String member = memberMethod.getName();
|
||||
Object ourValue = memberValues.get(member);
|
||||
Object hisValue = null;
|
||||
AnnotationInvocationHandler hisHandler = asOneOfUs(o);
|
||||
if (hisHandler != null) {
|
||||
hisValue = hisHandler.memberValues.get(member);
|
||||
Object otherValue = null;
|
||||
AnnotationInvocationHandler otherHandler = asOneOfUs(o);
|
||||
if (otherHandler != null) {
|
||||
otherValue = otherHandler.memberValues.get(member);
|
||||
} else {
|
||||
try {
|
||||
hisValue = memberMethod.invoke(o);
|
||||
otherValue = memberMethod.invoke(o);
|
||||
} catch (InvocationTargetException e) {
|
||||
return false;
|
||||
} catch (IllegalAccessException e) {
|
||||
throw new AssertionError(e);
|
||||
}
|
||||
}
|
||||
if (!memberValueEquals(ourValue, hisValue))
|
||||
if (!memberValueEquals(ourValue, otherValue))
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue