| 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 dart2js.typechecker; | 5 library dart2js.typechecker; |
| 6 | 6 |
| 7 import 'common.dart'; | 7 import 'common.dart'; |
| 8 import 'common/names.dart' show | 8 import 'common/names.dart' show |
| 9 Identifiers; | 9 Identifiers; |
| 10 import 'common/resolution.dart' show | 10 import 'common/resolution.dart' show |
| (...skipping 824 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 835 break; | 835 break; |
| 836 case MemberKind.OPERATOR: | 836 case MemberKind.OPERATOR: |
| 837 reportMessage(node, MessageKind.UNDEFINED_OPERATOR, | 837 reportMessage(node, MessageKind.UNDEFINED_OPERATOR, |
| 838 {'className': receiverType.name, 'memberName': name}, | 838 {'className': receiverType.name, 'memberName': name}, |
| 839 isHint: isHint); | 839 isHint: isHint); |
| 840 break; | 840 break; |
| 841 case MemberKind.GETTER: | 841 case MemberKind.GETTER: |
| 842 if (lookupMemberSignature(memberName.setter, interface) != null) { | 842 if (lookupMemberSignature(memberName.setter, interface) != null) { |
| 843 // A setter is present so warn explicitly about the missing | 843 // A setter is present so warn explicitly about the missing |
| 844 // getter. | 844 // getter. |
| 845 reportMessage(node, MessageKind.UNDEFINED_INSTANCE_GETTER_BUT_SETT
ER, | 845 reportMessage(node, |
| 846 MessageKind.UNDEFINED_INSTANCE_GETTER_BUT_SETTER, |
| 846 {'className': receiverType.name, 'memberName': name}, | 847 {'className': receiverType.name, 'memberName': name}, |
| 847 isHint: isHint); | 848 isHint: isHint); |
| 848 } else if (name == 'await') { | 849 } else if (name == 'await') { |
| 849 Map arguments = {'className': receiverType.name}; | 850 Map arguments = {'className': receiverType.name}; |
| 850 String functionName = executableContext.name; | 851 String functionName = executableContext.name; |
| 851 MessageKind kind; | 852 MessageKind kind; |
| 852 if (functionName == '') { | 853 if (functionName == '') { |
| 853 kind = MessageKind.AWAIT_MEMBER_NOT_FOUND_IN_CLOSURE; | 854 kind = MessageKind.AWAIT_MEMBER_NOT_FOUND_IN_CLOSURE; |
| 854 } else { | 855 } else { |
| 855 kind = MessageKind.AWAIT_MEMBER_NOT_FOUND; | 856 kind = MessageKind.AWAIT_MEMBER_NOT_FOUND; |
| (...skipping 1147 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2003 | 2004 |
| 2004 visitTypedef(Typedef node) { | 2005 visitTypedef(Typedef node) { |
| 2005 // Do not typecheck [Typedef] nodes. | 2006 // Do not typecheck [Typedef] nodes. |
| 2006 } | 2007 } |
| 2007 | 2008 |
| 2008 visitNode(Node node) { | 2009 visitNode(Node node) { |
| 2009 reporter.internalError(node, | 2010 reporter.internalError(node, |
| 2010 'Unexpected node ${node.getObjectDescription()} in the type checker.'); | 2011 'Unexpected node ${node.getObjectDescription()} in the type checker.'); |
| 2011 } | 2012 } |
| 2012 } | 2013 } |
| OLD | NEW |