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

Side by Side Diff: lib/compiler/implementation/apiimpl.dart

Issue 10891004: [dart2dart] Optionally cut types in variable declarations: (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 years, 3 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 | « no previous file | lib/compiler/implementation/compiler.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 #library('leg_apiimpl'); 5 #library('leg_apiimpl');
6 6
7 #import('dart:uri'); 7 #import('dart:uri');
8 8
9 #import('../compiler.dart', prefix: 'api'); 9 #import('../compiler.dart', prefix: 'api');
10 #import('leg.dart', prefix: 'leg'); 10 #import('leg.dart', prefix: 'leg');
(...skipping 12 matching lines...) Expand all
23 bool mockableLibraryUsed = false; 23 bool mockableLibraryUsed = false;
24 24
25 Compiler(this.provider, this.handler, this.libraryRoot, this.packageRoot, 25 Compiler(this.provider, this.handler, this.libraryRoot, this.packageRoot,
26 List<String> options) 26 List<String> options)
27 : this.options = options, 27 : this.options = options,
28 super( 28 super(
29 tracer: new ssa.HTracer(), 29 tracer: new ssa.HTracer(),
30 enableTypeAssertions: options.indexOf('--enable-checked-mode') != -1, 30 enableTypeAssertions: options.indexOf('--enable-checked-mode') != -1,
31 enableUserAssertions: options.indexOf('--enable-checked-mode') != -1, 31 enableUserAssertions: options.indexOf('--enable-checked-mode') != -1,
32 emitJavascript: options.indexOf('--output-type=dart') == -1, 32 emitJavascript: options.indexOf('--output-type=dart') == -1,
33 minify: options.indexOf('--minify') != -1); 33 minify: options.indexOf('--minify') != -1,
34 cutDeclarationTypes: options.indexOf('--cutDeclarationTypes') != -1);
34 35
35 elements.LibraryElement scanBuiltinLibrary(String path) { 36 elements.LibraryElement scanBuiltinLibrary(String path) {
36 Uri uri = libraryRoot.resolve(DART2JS_LIBRARY_MAP[path].libraryPath); 37 Uri uri = libraryRoot.resolve(DART2JS_LIBRARY_MAP[path].libraryPath);
37 Uri canonicalUri; 38 Uri canonicalUri;
38 if (path.startsWith("_")) { 39 if (path.startsWith("_")) {
39 canonicalUri = uri; 40 canonicalUri = uri;
40 } else { 41 } else {
41 canonicalUri = new Uri.fromComponents(scheme: "dart", path: path); 42 canonicalUri = new Uri.fromComponents(scheme: "dart", path: path);
42 } 43 }
43 elements.LibraryElement library = 44 elements.LibraryElement library =
(...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after
120 handler(translateUri(span.uri, null), span.begin, span.end, 121 handler(translateUri(span.uri, null), span.begin, span.end,
121 message, kind); 122 message, kind);
122 } 123 }
123 } 124 }
124 125
125 bool get isMockCompilation { 126 bool get isMockCompilation {
126 return mockableLibraryUsed 127 return mockableLibraryUsed
127 && (options.indexOf('--allow-mock-compilation') !== -1); 128 && (options.indexOf('--allow-mock-compilation') !== -1);
128 } 129 }
129 } 130 }
OLDNEW
« no previous file with comments | « no previous file | lib/compiler/implementation/compiler.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698