Skip to content

Commit

Permalink
Make containsKey return true if the key is present and the value is n…
Browse files Browse the repository at this point in the history
…ull in NullableConcurrentHashMap (#320)

* Make containsKey return true if the key is present and the value is null

* Update TestGenericsInvocUnchecked test
  • Loading branch information
coehlrich authored Sep 11, 2023
1 parent d56f39e commit 460f0d9
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ public boolean containsKey(Object key) {
key = NULL_KEY;
}

return super.containsKey(key);
return super.get(key) != null;
}

@Override
Expand Down
2 changes: 1 addition & 1 deletion testData/results/pkg/TestGenericsInvocUnchecked.dec
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ package pkg;

public class TestGenericsInvocUnchecked<T extends Number> {
public void test(int i, TestGenericsInvocUnchecked<?> other) {
new TestGenericsInvocUnchecked.Inner().testInner(i, this, (TestGenericsInvocUnchecked<T>)other);// 11
new TestGenericsInvocUnchecked.Inner().testInner(i, this, other);// 11
}// 12

public void test1(Class<?> c, String s) {
Expand Down

0 comments on commit 460f0d9

Please sign in to comment.