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

Unified Diff: runtime/bin/string_stream.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/bin/socket_stream.dart ('k') | runtime/lib/string.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/bin/string_stream.dart
===================================================================
--- runtime/bin/string_stream.dart (revision 855)
+++ runtime/bin/string_stream.dart (working copy)
@@ -171,7 +171,7 @@
class _StringInputStream implements StringInputStream {
_StringInputStream(InputStream this._input, [String this._encoding]) {
- if (_encoding == null) {
+ if (_encoding === null) {
_encoding = "UTF-8";
}
if (_encoding == "UTF-8") {
@@ -213,7 +213,7 @@
}
// Try to fill more data into the buffer and read a line.
if (_fillBuffer()) {
- if (_eof && _buffer == null) return null;
+ if (_eof && _buffer === null) return null;
return _readLineFromBuffer();
}
return null;
@@ -299,11 +299,11 @@
}
_readData();
var decodedString = _decoder.decoded;
- if (decodedString == null && _closed) {
+ if (decodedString === null && _closed) {
_eof = true;
return true;
}
- if (_buffer == null) {
+ if (_buffer === null) {
_buffer = decodedString;
if (_buffer != null) {
_bufferLineStart = 0;
« no previous file with comments | « runtime/bin/socket_stream.dart ('k') | runtime/lib/string.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698