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 | 5 |
6 /** | 6 /** |
7 * If true, print a warning for each method that was resolved, but not | 7 * If true, print a warning for each method that was resolved, but not |
8 * compiled. | 8 * compiled. |
9 */ | 9 */ |
10 final bool REPORT_EXCESS_RESOLUTION = false; | 10 final bool REPORT_EXCESS_RESOLUTION = false; |
(...skipping 894 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
905 codegenWorld.addGeneratedCode(work, codeBuffer); | 905 codegenWorld.addGeneratedCode(work, codeBuffer); |
906 return codeBuffer.toString(); | 906 return codeBuffer.toString(); |
907 } | 907 } |
908 } | 908 } |
909 | 909 |
910 void registerInstantiatedClass(ClassElement cls) { | 910 void registerInstantiatedClass(ClassElement cls) { |
911 enqueuer.resolution.registerInstantiatedClass(cls); | 911 enqueuer.resolution.registerInstantiatedClass(cls); |
912 enqueuer.codegen.registerInstantiatedClass(cls); | 912 enqueuer.codegen.registerInstantiatedClass(cls); |
913 } | 913 } |
914 | 914 |
915 void resolveClass(ClassElement element) { | |
916 withCurrentElement(element, () => resolver.resolveClass(element)); | |
917 } | |
918 | |
919 Type resolveTypeAnnotation(Element element, TypeAnnotation annotation) { | 915 Type resolveTypeAnnotation(Element element, TypeAnnotation annotation) { |
920 return resolver.resolveTypeAnnotation(element, annotation); | 916 return resolver.resolveTypeAnnotation(element, annotation); |
921 } | 917 } |
922 | 918 |
923 FunctionSignature resolveSignature(FunctionElement element) { | 919 FunctionSignature resolveSignature(FunctionElement element) { |
924 return withCurrentElement(element, | 920 return withCurrentElement(element, |
925 () => resolver.resolveSignature(element)); | 921 () => resolver.resolveSignature(element)); |
926 } | 922 } |
927 | 923 |
928 FunctionSignature resolveFunctionExpression(Element element, | 924 FunctionSignature resolveFunctionExpression(Element element, |
(...skipping 166 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1095 final endOffset = end.charOffset + end.slowCharCount; | 1091 final endOffset = end.charOffset + end.slowCharCount; |
1096 | 1092 |
1097 // [begin] and [end] might be the same for the same empty token. This | 1093 // [begin] and [end] might be the same for the same empty token. This |
1098 // happens for instance when scanning '$$'. | 1094 // happens for instance when scanning '$$'. |
1099 assert(endOffset >= beginOffset); | 1095 assert(endOffset >= beginOffset); |
1100 return f(beginOffset, endOffset); | 1096 return f(beginOffset, endOffset); |
1101 } | 1097 } |
1102 | 1098 |
1103 String toString() => 'SourceSpan($uri, $begin, $end)'; | 1099 String toString() => 'SourceSpan($uri, $begin, $end)'; |
1104 } | 1100 } |
OLD | NEW |