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

Side by Side Diff: pkg/compiler/lib/src/compiler.dart

Issue 2500413002: Remove Registry (Closed)
Patch Set: Created 4 years, 1 month 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
« no previous file with comments | « pkg/compiler/lib/src/common/registry.dart ('k') | pkg/compiler/lib/src/enqueue.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 dart2js.compiler_base; 5 library dart2js.compiler_base;
6 6
7 import 'dart:async' show EventSink, Future; 7 import 'dart:async' show EventSink, Future;
8 8
9 import '../compiler_new.dart' as api; 9 import '../compiler_new.dart' as api;
10 import 'cache_strategy.dart' show CacheStrategy; 10 import 'cache_strategy.dart' show CacheStrategy;
11 import 'closure.dart' as closureMapping show ClosureTask; 11 import 'closure.dart' as closureMapping show ClosureTask;
12 import 'common/backend_api.dart' show Backend; 12 import 'common/backend_api.dart' show Backend;
13 import 'common/codegen.dart' show CodegenWorkItem; 13 import 'common/codegen.dart' show CodegenWorkItem;
14 import 'common/names.dart' show Selectors; 14 import 'common/names.dart' show Selectors;
15 import 'common/names.dart' show Identifiers, Uris; 15 import 'common/names.dart' show Identifiers, Uris;
16 import 'common/registry.dart' show Registry;
17 import 'common/resolution.dart' 16 import 'common/resolution.dart'
18 show 17 show
19 ParsingContext, 18 ParsingContext,
20 Resolution, 19 Resolution,
21 ResolutionWorkItem, 20 ResolutionWorkItem,
22 ResolutionImpact, 21 ResolutionImpact,
23 Target; 22 Target;
24 import 'common/tasks.dart' show CompilerTask, GenericTask, Measurer; 23 import 'common/tasks.dart' show CompilerTask, GenericTask, Measurer;
25 import 'common/work.dart' show WorkItem; 24 import 'common/work.dart' show WorkItem;
26 import 'common.dart'; 25 import 'common.dart';
(...skipping 2179 matching lines...) Expand 10 before | Expand all | Expand 10 after
2206 if (field == null) return false; 2205 if (field == null) return false;
2207 if (!hasBeenResolved(field)) return false; 2206 if (!hasBeenResolved(field)) return false;
2208 if (_proxyConstant == null) { 2207 if (_proxyConstant == null) {
2209 _proxyConstant = constants 2208 _proxyConstant = constants
2210 .getConstantValue(resolver.constantCompiler.compileConstant(field)); 2209 .getConstantValue(resolver.constantCompiler.compileConstant(field));
2211 } 2210 }
2212 return _proxyConstant == value; 2211 return _proxyConstant == value;
2213 } 2212 }
2214 } 2213 }
2215 2214
2216 class GlobalDependencyRegistry extends Registry { 2215 class GlobalDependencyRegistry {
2217 Setlet<Element> _otherDependencies; 2216 Setlet<Element> _otherDependencies;
2218 2217
2219 GlobalDependencyRegistry(); 2218 GlobalDependencyRegistry();
2220 2219
2221 void registerDependency(Element element) { 2220 void registerDependency(Element element) {
2222 if (element == null) return; 2221 if (element == null) return;
2223 if (_otherDependencies == null) { 2222 if (_otherDependencies == null) {
2224 _otherDependencies = new Setlet<Element>(); 2223 _otherDependencies = new Setlet<Element>();
2225 } 2224 }
2226 _otherDependencies.add(element.implementation); 2225 _otherDependencies.add(element.implementation);
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
2258 _ElementScanner(this.scanner); 2257 _ElementScanner(this.scanner);
2259 void scanLibrary(LibraryElement library) => scanner.scanLibrary(library); 2258 void scanLibrary(LibraryElement library) => scanner.scanLibrary(library);
2260 void scanUnit(CompilationUnitElement unit) => scanner.scan(unit); 2259 void scanUnit(CompilationUnitElement unit) => scanner.scan(unit);
2261 } 2260 }
2262 2261
2263 class _EmptyEnvironment implements Environment { 2262 class _EmptyEnvironment implements Environment {
2264 const _EmptyEnvironment(); 2263 const _EmptyEnvironment();
2265 2264
2266 String valueOf(String key) => null; 2265 String valueOf(String key) => null;
2267 } 2266 }
OLDNEW
« no previous file with comments | « pkg/compiler/lib/src/common/registry.dart ('k') | pkg/compiler/lib/src/enqueue.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698