Index: tests/compiler/dart2js/mock_compiler.dart |
diff --git a/tests/compiler/dart2js/mock_compiler.dart b/tests/compiler/dart2js/mock_compiler.dart |
index 38ddd79fafb8747590ae1fe47a1a0635a590d5ae..d8d37fd06d058a4292dac036ee347cf6426a9128 100644 |
--- a/tests/compiler/dart2js/mock_compiler.dart |
+++ b/tests/compiler/dart2js/mock_compiler.dart |
@@ -135,7 +135,7 @@ class MockCompiler extends Compiler { |
void reportMessage(SourceSpan span, var message, api.Diagnostic kind) { |
var diagnostic = new WarningMessage(null, message.message); |
- if (kind === api.Diagnostic.ERROR) { |
+ if (identical(kind, api.Diagnostic.ERROR)) { |
Lasse Reichstein Nielsen
2012/11/12 13:10:41
Consider whether == would do, since Diagnostic pro
floitsch
2012/11/12 22:18:43
Done.
|
errors.add(diagnostic); |
} else { |
warnings.add(diagnostic); |
@@ -183,7 +183,7 @@ class MockCompiler extends Compiler { |
} |
parseScript(String text, [LibraryElement library]) { |
- if (library === null) library = mainApp; |
+ if (library == null) library = mainApp; |
parseUnit(text, this, library); |
} |
@@ -204,7 +204,7 @@ class MockCompiler extends Compiler { |
Script readScript(Uri uri, [ScriptTag node]) { |
SourceFile sourceFile = sourceFiles[uri.toString()]; |
- if (sourceFile === null) throw new ArgumentError(uri); |
+ if (sourceFile == null) throw new ArgumentError(uri); |
return new Script(uri, sourceFile); |
} |
} |