File tree 3 files changed +4
-4
lines changed
main/java/com/google/gson/internal/bind
test/java/com/google/gson
3 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -277,7 +277,7 @@ JsonElement nextJsonElement() throws IOException {
277
277
JsonToken peeked = peek ();
278
278
switch (peeked ) {
279
279
case NAME :
280
- nextName (true );
280
+ String unused = nextName (true );
281
281
break ;
282
282
case END_ARRAY :
283
283
endArray ();
Original file line number Diff line number Diff line change @@ -210,7 +210,7 @@ public void testContains() {
210
210
assertFalse (list .contains (new JsonPrimitive (2 )));
211
211
assertFalse (list .contains (null ));
212
212
213
- @ SuppressWarnings ("unlikely-arg-type" )
213
+ @ SuppressWarnings ({ "unlikely-arg-type" , "CollectionIncompatibleType" } )
214
214
boolean containsInt = list .contains (1 ); // should only contain JsonPrimitive(1)
215
215
assertFalse (containsInt );
216
216
}
@@ -227,7 +227,7 @@ public void testIndexOf() {
227
227
assertEquals (-1 , list .indexOf (new JsonPrimitive (2 )));
228
228
assertEquals (-1 , list .indexOf (null ));
229
229
230
- @ SuppressWarnings ("unlikely-arg-type" )
230
+ @ SuppressWarnings ({ "unlikely-arg-type" , "CollectionIncompatibleType" } )
231
231
int indexOfInt = list .indexOf (1 ); // should only contain JsonPrimitive(1)
232
232
assertEquals (-1 , indexOfInt );
233
233
Original file line number Diff line number Diff line change @@ -59,7 +59,7 @@ public void testContainsValue() {
59
59
assertFalse (map .containsValue (new JsonPrimitive (2 )));
60
60
assertFalse (map .containsValue (null ));
61
61
62
- @ SuppressWarnings ("unlikely-arg-type" )
62
+ @ SuppressWarnings ({ "unlikely-arg-type" , "CollectionIncompatibleType" } )
63
63
boolean containsInt = map .containsValue (1 ); // should only contain JsonPrimitive(1)
64
64
assertFalse (containsInt );
65
65
}
You can’t perform that action at this time.
0 commit comments