| OLD | NEW |
| 1 // Copyright (c) 2017, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2017, 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 import 'package:js_runtime/shared/embedded_names.dart'; | 5 import 'package:js_runtime/shared/embedded_names.dart'; |
| 6 import 'package:kernel/ast.dart' as ir; | 6 import 'package:kernel/ast.dart' as ir; |
| 7 | 7 |
| 8 import '../common.dart'; | 8 import '../common.dart'; |
| 9 import '../common/names.dart'; | 9 import '../common/names.dart'; |
| 10 import '../constants/constructors.dart'; | 10 import '../constants/constructors.dart'; |
| (...skipping 124 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 135 type ??= findIn(Uris.dart_collection); | 135 type ??= findIn(Uris.dart_collection); |
| 136 type ??= findIn(Uris.dart_math); | 136 type ??= findIn(Uris.dart_math); |
| 137 type ??= findIn(Uris.dart_html); | 137 type ??= findIn(Uris.dart_html); |
| 138 type ??= findIn(Uris.dart_html_common); | 138 type ??= findIn(Uris.dart_html_common); |
| 139 type ??= findIn(Uris.dart_svg); | 139 type ??= findIn(Uris.dart_svg); |
| 140 type ??= findIn(Uris.dart_web_audio); | 140 type ??= findIn(Uris.dart_web_audio); |
| 141 type ??= findIn(Uris.dart_web_gl); | 141 type ??= findIn(Uris.dart_web_gl); |
| 142 type ??= findIn(Uris.dart_web_sql); | 142 type ??= findIn(Uris.dart_web_sql); |
| 143 type ??= findIn(Uris.dart_indexed_db); | 143 type ??= findIn(Uris.dart_indexed_db); |
| 144 type ??= findIn(Uris.dart_typed_data); | 144 type ??= findIn(Uris.dart_typed_data); |
| 145 type ??= findIn(Uris.dart_mirrors); |
| 145 if (type == null && required) { | 146 if (type == null && required) { |
| 146 reporter.reportErrorMessage(CURRENT_ELEMENT_SPANNABLE, | 147 reporter.reportErrorMessage(CURRENT_ELEMENT_SPANNABLE, |
| 147 MessageKind.GENERIC, {'text': "Type '$typeName' not found."}); | 148 MessageKind.GENERIC, {'text': "Type '$typeName' not found."}); |
| 148 } | 149 } |
| 149 return type; | 150 return type; |
| 150 } | 151 } |
| 151 | 152 |
| 152 return lookup; | 153 return lookup; |
| 153 } | 154 } |
| 154 | 155 |
| (...skipping 687 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 842 } | 843 } |
| 843 if (isRedirecting) { | 844 if (isRedirecting) { |
| 844 return new RedirectingGenerativeConstantConstructor( | 845 return new RedirectingGenerativeConstantConstructor( |
| 845 defaultValues, superConstructorInvocation); | 846 defaultValues, superConstructorInvocation); |
| 846 } else { | 847 } else { |
| 847 return new GenerativeConstantConstructor( | 848 return new GenerativeConstantConstructor( |
| 848 type, defaultValues, fieldMap, superConstructorInvocation); | 849 type, defaultValues, fieldMap, superConstructorInvocation); |
| 849 } | 850 } |
| 850 } | 851 } |
| 851 } | 852 } |
| OLD | NEW |