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

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

Issue 1879373004: Implement modular compilation (Closed) Base URL: git@github.com:dart-lang/dev_compiler.git@master
Patch Set: Created 4 years, 8 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 | « lib/src/compiler/extension_types.dart ('k') | lib/src/compiler/js_interop.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 import 'dart:collection' show HashMap, HashSet; 5 import 'dart:collection' show HashSet;
6 import 'package:analyzer/dart/ast/ast.dart' show Identifier; 6 import 'package:analyzer/dart/ast/ast.dart' show Identifier;
7 import 'package:analyzer/dart/element/element.dart'; 7 import 'package:analyzer/dart/element/element.dart';
8 8 import 'extension_types.dart';
9 import 'js_codegen.dart' show ExtensionTypeSet;
10 9
11 /// We use a storage slot for fields that override or can be overridden by 10 /// We use a storage slot for fields that override or can be overridden by
12 /// getter/setter pairs. 11 /// getter/setter pairs.
13 HashSet<FieldElement> findFieldsNeedingStorage( 12 HashSet<FieldElement> findFieldsNeedingStorage(
14 Iterable<CompilationUnitElement> units, ExtensionTypeSet extensionTypes) { 13 Iterable<CompilationUnitElement> units, ExtensionTypeSet extensionTypes) {
15 var overrides = new HashSet<FieldElement>(); 14 var overrides = new HashSet<FieldElement>();
16 for (var unit in units) { 15 for (var unit in units) {
17 for (var cls in unit.types) { 16 for (var cls in unit.types) {
18 var superclasses = getSuperclasses(cls); 17 var superclasses = getSuperclasses(cls);
19 for (var field in cls.fields) { 18 for (var field in cls.fields) {
(...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after
82 if (mixin != null) result.add(mixin); 81 if (mixin != null) result.add(mixin);
83 } 82 }
84 var supertype = cls.supertype; 83 var supertype = cls.supertype;
85 if (supertype == null) break; 84 if (supertype == null) break;
86 85
87 cls = supertype.element; 86 cls = supertype.element;
88 result.add(cls); 87 result.add(cls);
89 } 88 }
90 return result; 89 return result;
91 } 90 }
OLDNEW
« no previous file with comments | « lib/src/compiler/extension_types.dart ('k') | lib/src/compiler/js_interop.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698