| 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 part of dart2js; | 5 part of dart2js; |
| 6 | 6 |
| 7 /** | 7 /** |
| 8 * If true, print a warning for each method that was resolved, but not | 8 * If true, print a warning for each method that was resolved, but not |
| 9 * compiled. | 9 * compiled. |
| 10 */ | 10 */ |
| (...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 80 List<CompilerTask> get tasks; | 80 List<CompilerTask> get tasks; |
| 81 | 81 |
| 82 // TODO(ahe,karlklose): rename this? | 82 // TODO(ahe,karlklose): rename this? |
| 83 void dumpInferredTypes() {} | 83 void dumpInferredTypes() {} |
| 84 | 84 |
| 85 ItemCompilationContext createItemCompilationContext() { | 85 ItemCompilationContext createItemCompilationContext() { |
| 86 return new ItemCompilationContext(); | 86 return new ItemCompilationContext(); |
| 87 } | 87 } |
| 88 | 88 |
| 89 SourceString getCheckedModeHelper(DartType type) => null; | 89 SourceString getCheckedModeHelper(DartType type) => null; |
| 90 ClassElement getBackendImplementation(ClassElement cls) => null; |
| 90 | 91 |
| 91 Element getInterceptor(Selector selector); | 92 Element getInterceptor(Selector selector); |
| 92 } | 93 } |
| 93 | 94 |
| 94 abstract class Compiler implements DiagnosticListener { | 95 abstract class Compiler implements DiagnosticListener { |
| 95 final Map<String, LibraryElement> libraries; | 96 final Map<String, LibraryElement> libraries; |
| 96 int nextFreeClassId = 0; | 97 int nextFreeClassId = 0; |
| 97 World world; | 98 World world; |
| 98 String assembledCode; | 99 String assembledCode; |
| 99 Types types; | 100 Types types; |
| (...skipping 802 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 902 // TODO(johnniwinther): Use [spannable] and [message] to provide better | 903 // TODO(johnniwinther): Use [spannable] and [message] to provide better |
| 903 // information on assertion errors. | 904 // information on assertion errors. |
| 904 if (condition is Function){ | 905 if (condition is Function){ |
| 905 condition = condition(); | 906 condition = condition(); |
| 906 } | 907 } |
| 907 if (spannable == null || !condition) { | 908 if (spannable == null || !condition) { |
| 908 throw new SpannableAssertionFailure(spannable, message); | 909 throw new SpannableAssertionFailure(spannable, message); |
| 909 } | 910 } |
| 910 return true; | 911 return true; |
| 911 } | 912 } |
| OLD | NEW |