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 Future; | 7 import 'dart:async' show Future; |
8 | 8 |
9 import 'dart:io' show File; | 9 import 'dart:io' show File; |
10 | 10 |
(...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
94 | 94 |
95 Program program; | 95 Program program; |
96 | 96 |
97 final List<String> errors = <String>[]; | 97 final List<String> errors = <String>[]; |
98 | 98 |
99 final TypeBuilder dynamicType = | 99 final TypeBuilder dynamicType = |
100 new KernelNamedTypeBuilder("dynamic", null, -1, null); | 100 new KernelNamedTypeBuilder("dynamic", null, -1, null); |
101 | 101 |
102 bool get strongMode => backendTarget.strongMode; | 102 bool get strongMode => backendTarget.strongMode; |
103 | 103 |
| 104 bool get disableTypeInference => backendTarget.disableTypeInference; |
| 105 |
104 KernelTarget( | 106 KernelTarget( |
105 this.fileSystem, DillTarget dillTarget, TranslateUri uriTranslator, | 107 this.fileSystem, DillTarget dillTarget, TranslateUri uriTranslator, |
106 [Map<String, Source> uriToSource]) | 108 [Map<String, Source> uriToSource]) |
107 : dillTarget = dillTarget, | 109 : dillTarget = dillTarget, |
108 uriToSource = uriToSource ?? CompilerContext.current.uriToSource, | 110 uriToSource = uriToSource ?? CompilerContext.current.uriToSource, |
109 super(dillTarget.ticker, uriTranslator, dillTarget.backendTarget) { | 111 super(dillTarget.ticker, uriTranslator, dillTarget.backendTarget) { |
110 resetCrashReporting(); | 112 resetCrashReporting(); |
111 loader = createLoader(); | 113 loader = createLoader(); |
112 } | 114 } |
113 | 115 |
(...skipping 612 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
726 } | 728 } |
727 for (Constructor constructor in superclass.constructors) { | 729 for (Constructor constructor in superclass.constructors) { |
728 if (constructor.name.name.isEmpty) { | 730 if (constructor.name.name.isEmpty) { |
729 return constructor.function.requiredParameterCount == 0 | 731 return constructor.function.requiredParameterCount == 0 |
730 ? constructor | 732 ? constructor |
731 : null; | 733 : null; |
732 } | 734 } |
733 } | 735 } |
734 return null; | 736 return null; |
735 } | 737 } |
OLD | NEW |