| 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 1069 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1080 libraries.forEach( | 1080 libraries.forEach( |
| 1081 (_, lib) => fullyEnqueueLibrary(lib, enqueuer.resolution)); | 1081 (_, lib) => fullyEnqueueLibrary(lib, enqueuer.resolution)); |
| 1082 } | 1082 } |
| 1083 // Elements required by enqueueHelpers are global dependencies | 1083 // Elements required by enqueueHelpers are global dependencies |
| 1084 // that are not pulled in by a particular element. | 1084 // that are not pulled in by a particular element. |
| 1085 backend.enqueueHelpers(enqueuer.resolution, globalDependencies); | 1085 backend.enqueueHelpers(enqueuer.resolution, globalDependencies); |
| 1086 resolveLibraryMetadata(); | 1086 resolveLibraryMetadata(); |
| 1087 processQueue(enqueuer.resolution, main); | 1087 processQueue(enqueuer.resolution, main); |
| 1088 enqueuer.resolution.logSummary(log); | 1088 enqueuer.resolution.logSummary(log); |
| 1089 | 1089 |
| 1090 if (compilationFailed) return; |
| 1090 if (analyzeOnly) { | 1091 if (analyzeOnly) { |
| 1091 if (!analyzeAll) { | 1092 if (!analyzeAll) { |
| 1092 // No point in reporting unused code when [analyzeAll] is true: all | 1093 // No point in reporting unused code when [analyzeAll] is true: all |
| 1093 // code is artificially used. | 1094 // code is artificially used. |
| 1094 reportUnusedCode(); | 1095 reportUnusedCode(); |
| 1095 } | 1096 } |
| 1096 return; | 1097 return; |
| 1097 } | 1098 } |
| 1098 if (compilationFailed) return; | |
| 1099 assert(main != null); | 1099 assert(main != null); |
| 1100 phase = PHASE_DONE_RESOLVING; | 1100 phase = PHASE_DONE_RESOLVING; |
| 1101 | 1101 |
| 1102 // TODO(ahe): Remove this line. Eventually, enqueuer.resolution | 1102 // TODO(ahe): Remove this line. Eventually, enqueuer.resolution |
| 1103 // should know this. | 1103 // should know this. |
| 1104 world.populate(); | 1104 world.populate(); |
| 1105 // Compute whole-program-knowledge that the backend needs. (This might | 1105 // Compute whole-program-knowledge that the backend needs. (This might |
| 1106 // require the information computed in [world.populate].) | 1106 // require the information computed in [world.populate].) |
| 1107 backend.onResolutionComplete(); | 1107 backend.onResolutionComplete(); |
| 1108 | 1108 |
| (...skipping 569 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1678 | 1678 |
| 1679 void close() {} | 1679 void close() {} |
| 1680 | 1680 |
| 1681 toString() => name; | 1681 toString() => name; |
| 1682 | 1682 |
| 1683 /// Convenience method for getting an [api.CompilerOutputProvider]. | 1683 /// Convenience method for getting an [api.CompilerOutputProvider]. |
| 1684 static NullSink outputProvider(String name, String extension) { | 1684 static NullSink outputProvider(String name, String extension) { |
| 1685 return new NullSink('$name.$extension'); | 1685 return new NullSink('$name.$extension'); |
| 1686 } | 1686 } |
| 1687 } | 1687 } |
| OLD | NEW |