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

Side by Side Diff: pkg/analyzer/lib/src/task/strong_mode.dart

Issue 1329743005: Abstract over the type system. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Address comments Created 5 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
« no previous file with comments | « pkg/analyzer/lib/src/task/dart.dart ('k') | pkg/analyzer/test/generated/all_the_rest_test.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) 2015, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2015, 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 analyzer.src.task.strong_mode; 5 library analyzer.src.task.strong_mode;
6 6
7 import 'dart:collection'; 7 import 'dart:collection';
8 8
9 import 'package:analyzer/src/generated/ast.dart'; 9 import 'package:analyzer/src/generated/ast.dart';
10 import 'package:analyzer/src/generated/element.dart'; 10 import 'package:analyzer/src/generated/element.dart';
(...skipping 94 matching lines...) Expand 10 before | Expand all | Expand 10 after
105 /** 105 /**
106 * The classes that have been visited while attempting to infer the types of 106 * The classes that have been visited while attempting to infer the types of
107 * instance members of some base class. 107 * instance members of some base class.
108 */ 108 */
109 HashSet<ClassElementImpl> elementsBeingInferred = 109 HashSet<ClassElementImpl> elementsBeingInferred =
110 new HashSet<ClassElementImpl>(); 110 new HashSet<ClassElementImpl>();
111 111
112 /** 112 /**
113 * Initialize a newly create inferrer. 113 * Initialize a newly create inferrer.
114 */ 114 */
115 InstanceMemberInferrer(this.typeProvider) { 115 InstanceMemberInferrer(this.typeProvider, this.typeSystem);
116 typeSystem = new TypeSystemImpl(typeProvider);
117 }
118 116
119 /** 117 /**
120 * Infer type information for all of the instance members in the given 118 * Infer type information for all of the instance members in the given
121 * compilation [unit]. 119 * compilation [unit].
122 */ 120 */
123 void inferCompilationUnit(CompilationUnitElement unit) { 121 void inferCompilationUnit(CompilationUnitElement unit) {
124 inheritanceManager = new InheritanceManager(unit.library); 122 inheritanceManager = new InheritanceManager(unit.library);
125 unit.types.forEach((ClassElement classElement) { 123 unit.types.forEach((ClassElement classElement) {
126 try { 124 try {
127 _inferClass(classElement); 125 _inferClass(classElement);
(...skipping 343 matching lines...) Expand 10 before | Expand all | Expand 10 after
471 results.add(element); 469 results.add(element);
472 } 470 }
473 } 471 }
474 } 472 }
475 } 473 }
476 474
477 /** 475 /**
478 * A class of exception that is not used anywhere else. 476 * A class of exception that is not used anywhere else.
479 */ 477 */
480 class _CycleException implements Exception {} 478 class _CycleException implements Exception {}
OLDNEW
« no previous file with comments | « pkg/analyzer/lib/src/task/dart.dart ('k') | pkg/analyzer/test/generated/all_the_rest_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698