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

Unified Diff: runtime/vm/snapshot_test.dart

Issue 8400038: Use strict equality when comparing with null, especially when null is a default value. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: '' Created 9 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
« no previous file with comments | « runtime/lib/string.dart ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/snapshot_test.dart
===================================================================
--- runtime/vm/snapshot_test.dart (revision 855)
+++ runtime/vm/snapshot_test.dart (working copy)
@@ -121,7 +121,7 @@
TowersDisk pop(int pile) {
var top = piles[pile];
- if (top == null)
+ if (top === null)
Error.error("Attempting to remove a disk from an empty pile.");
piles[pile] = top.next;
top.next = null;
@@ -524,10 +524,10 @@
void insert(int n) {
if (n < value) {
- if (left == null) left = new TreeNodePress(n);
+ if (left === null) left = new TreeNodePress(n);
else left.insert(n);
} else {
- if (right == null) right = new TreeNodePress(n);
+ if (right === null) right = new TreeNodePress(n);
else right.insert(n);
}
}
@@ -537,8 +537,8 @@
TreeNodePress right = this.right;
int value = this.value;
- return ((left == null) || ((left.value < value) && left.check())) &&
- ((right == null) || ((right.value >= value) && right.check()));
+ return ((left === null) || ((left.value < value) && left.check())) &&
+ ((right === null) || ((right.value >= value) && right.check()));
}
}
@@ -609,7 +609,7 @@
ListElement xTail = x;
ListElement yTail = y;
while (yTail != null) {
- if (xTail == null) return true;
+ if (xTail === null) return true;
xTail = xTail.next;
yTail = yTail.next;
}
@@ -2137,7 +2137,7 @@
void main() {
this.port.receive((message, SendPort replyTo) {
if (message == MandelIsolateTest.TERMINATION_MESSAGE) {
- assert(replyTo == null);
+ assert(replyTo === null);
this.port.close();
} else {
replyTo.send(_processLine(message), null);
« no previous file with comments | « runtime/lib/string.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698