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

Unified Diff: sdk/lib/typed_data/dart2js/typed_data_dart2js.dart

Issue 15263004: Adding isNotEmpty property to collection and string. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Fix template generation Created 7 years, 7 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
« no previous file with comments | « sdk/lib/io/platform_impl.dart ('k') | tests/corelib/collection_length_test.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sdk/lib/typed_data/dart2js/typed_data_dart2js.dart
diff --git a/sdk/lib/typed_data/dart2js/typed_data_dart2js.dart b/sdk/lib/typed_data/dart2js/typed_data_dart2js.dart
index d6e5f43cc12c11211c7ede686db1cf1f53cf430d..d7afeeddc55fed8fb5bad560b5051ce14afc4731 100644
--- a/sdk/lib/typed_data/dart2js/typed_data_dart2js.dart
+++ b/sdk/lib/typed_data/dart2js/typed_data_dart2js.dart
@@ -314,6 +314,8 @@ class Float32List extends TypedData implements JavaScriptIndexingBehavior, List<
bool get isEmpty => this.length == 0;
+ bool get isNotEmpty => !isEmpty;
+
Iterable<num> take(int n) => IterableMixinWorkaround.takeList(this, n);
Iterable<num> takeWhile(bool test(num value)) {
@@ -534,6 +536,8 @@ class Float64List extends TypedData implements JavaScriptIndexingBehavior, List<
bool get isEmpty => this.length == 0;
+ bool get isNotEmpty => !isEmpty;
+
Iterable<num> take(int n) => IterableMixinWorkaround.takeList(this, n);
Iterable<num> takeWhile(bool test(num value)) {
@@ -754,6 +758,8 @@ class Int16List extends TypedData implements JavaScriptIndexingBehavior, List<in
bool get isEmpty => this.length == 0;
+ bool get isNotEmpty => !isEmpty;
+
Iterable<int> take(int n) => IterableMixinWorkaround.takeList(this, n);
Iterable<int> takeWhile(bool test(int value)) {
@@ -974,6 +980,8 @@ class Int32List extends TypedData implements JavaScriptIndexingBehavior, List<in
bool get isEmpty => this.length == 0;
+ bool get isNotEmpty => !isEmpty;
+
Iterable<int> take(int n) => IterableMixinWorkaround.takeList(this, n);
Iterable<int> takeWhile(bool test(int value)) {
@@ -1194,6 +1202,8 @@ class Int8List extends TypedData implements JavaScriptIndexingBehavior, List<int
bool get isEmpty => this.length == 0;
+ bool get isNotEmpty => !isEmpty;
+
Iterable<int> take(int n) => IterableMixinWorkaround.takeList(this, n);
Iterable<int> takeWhile(bool test(int value)) {
@@ -1414,6 +1424,8 @@ class Uint16List extends TypedData implements JavaScriptIndexingBehavior, List<i
bool get isEmpty => this.length == 0;
+ bool get isNotEmpty => !isEmpty;
+
Iterable<int> take(int n) => IterableMixinWorkaround.takeList(this, n);
Iterable<int> takeWhile(bool test(int value)) {
@@ -1634,6 +1646,8 @@ class Uint32List extends TypedData implements JavaScriptIndexingBehavior, List<i
bool get isEmpty => this.length == 0;
+ bool get isNotEmpty => !isEmpty;
+
Iterable<int> take(int n) => IterableMixinWorkaround.takeList(this, n);
Iterable<int> takeWhile(bool test(int value)) {
@@ -1853,6 +1867,8 @@ class Uint8ClampedList extends Uint8List implements JavaScriptIndexingBehavior,
bool get isEmpty => this.length == 0;
+ bool get isNotEmpty => !isEmpty;
+
Iterable<int> take(int n) => IterableMixinWorkaround.takeList(this, n);
Iterable<int> takeWhile(bool test(int value)) {
@@ -2073,6 +2089,8 @@ class Uint8List extends TypedData implements JavaScriptIndexingBehavior, List<in
bool get isEmpty => this.length == 0;
+ bool get isNotEmpty => !isEmpty;
+
Iterable<int> take(int n) => IterableMixinWorkaround.takeList(this, n);
Iterable<int> takeWhile(bool test(int value)) {
« no previous file with comments | « sdk/lib/io/platform_impl.dart ('k') | tests/corelib/collection_length_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698