OLD | NEW |
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
4 | 4 |
5 library mirrors_dart2js; | 5 library mirrors_dart2js; |
6 | 6 |
7 import 'dart:io'; | 7 import 'dart:io'; |
8 import 'dart:uri'; | 8 import 'dart:uri'; |
9 | 9 |
10 import '../../../../../lib/compiler/compiler.dart' as diagnostics; | 10 import '../../../../../lib/compiler/compiler.dart' as diagnostics; |
(...skipping 1041 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1052 return false; | 1052 return false; |
1053 } | 1053 } |
1054 if (other.isDeclaration) { | 1054 if (other.isDeclaration) { |
1055 return false; | 1055 return false; |
1056 } | 1056 } |
1057 if (declaration != other.declaration) { | 1057 if (declaration != other.declaration) { |
1058 return false; | 1058 return false; |
1059 } | 1059 } |
1060 var thisTypeArguments = typeArguments.iterator(); | 1060 var thisTypeArguments = typeArguments.iterator(); |
1061 var otherTypeArguments = other.typeArguments.iterator(); | 1061 var otherTypeArguments = other.typeArguments.iterator(); |
1062 while (thisTypeArguments.hasNext() && otherTypeArguments.hasNext()) { | 1062 while (thisTypeArguments.hasNext && otherTypeArguments.hasNext) { |
1063 if (thisTypeArguments.next() != otherTypeArguments.next()) { | 1063 if (thisTypeArguments.next() != otherTypeArguments.next()) { |
1064 return false; | 1064 return false; |
1065 } | 1065 } |
1066 } | 1066 } |
1067 return !thisTypeArguments.hasNext() && !otherTypeArguments.hasNext(); | 1067 return !thisTypeArguments.hasNext && !otherTypeArguments.hasNext; |
1068 } | 1068 } |
1069 } | 1069 } |
1070 | 1070 |
1071 | 1071 |
1072 class Dart2JsFunctionTypeMirror extends Dart2JsTypeElementMirror | 1072 class Dart2JsFunctionTypeMirror extends Dart2JsTypeElementMirror |
1073 implements FunctionTypeMirror { | 1073 implements FunctionTypeMirror { |
1074 final FunctionSignature _functionSignature; | 1074 final FunctionSignature _functionSignature; |
1075 List<ParameterMirror> _parameters; | 1075 List<ParameterMirror> _parameters; |
1076 | 1076 |
1077 Dart2JsFunctionTypeMirror(Dart2JsMirrorSystem system, | 1077 Dart2JsFunctionTypeMirror(Dart2JsMirrorSystem system, |
(...skipping 311 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1389 if (node !== null) { | 1389 if (node !== null) { |
1390 var span = system.compiler.spanFromNode(node, script.uri); | 1390 var span = system.compiler.spanFromNode(node, script.uri); |
1391 return new Dart2JsLocation(script, span); | 1391 return new Dart2JsLocation(script, span); |
1392 } else { | 1392 } else { |
1393 var span = system.compiler.spanFromElement(_variable); | 1393 var span = system.compiler.spanFromElement(_variable); |
1394 return new Dart2JsLocation(script, span); | 1394 return new Dart2JsLocation(script, span); |
1395 } | 1395 } |
1396 } | 1396 } |
1397 } | 1397 } |
1398 | 1398 |
OLD | NEW |