Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1560)

Unified Diff: lib/core/sequences.dart

Issue 11235054: Removed IllegalAccessException and UnsupportedOperationException. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: lib/core/sequences.dart
diff --git a/lib/core/sequences.dart b/lib/core/sequences.dart
index 5ed4366aa2e91f58330897c94e713d0d814d0c27..d41a5e8809fd4d0c8c3419eb4d1c0f7bba809b9d 100644
--- a/lib/core/sequences.dart
+++ b/lib/core/sequences.dart
@@ -128,62 +128,62 @@ class SequenceList<E> extends SequenceCollection<E> implements List<E> {
}
void operator []=(int index, E value) {
- throw new UnsupportedOperationException(
+ throw new StateError(
"Cannot modify an unmodifiable list");
}
void set length(int newLength) {
- throw new UnsupportedOperationException(
+ throw new StateError(
"Cannot change the length of an unmodifiable list");
}
void add(E value) {
- throw new UnsupportedOperationException(
+ throw new StateError(
"Cannot add to an unmodifiable list");
}
void addLast(E value) {
- throw new UnsupportedOperationException(
+ throw new StateError(
"Cannot add to an unmodifiable list");
}
void addAll(Collection<E> collection) {
- throw new UnsupportedOperationException(
+ throw new StateError(
"Cannot add to an unmodifiable list");
}
void sort([Comparator<E> compare]) {
- throw new UnsupportedOperationException(
+ throw new StateError(
"Cannot modify an unmodifiable list");
}
void clear() {
- throw new UnsupportedOperationException(
+ throw new StateError(
"Cannot clear an unmodifiable list");
}
E removeAt(int index) {
- throw new UnsupportedOperationException(
+ throw new StateError(
"Cannot remove in an unmodifiable list");
}
E removeLast() {
- throw new UnsupportedOperationException(
+ throw new StateError(
"Cannot remove in an unmodifiable list");
}
void setRange(int start, int length, List<E> from, [int startFrom]) {
- throw new UnsupportedOperationException(
+ throw new StateError(
"Cannot modify an unmodifiable list");
}
void removeRange(int start, int length) {
- throw new UnsupportedOperationException(
+ throw new StateError(
"Cannot remove in an unmodifiable list");
}
void insertRange(int start, int length, [E initialValue]) {
- throw new UnsupportedOperationException(
+ throw new StateError(
"Cannot insert range in an unmodifiable list");
}
}

Powered by Google App Engine
This is Rietveld 408576698