Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(225)

Side by Side Diff: sdk/lib/_internal/compiler/samples/leap/leap_leg.dart

Issue 12052038: Rename new Uri.fromString to Uri.parse. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Reupload because of Error. Created 7 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « sdk/lib/_internal/compiler/implementation/dart2js.dart ('k') | sdk/lib/io/http_impl.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 compilerIsolate(port) { 5 compilerIsolate(port) {
6 Runner runner = new Runner(); 6 Runner runner = new Runner();
7 runner.init(); 7 runner.init();
8 8
9 port.receive((msg, replyTo) { 9 port.receive((msg, replyTo) {
10 replyTo.send(runner.update(msg)); 10 replyTo.send(runner.update(msg));
(...skipping 204 matching lines...) Expand 10 before | Expand all | Expand 10 after
215 215
216 LeapCompiler() : cache = new HttpRequestCache(), super() { 216 LeapCompiler() : cache = new HttpRequestCache(), super() {
217 tasks = [scanner, dietParser, parser, resolver, checker]; 217 tasks = [scanner, dietParser, parser, resolver, checker];
218 } 218 }
219 219
220 void log(message) { print(message); } 220 void log(message) { print(message); }
221 221
222 String get legDirectory => libDir; 222 String get legDirectory => libDir;
223 223
224 LibraryElement scanBuiltinLibrary(String path) { 224 LibraryElement scanBuiltinLibrary(String path) {
225 Uri base = new Uri.fromString(html.window.location.toString()); 225 Uri base = Uri.parse(html.window.location.toString());
226 Uri libraryRoot = base.resolve(libDir); 226 Uri libraryRoot = base.resolve(libDir);
227 Uri resolved = libraryRoot.resolve(DART2JS_LIBRARY_MAP[path]); 227 Uri resolved = libraryRoot.resolve(DART2JS_LIBRARY_MAP[path]);
228 LibraryElement library = scanner.loadLibrary(resolved, null); 228 LibraryElement library = scanner.loadLibrary(resolved, null);
229 return library; 229 return library;
230 } 230 }
231 231
232 currentScript() { 232 currentScript() {
233 if (currentElement == null) return null; 233 if (currentElement == null) return null;
234 CompilationUnitElement compilationUnit = 234 CompilationUnitElement compilationUnit =
235 currentElement.getCompilationUnit(); 235 currentElement.getCompilationUnit();
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after
278 mainApp = new LibraryElement(script); 278 mainApp = new LibraryElement(script);
279 279
280 universe.libraries.remove(script.uri.toString()); 280 universe.libraries.remove(script.uri.toString());
281 Element element; 281 Element element;
282 withCurrentElement(mainApp, () { 282 withCurrentElement(mainApp, () {
283 scanner.scan(mainApp); 283 scanner.scan(mainApp);
284 }); 284 });
285 return mainApp; 285 return mainApp;
286 } 286 }
287 } 287 }
OLDNEW
« no previous file with comments | « sdk/lib/_internal/compiler/implementation/dart2js.dart ('k') | sdk/lib/io/http_impl.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698