--- old/src/share/classes/java/util/Collection.java 2013-09-17 14:54:25.705274297 -0700 +++ new/src/share/classes/java/util/Collection.java 2013-09-17 14:54:25.553274289 -0700 @@ -1,4 +1,4 @@ -/* +f/* * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * @@ -379,8 +379,8 @@ /** * Removes all of the elements of this collection that satisfy the given - * predicate. Errors or runtime exceptions thrown by the predicate are - * relayed to the caller. + * predicate. Errors or runtime exceptions thrown during iteration or by + * the predicate are relayed to the caller. * * @implSpec * The default implementation traverses all elements of the collection using @@ -393,9 +393,10 @@ * removed * @return {@code true} if any elements were removed * @throws NullPointerException if the specified filter is null - * @throws UnsupportedOperationException if the {@code remove} - * method is not supported by this collection's - * {@link #iterator} + * @throws UnsupportedOperationException if elements cannot be removed + * from this collection. Implementations may throw this exception if a + * matching element cannot be removed or if, in general, removal is not + * supported. * @since 1.8 */ default boolean removeIf(Predicate filter) { --- old/src/share/classes/java/util/List.java 2013-09-17 14:54:26.289274325 -0700 +++ new/src/share/classes/java/util/List.java 2013-09-17 14:54:26.137274318 -0700 @@ -396,11 +396,13 @@ * replacing the first element. * * @param operator the operator to apply to each element - * @throws UnsupportedOperationException if the {@code set} - * operation is not supported by this list + * @throws UnsupportedOperationException if this list is unmodifiable. + * Implementations may throw this exception if a matching element + * cannot be replaced or if, in general, modification is not + * supported * @throws NullPointerException if the specified operator is null or - * if the element is replaced with a null value and this list - * does not permit null elements + * if the operator result is a null value and this list does + * not permit null elements * (optional) * @since 1.8 */ @@ -685,4 +687,3 @@ return Spliterators.spliterator(this, Spliterator.ORDERED); } } - --- old/test/java/util/Collection/MOAT.java 2013-09-17 14:54:26.893274354 -0700 +++ new/test/java/util/Collection/MOAT.java 2013-09-17 14:54:26.721274346 -0700 @@ -207,8 +207,8 @@ new Fun(){void f(){ it.next(); }}); try { it.remove(); } - catch (IllegalStateException _) { pass(); } - catch (UnsupportedOperationException _) { pass(); } + catch (IllegalStateException ignored) { pass(); } + catch (UnsupportedOperationException ignored) { pass(); } catch (Throwable t) { unexpected(t); } if (rnd.nextBoolean()) @@ -280,9 +280,9 @@ testEmptyCollection(m.values()); try { check(! m.containsValue(null)); } - catch (NullPointerException _) { /* OK */ } + catch (NullPointerException ignored) { /* OK */ } try { check(! m.containsKey(null)); } - catch (NullPointerException _) { /* OK */ } + catch (NullPointerException ignored) { /* OK */ } check(! m.containsValue(1)); check(! m.containsKey(1)); } @@ -710,8 +710,8 @@ l.addAll(-1, Collections.emptyList()); fail("Expected IndexOutOfBoundsException not thrown"); } - catch (UnsupportedOperationException _) {/* OK */} - catch (IndexOutOfBoundsException _) {/* OK */} + catch (UnsupportedOperationException ignored) {/* OK */} + catch (IndexOutOfBoundsException ignored) {/* OK */} catch (Throwable t) { unexpected(t); } // equal(l instanceof Serializable,