| OLD | NEW |
| 1 // Copyright (c) 2016, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2016, 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 fasta.kernel_target; | 5 library fasta.kernel_target; |
| 6 | 6 |
| 7 import 'dart:async' show | 7 import 'dart:async' show |
| 8 Future; | 8 Future; |
| 9 | 9 |
| 10 import 'dart:io' show | 10 import 'dart:io' show |
| (...skipping 233 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 244 } | 244 } |
| 245 } | 245 } |
| 246 | 246 |
| 247 Future<Program> writeOutline(Uri uri) async { | 247 Future<Program> writeOutline(Uri uri) async { |
| 248 if (loader.first == null) return null; | 248 if (loader.first == null) return null; |
| 249 try { | 249 try { |
| 250 await loader.buildOutlines(); | 250 await loader.buildOutlines(); |
| 251 loader.resolveParts(); | 251 loader.resolveParts(); |
| 252 loader.computeLibraryScopes(); | 252 loader.computeLibraryScopes(); |
| 253 loader.resolveTypes(); | 253 loader.resolveTypes(); |
| 254 loader.convertConstructors(); | |
| 255 loader.buildProgram(); | 254 loader.buildProgram(); |
| 256 loader.checkSemantics(); | 255 loader.checkSemantics(); |
| 257 List<SourceClassBuilder> sourceClasses = collectAllSourceClasses(); | 256 List<SourceClassBuilder> sourceClasses = collectAllSourceClasses(); |
| 258 installDefaultSupertypes(sourceClasses); | 257 installDefaultSupertypes(sourceClasses); |
| 259 installDefaultConstructors(sourceClasses); | 258 installDefaultConstructors(sourceClasses); |
| 260 loader.resolveConstructors(); | 259 loader.resolveConstructors(); |
| 261 program = link(new List<Library>.from(loader.libraries)); | 260 program = link(new List<Library>.from(loader.libraries)); |
| 262 if (uri == null) return program; | 261 if (uri == null) return program; |
| 263 return await writeLinkedProgram(uri, program, isFullProgram: false); | 262 return await writeLinkedProgram(uri, program, isFullProgram: false); |
| 264 } on InputError catch (e) { | 263 } on InputError catch (e) { |
| (...skipping 326 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 591 superclass = superclass.superclass; | 590 superclass = superclass.superclass; |
| 592 } | 591 } |
| 593 for (Constructor constructor in superclass.constructors) { | 592 for (Constructor constructor in superclass.constructors) { |
| 594 if (constructor.name.name.isEmpty) { | 593 if (constructor.name.name.isEmpty) { |
| 595 return constructor.function.requiredParameterCount == 0 ? | 594 return constructor.function.requiredParameterCount == 0 ? |
| 596 constructor : null; | 595 constructor : null; |
| 597 } | 596 } |
| 598 } | 597 } |
| 599 return null; | 598 return null; |
| 600 } | 599 } |
| OLD | NEW |